Issues with C# Script Not Recognizing Scene Objects in Flax Engine

Hello

I’m currently working on a project in Flax Engine using C#, and I’ve run into an issue where my script isn’t recognizing scene objects properly. I’ve assigned references in the Inspector; but when I try to access them in code; I keep getting null references. It seems like the script isn’t correctly fetching objects from the scene hierarchy. :upside_down_face:

I’ve tried ensuring that the objects are active, checking for missing components & even reassigning references in the editor, but nothing seems to work consistently. This issue mainly happens when loading a new scene / after compiling changes. Is there a specific way to ensure that scene objects are properly linked to scripts? :thinking: Checked Scripting - Flax Forum AWS guide related to this and found it quite informative.

Has anyone else encountered this problem? Could this be related to how Flax initializes scene objects at runtime? :upside_down_face:Any best practices or debugging steps would be greatly appreciated!

Thank you !! :slightly_smiling_face: