Forum rules - please read before posting.

Different Idle animation for NPCs (custom script/Spine)

Hello!

So I got some NPCs that need different idle animations, I tried to tie it up to Variable - Pop Up Switch, where depending on the number it executes Custom Animation and loops back. Also it is an independent Interaction.

ActionList Editor screenshot:
https://drive.google.com/file/d/1b1x1sryONzsORshErb5EIciSiUicMh06/view?usp=share_link

Variable screenshot:
https://drive.google.com/file/d/1Vrnlmz6AdcMzfS_PSoZRhstKfi-GVop1/view?usp=share_link

And as a result when I run the game NPC just loops with default Idle.

So I am using this method to tie Spine and AC together:
https://adventure-creator.fandom.com/wiki/Spine_Integration
(Shoutout to Chris for last help)

I have examples where I successfully used custom animation to play out exactly how I wanted during dialogue.

So that probably means I am doing something wrong and probably should be possible.

All info that I looked in the forum usually about Sprites Unity or Sprites Unity Complex and is fixed with using animator. In my case animator set as custom script and animation can be called upon its name.

If someone could help me out or maybe bounce some ideas I would really appreciate it.

Keep on creating adventurerers B)

Comments

  • Can't see an issue from the screenshots - what of the Skeleton's list of available animations? Check the Console for related messages, too.

    As a test, try un-looping the Actions so that the animation is only set each time the ActionList is run - does it then work if you run it manually by clicking "Run now" in the ActionList's Inspector?

  • Hey Chris!

    Didn't know "Run now" feature, it's perfect for testing, thank you.

    So it looks like when I press "Run now it works" but by itself it does not.

    I added Variable - Set - Set as Random from and it still doesn't run until I press "Run now".

    In the inspector of this interaction I set "When running : Run in Background".

    Looks like I am missing something simple.

  • If it's running OK manually, how and when is it set to run automatically?

    If you want it to run when the scene begins, you can attach the ActionList starter component to it and check Run on scene start?.

    To further help debugging, you can enable the "AC Status" box via the bottom of the Settings Manager. At runtime, this will show a list of all currently-running ActionLists in the corner of the Game window - you can use it to determine if the list is running or not.

  • Chris, my man thank you!

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.