Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: justifun on May 20, 2022, 03:17:29 AM
-
I'm writing a custom action to check the bool value of a object right after it was instantiated on the network. (FishNet in this case).
The bool is for whether or not the game object is Owned by the current local player or not.
When it first spawns, that value is "False" for 1 frame or something, then becomes "True" if its true for every frame after that.
I guess it takes a frame or so to go from its default False to True
OnEnter() always picks it up as "False" but if i add an "Every Frame" check to my action it will become "True" next frame.
How do I get OnEnter() to either way a sec or deal with the new object needing a second to set its local bool?
-
There's a lot of racing conditions when using Playmaker. If you're writing a custom action, you can always make on enable to wait for invoke another method with a small delay. That another method will have get bool.
-
Hi.
you can setup a coroutine or a await
for await you might need to set a #pragma to prevent a warning
and wait a frame, or check for some initiate completed