- Home /
Behaviour on playMakers "Invoke Mthod"
So, I want to invoke a method of an object not existing in the scene yet. I use the "Find Game Object" and the "Invoke Method" but what is "Behaviour" in "Invoke Method"? It's description says "Parameter: String" and its required. When I put the script name there I get the error:
Main Camera missing behaviour: LevelStarter
Answer by UNZoOM · Mar 20, 2015 at 05:32 PM
Behvaiour(String) is nothing but the Method Name you want to call.
like so, Invoke("MyMethod", 5); // where 5 is the delay before the function is called.
also better check if object is active which can be done in various ways for example ,
if( GameObject.activeInHierarchy)
Invoke("MyMethod", 5);
function MyMethod()
{
// MyMethod Actions to be performed after a delay of 5 seconds.
}
Main Camera missing behaviour: LevelStarter is because there is no Script known as LevelStarter attached to the Main Camera.
But there is a field for "Behaviour" and another for "$$anonymous$$ethod Name". $$anonymous$$y guess is that it "behaviour" should be "script name". Thank you for reply. $$anonymous$$aybe my error in my question is something else then.
what function are you using , it seemed like you are using Invoke() ?
Your answer
Follow this Question
Related Questions
Install PlayMaker 4 Answers
How to "dock" Playmaker so I can use it? 1 Answer
Playmaker Touch Actions for Android 0 Answers
BOLT FlowStateMachine for entire scene? 1 Answer
to draw a health bar 2 Answers