playMaker

Author Topic: Animator Follow - no go with Generic  (Read 3489 times)

Pawel

  • Junior Playmaker
  • **
  • Posts: 93
Animator Follow - no go with Generic
« on: April 01, 2013, 11:10:38 AM »
There is an issue with Animator Follow action when used with Generic Rigs -- they simply do not follow the target. This is also happening with with the Follow.cs script that was included with Mechanim samples. They work fine on Humanoids but not on Generic.

The Generic rigs had problems with initial release of Mechanim, but those issues have since been fixed -- could the two be related?

Pawel

  • Junior Playmaker
  • **
  • Posts: 93
Re: Animator Follow - no go with Generic
« Reply #1 on: April 01, 2013, 04:12:27 PM »
I see that this was a topic of discussion some months ago. I wanted to perform this setup with a generic rig and it did not work... (it works with 2-legged bears, robots and humans though <g>) Anybody has an idea why is this the case?

http://hutonggames.com/playmakerforum/index.php?topic=2531.msg11780#msg11780

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Animator Follow - no go with Generic
« Reply #2 on: April 02, 2013, 03:23:27 AM »
Hi,

 Unfortunatly, the action depends on "CharacterController" component and it's likely the case that it's not on your generic rig

you can tho write this action all in playmaker, you need to set the direction and the speed of the animator component yourself.

bye,

 Jean

Pawel

  • Junior Playmaker
  • **
  • Posts: 93
Re: Animator Follow - no go with Generic
« Reply #3 on: April 02, 2013, 09:20:38 AM »
Thanks Jean.

I do have Character Controllers. Everything is set up the same way as with the characters that were included in Unity Mecanim samples. I used the bears following the main character scene to check my setup. I replaced the Follow.cs Script with Playmaker Follow Action and tried several of my own non-humanoid characters, as well as the Unity's Generic mine_bot. None of the non-humanoid rigs work. All of them work just fine when controlled via direct input.

There is a small possibility that the axis in my character are the cause, and this is what I am investigating right now. I set up my animations using CAT in 3ds Max using "Follow Node" -- In order for this to work I need to rotate the node sideways otherwise the character in Max would go sideways... (this is a bug in Max that was never fixed) I will check if changing the axis in my FBX files in Max would make a difference... I'll let you know.

Also, there is a small difference between the behavior of the characters  depending using the Follow script and Follow Playmaker Action once the character reaches the target -- with the script the character goes into Idle animation and with the Playmaker's Follow it keeps running around the target. This you can test using Mechanim Bear sample files...

Pawel

  • Junior Playmaker
  • **
  • Posts: 93
Re: Animator Follow - no go with Generic
« Reply #4 on: April 02, 2013, 08:45:54 PM »
I did re-checked the axis setup in FBX files and it seem this was the culprit. Even though there was no problem when using direct control of the player character via keyboard or joystick, when the character is controlled by the follow.cs script the axis have to be set up exactly in the FBX files.

This is huge relief!

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Animator Follow - no go with Generic[SOLVED]
« Reply #5 on: April 03, 2013, 01:57:59 AM »
Hi,

 very good!

bye,

 Jean