You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using Godot Object pointers provide unexpected results regarding the access to properties that are not declared (see #46).
Using Lua tables, it doesn't matter if a property is declared or not, so it should be possible to set new values to Lua instances from Lua regardless of property declaration. It won't work from GDScript or other languages, but people might be writing all scripts in Lua, so it's more useful to have script instances automatically unboxed, if available.
Using GD.get_lua_instance from Variant.unbox should be enough, falling back to the original Object pointer if there is not Lua script attached to it. The cost of this operation is a single table index, so it shouldn't be a problem regarding performance.
The text was updated successfully, but these errors were encountered:
Using Godot Object pointers provide unexpected results regarding the access to properties that are not declared (see #46).
Using Lua tables, it doesn't matter if a property is declared or not, so it should be possible to set new values to Lua instances from Lua regardless of property declaration. It won't work from GDScript or other languages, but people might be writing all scripts in Lua, so it's more useful to have script instances automatically unboxed, if available.
Using
GD.get_lua_instance
fromVariant.unbox
should be enough, falling back to the original Object pointer if there is not Lua script attached to it. The cost of this operation is a single table index, so it shouldn't be a problem regarding performance.The text was updated successfully, but these errors were encountered: