btw while we’re here
by user 263967078346653697
btw while we’re here
by user 263967078346653697
is there any function for onsceneloaded?
by user 263967078346653697
since as i understand the scenes dont actually change
by user 263967078346653697
so start() only hits once
by user 263967078346653697
when the scene is loaded for the first time
by user 263967078346653697
Same as in Unity. Start is called when an object is becoming active for the first time before calling the update/early update events.
right, but i assumed at first that whenever a scene is changed, it will hit start every time
by user 263967078346653697
There’s no special function for “onsceneloaded” - that could be any of your components in the root scene (your main export scene) and something your scene loader would / could invoke on child components
got it
by user 263967078346653697
Ah ok, well you control that - a “scene” is just the Unity term for what at runtime could be any part of your hierarchy (like you could have 5 unity scenes that you use for something totally different on your website) - so we don’t enforce unloading/loading everything
ok that makes sense
by user 263967078346653697
umm what about OnEnable
by user 263967078346653697
that should do it right?
by user 263967078346653697
ohhhh right i remembered
by user 263967078346653697
theres an issue with video player
by user 263967078346653697
if i change a scene where theres a video player and go back to it
by user 263967078346653697
it no longer plays
by user 263967078346653697
tho i guess if onenable works, i could force restart it
by user 263967078346653697
gotta try that out
by user 263967078346653697
yess woop it works super simple
by user 263967078346653697