colyseus / colyseus-defold

⚔ Colyseus SDK for Defold Engine
https://docs.colyseus.io/getting-started/defold-client/
MIT License
62 stars 10 forks source link

Connection problems #13

Closed emarkk closed 5 years ago

emarkk commented 5 years ago

Everything works fine when target is set to New Local Engine, but when I run the game on my Android device the WebSocket does not work and I get these errors

DEBUG:SCRIPT: CONNECTION ERROR!
DEBUG:SCRIPT: /websocket/tools.lua:162: attempt to index upvalue 'mime' (a nil value)

I am using colyseus-defold with the following dependencies:

https://github.com/britzl/defold-websocket/archive/master.zip
https://github.com/britzl/defold-luasocket/archive/0.11.zip
https://github.com/britzl/defold-luasec/archive/master.zip
britzl commented 5 years ago

It looks like it doesn't build the mime native extension (part of defold-luasocket)

endel commented 5 years ago

That's strange, I've just built for Android and it works fine

endel commented 5 years ago

@emarkk have you figured this one out? I see you had some progress on the forum. Cheers!

emarkk commented 5 years ago

Yeah, sorry, I solved it. I think it was due to the Defold Engine which was not up to date. I updated it and used a debug bundle of the app instead of dmengine.apk and everything worked.

endel commented 5 years ago

perfect, going to close this then, thanks!