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
Nice video and example code. I looked through it and it looks like you're using duck typing to assume that there's a variable or method to call to set data when you create a new scene from a scene path. This works ok in GDScript (though seems a bit brittle), but how would you do this sort of thing in a compiled language like C#? Would your scene switcher have to know the type of every scene it might switch to and what properties it has? Maybe you pass in a Function to call that does the creation and injection of parameters rather than only using a scene path? I'm just wondering how you do it if you want to use something other than GDScript that has compile-time checks.
The text was updated successfully, but these errors were encountered:
Nice video and example code. I looked through it and it looks like you're using duck typing to assume that there's a variable or method to call to set data when you create a new scene from a scene path. This works ok in GDScript (though seems a bit brittle), but how would you do this sort of thing in a compiled language like C#? Would your scene switcher have to know the type of every scene it might switch to and what properties it has? Maybe you pass in a Function to call that does the creation and injection of parameters rather than only using a scene path? I'm just wondering how you do it if you want to use something other than GDScript that has compile-time checks.
The text was updated successfully, but these errors were encountered: