PrismarineJS / mineflayer

Create Minecraft bots with a powerful, stable, and high level JavaScript API.
https://prismarinejs.github.io/mineflayer/
MIT License
4.96k stars 904 forks source link

Error when bot enters the nether #521

Closed ghost closed 7 years ago

ghost commented 7 years ago

When my bot enters the nether, I get the following error:

C:\MinecraftBot\node_modules\prismarine-chunk\src\pc\1.9\chunk.js:365 throw e; ^

PartialReadError: Read error for skyLight : undefined at PartialReadError.ExtendableError (C:\MinecraftBot\node_modules\protodef\src\utils.js:75:11) at PartialReadError (C:\MinecraftBot\node_modules\protodef\src\utils.js:81:5) at ProtoDef.readBuffer (C:\MinecraftBot\node_modules\protodef\src\datatypes\utils.js:150:42) at ProtoDef.read (C:\MinecraftBot\node_modules\protodef\src\protodef.js:127:29) at tryDoc (C:\MinecraftBot\node_modules\protodef\src\datatypes\structures.js:46:32) at tryCatch (C:\MinecraftBot\node_modules\protodef\src\utils.js:63:16) at tryDoc (C:\MinecraftBot\node_modules\protodef\src\utils.js:67:10) at typeArgs.forEach (C:\MinecraftBot\node_modules\protodef\src\datatypes\structures.js:45:5) at Array.forEach (native) at ProtoDef.readContainer (C:\MinecraftBot\node_modules\protodef\src\datatypes\structures.js:44:12)

Just for good measure I tried it on a localhost server which game me a different error the first time he went in, but after that he gave the same error as above.

The error he gave on a localhost was:

buffer.js:11 super(arg1, arg2, arg3); ^

RangeError: Invalid typed array length at Buffer.Uint8Array (native) at FastBuffer (buffer.js:11:5) at Function.Buffer.alloc (buffer.js:132:10) at Chunk.eatPackedBlockLongs (C:\MinecraftBot\node_modules\prismarine-chunk\src\pc\1.9\chunk.js:427:34) at Chunk.unpackChunkData (C:\MinecraftBot\node_modules\prismarine-chunk\src\pc\1.9\chunk.js:371:31) at Chunk.load (C:\MinecraftBot\node_modules\prismarine-chunk\src\pc\1.9\chunk.js:343:29) at addColumn (C:\MinecraftBot\node_modules\mineflayer\lib\plugins\blocks.js:46:12) at Client. (C:\MinecraftBot\node_modules\mineflayer\lib\plugins\blocks.js:168:5) at emitTwo (events.js:106:13) at Client.emit (events.js:191:7)

rom1504 commented 7 years ago

Ah I guess we need #521

Gjum commented 7 years ago

521 is this issue itself, did you mean to refer to another one? :)

rom1504 commented 7 years ago

hahaha yes. I meant #510

rom1504 commented 7 years ago

now fixed