Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: hockeygoalie78 on January 21, 2020, 10:07:11 AM
-
I have been attempting to get my FSM to go to a particular state given the name of it in string format. I'm using the GoToStateByName action (which I have downloaded separately and added into my project), but I am unable to get it to work properly. I have the correct name stored in a variable, but when I use the action it gives me a null reference exception on the Fsm sourceFsm on line 85. Does anyone know what might be causing that?
For reference, I found the GoToStateByName action here:
https://github.com/jeanfabre/PlayMakerCustomActions_U3/blob/5d388f4bfbec8144aaa5272759f3cc7c76af90d5/Assets/PlayMaker%20Custom%20Actions/StateMachine/GoToStateByName.cs (https://github.com/jeanfabre/PlayMakerCustomActions_U3/blob/5d388f4bfbec8144aaa5272759f3cc7c76af90d5/Assets/PlayMaker%20Custom%20Actions/StateMachine/GoToStateByName.cs)
-
Hi.
You might have an outdated version of the action, it is best to use the Ecosystem (https://hutonggames.fogbugz.com/default.asp?W1181) to download custom actions
for the name, also make sure there is no space at the end or beginning.
-
Getting it from the Ecosystem rather than the Git repository worked, thanks!
-
Hi,
yes, Unity 3 is very very old indeed :)
Bye,
Jean