Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: Lax on February 15, 2022, 03:52:22 PM

Title: Trigger Parameters not working inside Animator Trigger action
Post by: Lax on February 15, 2022, 03:52:22 PM
Hello Everyone,

I am new to Unity and Playmaker and I need some help here.

I am creating a 2D platformer game and have used Fantasy Hero Editor asset to use a readily animated hero character(and stored as a prefab).

While setting up the basic player controller/movements using Playmaker, I have managed to move the character left and right along with flip left and right action.

Now the problem is that I am not able to trigger the walk animation of my character model.

My trigger parameters of Stand & Walk are not visible when using the Set Animator Trigger action >  Specify Game Object >  selecting CharacterPrefab. The Trigger field shows the message as "No Trigger Parameters..."


I have already setup the stand and walk triggers in the Animator window. Still it's not working in the "Set Animator Trigger". I have also attached the screenshot here. Can someone help me here?

Thanks in advance!

============================


I had used below reference video to start working on my character movement in Unity + Playmaker:

Title: Re: Trigger Parameters not working inside Animator Trigger action
Post by: djaydino on February 15, 2022, 08:57:38 PM
Hi.
You can write the names of the parameters in the box next to it.
the ... does not always work for some reason.
Title: Re: Trigger Parameters not working inside Animator Trigger action
Post by: Lax on February 16, 2022, 12:21:05 PM
Thanks for your help. I checked that as well. But that did not help.

Also, I did something just now  due to which I was switched to Animator > Base Layer  (from Animator > Lower Layer of the character). And after setting up the transitions between Idle and Walk I am now able to see the drop-down menus of Idle and Walk triggers. But the walk animation is still not played. Neither there are any errors. My character is moving left and right, also flipping left and right as expected. Idle animation is also working fine. But the walk animation is not happening. Any suggestions?
Title: Re: Trigger Parameters not working inside Animator Trigger action
Post by: djaydino on February 16, 2022, 12:35:33 PM
Hi.
is this a 2d sprite based?
if so i suggest using the action 'Animator Play' instead of Animator trigger.

can you show the animator setup, also how you trigger the walk
Title: Re: Trigger Parameters not working inside Animator Trigger action
Post by: Lax on February 16, 2022, 12:49:45 PM
It's not 2D sprite based. I am using Fantasy Hero Editor asset to use a readily animated hero character.
Title: Re: Trigger Parameters not working inside Animator Trigger action
Post by: djaydino on February 16, 2022, 01:22:55 PM
Hi.
Check if the transition setting (animator) are correct, also if the animation file is correct.
it can be multiple things, its hard to say without more info,
make short video or gif, showing animator settings from the walk, also the parameter that is used for the trigger.
and playmaker event to trigger it
Title: Re: Trigger Parameters not working inside Animator Trigger action
Post by: Lax on February 19, 2022, 03:16:21 AM
Thanks for responding. I did check the animator and transition settings. It's looking fine(according to me). Still, attached the GIF of everything to explain the situation better. GIF Link-
https://drive.google.com/file/d/1OKVFQldSkAzSK5qo0wsEXT-_j_OaVuas/view?usp=sharing


Title: Re: Trigger Parameters not working inside Animator Trigger action
Post by: djaydino on February 19, 2022, 09:21:10 AM
Hi.
between walk/run you should use a float condition (Speed) instead of triggers

or do separate transitions starting from "Any State"
Title: Re: Trigger Parameters not working inside Animator Trigger action
Post by: Lax on February 21, 2022, 09:15:14 AM
Thanks. Tried that as well but it's not working.