inxomnyaa / MagicWE

Lag free asynchronous world editor for PMMP with plenty of options
https://poggit.pmmp.io/ci/inxomnyaa/MagicWE
GNU General Public License v3.0
102 stars 83 forks source link

Crash when player look an UnknownBlock #227

Closed IvanCraft623 closed 3 years ago

IvanCraft623 commented 3 years ago

Description

2021-06-17 [18:18:07.648] [Server thread/CRITICAL]: ErrorException: "Undefined offset: 14" (EXCEPTION) in "plugins/MagicWE2.phar/src/xenialdan/MagicWE2/helper/BlockStatesParser" at line 299
2021-06-17 [18:18:07.809] [Server thread/CRITICAL]: #0 plugins/MagicWE2.phar/src/xenialdan/MagicWE2/helper/BlockStatesParser(299): pocketmine\errorhandler\ErrorToExceptionHandler::handle(integer 8, string[20] Undefined offset: 14, string[107] phar://C:/Users/ivanc/Desktop/PM4/plugins/MagicWE2.phar/src/xenialdan/MagicWE2/h, integer 299, array[3])
2021-06-17 [18:18:07.935] [Server thread/CRITICAL]: #1 plugins/MagicWE2.phar/src/xenialdan/MagicWE2/Loader(341): xenialdan\MagicWE2\helper\BlockStatesParser::getStateByBlock(object pocketmine\block\UnknownBlock#233027)
2021-06-17 [18:18:08.225] [Server thread/CRITICAL]: #2 pmsrc/src/scheduler/ClosureTask(61): xenialdan\MagicWE2\Loader->xenialdan\MagicWE2\{closure}()
2021-06-17 [18:18:08.634] [Server thread/CRITICAL]: #3 pmsrc/src/scheduler/TaskHandler(117): pocketmine\scheduler\ClosureTask->onRun()
2021-06-17 [18:18:08.879] [Server thread/CRITICAL]: #4 pmsrc/src/scheduler/TaskScheduler(144): pocketmine\scheduler\TaskHandler->run()
2021-06-17 [18:18:08.970] [Server thread/CRITICAL]: #5 pmsrc/src/plugin/PluginManager(429): pocketmine\scheduler\TaskScheduler->mainThreadHeartbeat(integer 12253)
2021-06-17 [18:18:09.194] [Server thread/CRITICAL]: #6 pmsrc/src/Server(1692): pocketmine\plugin\PluginManager->tickSchedulers(integer 12253)
2021-06-17 [18:18:09.403] [Server thread/CRITICAL]: #7 pmsrc/src/Server(1594): pocketmine\Server->tick()
2021-06-17 [18:18:09.487] [Server thread/CRITICAL]: #8 pmsrc/src/Server(1147): pocketmine\Server->tickProcessor()
2021-06-17 [18:18:09.618] [Server thread/CRITICAL]: #9 pmsrc/src/PocketMine(276): pocketmine\Server->__construct(object BaseClassLoader#2, object pocketmine\utils\MainLogger#3, string[27] C:\Users\ivanc\Desktop\PM4\, string[35] C:\Users\ivanc\Desktop\PM4\plugins\)
2021-06-17 [18:18:09.772] [Server thread/CRITICAL]: #10 pmsrc/src/PocketMine(299): pocketmine\server()
2021-06-17 [18:18:09.912] [Server thread/CRITICAL]: #11 pmsrc(11): require(string[71] phar://C:/Users/ivanc/Desktop/PM4/PocketMine-MP.phar/src/PocketMine.php)

How reproduce

Block: pocketmine/block/UnknownBlock.php

  1. Find an UnknownBlock
  2. Look it
  3. Crash!

    MagicWE2 Information
    Version 10.1.5
    Plugin API Version Branch PM4 4.0.0
    PMMP Protocol Version 440
    PMMP Version 4.0.0
    PMMP API Version 4.0.0
inxomnyaa commented 3 years ago

Looks like i can't debug it with just this information. Try turning off the WAILA tool (//togglewaila) and show me the block id/meta that has been looked at. "UnknownBlock" is just a placeholder block object. If the //debug stick still exists, try using that one. otherwise try making a selection that includes the block and do //count

inxomnyaa commented 3 years ago

Potentially related: https://crash.pmmp.io/view/4983649

IvanCraft623 commented 3 years ago

UnknownBlocks do not have a specific id or meta, they are any block placed in which they are not registered. This block appeared to me after using a Java world in Pocketmine.

inxomnyaa commented 3 years ago

I guess user error then?