Error with TOC, when I take over car with other player, I will get an error:
Code I am using:
Is this a PRISM bug?
<?php
< IS_TOC Packet from server.
PHP NOTICE:
Undefined offset: 21 in xxxx\modules\prism_statehandler.php on line 416
1 :: onTakeOverCar in xxxx\modules\prism_statehandler.php:81
2 :: onClientPacket in xxxx\modules\prism_statehandler.php:58
3 :: dispatchPacket in xxxx\modules\prism_hosts.php:576
4 :: inspectPacket in xxxx\modules\prism_hosts.php:487
5 :: handlePacket in xxxx\modules\prism_hosts.php:353
6 :: checkTraffic in xxxx\PHPInSimMod.php:228
PHP NOTICE:
Object of class PlayerHandler could not be converted to int in xxxx\modules\prism_statehandler.php on line 416
1 :: onTakeOverCar in xxxx\modules\prism_statehandler.php:81
2 :: onClientPacket in xxxx\modules\prism_statehandler.php:58
3 :: dispatchPacket in xxxx\modules\prism_hosts.php:576
4 :: inspectPacket in xxxx\modules\prism_hosts.php:487
5 :: handlePacket in xxxx\modules\prism_hosts.php:353
6 :: checkTraffic in xxxx\PHPInSimMod.php:228
UNKNOWN:
Argument 1 passed to welcome::onTest() must be an instance of ISP_TOC, instance of IS_TOC given, called in xxxx\modules\prism_plugins.php on line 156 and defined in xxxx\plugins\welcome.php on line 54
1 :: onTest in xxxx\modules\prism_plugins.php:156
2 :: dispatchPacket in xxxx\modules\prism_hosts.php:577
3 :: inspectPacket in xxxx\modules\prism_hosts.php:487
4 :: handlePacket in xxxx\modules\prism_hosts.php:353
5 :: checkTraffic in xxxx\PHPInSimMod.php:228
object(IS_TOC)#11 (8) {
["Size"[:p]rotected]=>
int(8)
["Type"[:p]rotected]=>
&int(31)
["ReqI"[:p]rotected]=>
int(0)
["PLID"]=>
int(21)
["OldUCID"]=>
int(20)
["NewUCID"]=>
int(19)
["Sp2"[:p]rotected]=>
int(0)
["Sp3"[:p]rotected]=>
int(0)
}
?>
<?php
public function onTakeOverCar(ISP_TOC $TOC)
{
var_dump($TOC);
}
?>