GodotSteam / GodotSteam

An ecosystem of tools for Godot Engine and Valve's Steam. For the Windows, Linux, and Mac platforms.
http://godotsteam.com/
MIT License
2.77k stars 187 forks source link

Error in lobby.gd in example project #199

Closed noidexe closed 3 years ago

noidexe commented 3 years ago

I can't find the repo for the GodotSteam Example project so I'm adding this here: If you try to use the lobby example you'll get this error: image

I thought it was just a colon where there should be a comma but then you get this error: image

I changed it like this and didn't get an error but I'm not sure if it's the right fix: image

Aditionally, when creating or opening a lobby I get this error:

E 0:00:07.851   Object::emit_signal: Error calling method from signal 'lobby_data_update': 'Control(lobby.gd)::_on_Lobby_Data_Update': Cannot convert argument 4 from int to String..
  <C++ Source>  core\object.cpp:1257 @ Object::emit_signal()
  <Stack Trace> global.gd:37 @ _process()

It seems the callback expects a String but should it be an int or a variant? image

It seems it is a char. I wonder if it needs to be converted to a Godot String before being passed to emit_signal. Is it ok that it is always '\0'? https://github.com/Gramps/GodotSteam/blob/abb8a3b843290081026c5edd620d167c1c9ac6d9/godotsteam/godotsteam.cpp#L7968

Gramps commented 3 years ago

Hey there! Yeah, there are a few weird bugs that got introduced into the tutorials after some module updates that haven't been fixed just yet. Thank you for pointing them out! A few people have mentioned these in the Discord as well; glad folks are keeping an eye out for this stuff.

We are re-writing the lobby / networking tutorials and example project today so this will be updated later on.

Also the example branch should be under the master in the branch drop-down list.

Gramps commented 3 years ago

OK, the example project has been updated and I will get the tutorial update to match that this weekend. Thanks again!