Slither-Server icon indicating copy to clipboard operation
Slither-Server copied to clipboard

Exception

Open axos88 opened this issue 8 years ago • 3 comments


 npm start

> [email protected] start /home/xxx/Downloads/slither/Slither-Server-0.0.5
> node ./index.js

[DEBUG] You are currently running on 0.0.5
[SERVER] Starting Server...
[SERVER] Server Started at 127.0.0.1:8080! Waiting for Connections...
[BOTS] Bot Status: Bot's are currently unavailable! Please try again later.
/home/xxx/Downloads/slither/Slither-Server-0.0.5/index.js:81
            if (value === conn.snake.direction.angle) {
                                    ^

TypeError: Cannot read property 'direction' of undefined
    at WebSocketServer.handleMessage (/home/xxx/Downloads/slither/Slither-Server-0.0.5/index.js:81:37)
    at emitOne (events.js:77:13)
    at WebSocket.emit (events.js:169:7)
    at Receiver._ultron.on._receiver.onmessage (/home/xxx/Downloads/slither/Slither-Server-0.0.5/node_modules/ws/lib/WebSocket.js:146:47)
    at Receiver.dataMessage (/home/xxx/Downloads/slither/Slither-Server-0.0.5/node_modules/ws/lib/Receiver.js:380:14)
    at Receiver.getData (/home/xxx/Downloads/slither/Slither-Server-0.0.5/node_modules/ws/lib/Receiver.js:330:12)
    at Receiver.startLoop (/home/xxx/Downloads/slither/Slither-Server-0.0.5/node_modules/ws/lib/Receiver.js:165:16)
    at Receiver.add (/home/xxx/Downloads/slither/Slither-Server-0.0.5/node_modules/ws/lib/Receiver.js:139:10)
    at Socket.<anonymous> (/home/xxx/Downloads/slither/Slither-Server-0.0.5/node_modules/ws/lib/WebSocket.js:142:22)
    at emitOne (events.js:77:13)

npm ERR! Linux 4.4.0-21-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "start"
npm ERR! node v4.2.6
npm ERR! npm  v3.5.2
npm ERR! code ELIFECYCLE
npm ERR! [email protected] start: `node ./index.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] start script 'node ./index.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the Slither-Server package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node ./index.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs Slither-Server
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls Slither-Server
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /home/xxx/Downloads/slither/Slither-Server-0.0.5/npm-debug.log

axos88 avatar Jun 14 '17 12:06 axos88

This happens when first snake is connecting.

axos88 avatar Jun 14 '17 12:06 axos88

$ npm version { 'Slither-Server': '0.0.5', npm: '3.5.2', ares: '1.10.1-DEV', http_parser: '2.5.0', icu: '55.1', modules: '46', node: '4.2.6', openssl: '1.0.2g-fips', uv: '1.8.0', v8: '4.5.103.35', zlib: '1.2.8' }

axos88 avatar Jun 14 '17 12:06 axos88

I think this is connected to a protocol incompatibility between the current version on slither.io and this project. Using one of the protocol v8 client allows running the server, but things are still buggy

computergeek125 avatar Jul 11 '17 15:07 computergeek125