I’m playing with the Colyesus engine to do multiplayer and have successfully implemented server side functionality while using the javascript Colyesus library to test with.
Now I’m implementing code in Defold to hook up with the server. In my code, I have them join an “auth” room to do initial login. In my javascript code, I do this and the server creates a new room and then passes the login info to the onAuth method on the server (I’m console.log’ing the parameters passed to onInit and onAuth):
auth = client.join(“auth”, {email: ‘some@email.tld’, pass: ‘secure’});
however, when I try this in Defold:
local opts = {}
opts[‘email’]= email
opts[‘pass’] = pass
room = client:join(“auth”, opts)
On the server I see it create a new room with the correct parameters, but when onAuth gets called, no parameters are passed to it, here’s the log:
Auth Room onInit, options: { sessionId: ‘SyrKOr2Z7’,
requestId: 1,
pass: ‘secure’,
email: ‘some@email.tld’,
clientId: ‘rkQWkSnWQ’ }
onAuth options: {}
Maybe @dossy can give some insight?