Forum rules - please read before posting.

Backwards animation in Mecanim mode and "Platform movement" in 3D Mode

edited March 2014 in Technical Q&A
Hi. I have followed the "mecanim tutorial" from the site and my player is moving nicely, but I have three questions...

- Is it possible to set a backward animation via Mecanim?
For example, using "3D / Direct Mode" I can move my player in the 3D environment easily, with the animations (walking/running) working properly, but if I press the button to go backward (walking or running), he uses the walk or running animation (then I start to do a moonwalking haha) and, of course, doesn't get a nice effect for the game.

- Is it possible to set a "second speed" stage for the player?
I have two animations: Running (little bit fast than walking, like a "running in stealth mode") and Sprinting (uses max effort to run)
The thing is: I want to make two different stages of run (maybe with some "stamina" state attached to, or something like that). AC allows you to do something like that without additional scripting?

- Is it possible to make a "side-scrolling" input for 3D mode?
I want to make a game like Deadlight, with the 3D character AND the 3D environment, but with left button making you go to the left, and right button making you go to the right. Is it possible with Adventure Creator?

That's all for now. Thanks for this awesome tool.

Comments

  • edited March 2014
    Oh, and I'm having another issue.

    My character (player) looks like he's in the moon. The "Ignore Gravity" is deactivated, in Rigidbody the Mass is 1000 and the "Use Gravity" is activated. In the "Project -> Physics" settings, they are all with default settings. When I walk through the scenario/go up the stairs, everything looks fine, but when I go down the stairs, the player just starts to fly and fall slowly...

    Any tip?
  • The lack of a backward-walking animation is a bit of an oversight.  I'll see about making the movement float become negative for you.

    You can use the Character: Animate action to change the values of your walk/run floats.

    As for your gravity issue, it could be to do with the scale of your character.  How does it compare with that of the demo player prefab, Tin Pot?  Try removing the AC-related scripts and just test getting gravity to work without the addition of AC code.
  • Nice, thanks for the "backward" response.

    About the gravity. I've tried the same prefab (just removing the AC script from the main GameObject) and the gravity works fine. I made this prefab using Tin Pot as a base (copying components values from one to another) and tweaking/adjusting the bones, animations, etc.
  • edited April 2014
    But again, what's the result of using the actual Tin Pot prefab in your game?  There are a couple of Rigidbody settings within the Player Inspector - have you tried changing them?
  • Oh, sorry, I forgot this part. :/
    I've duplicated again the Tin Pot prefab and, step by step, changed the TP model for my model.

    I've discovered the problem. When I'm using Mecanim Animation Controller in my model/prefab, the gravity just doesn't work correctly. When I remove the controller, everything works nicely.

    So, there's a way to fix this? Some kind of option to activate/deactivate? I'm very newbie with Mecanim system, so maybe I need to activate something and I just forgot. :/

    Thanks
  • Make sure you have no conflict in the way Root Motion is applied.  If your Player script is moving the model itself (i.e. Rely on Root Motion? in the Player Inspector is unchecked), be sure to also uncheck Apply Root Motion in the Mecanim Inspector.
  • edited April 2014
    Nice, I haven't saw that was activated. Unchecking the box fixes the gravity.
    Anyway, if I want to use rely motion to keep the movement animation more smoothly, how can I fix this gravity thing? Is something in animation file or in mecanim controller?

    Other thing, to make the speed float negative, what file I need to chance? I just haven't found The right file.

    Thanks
  • Gravity: Just make sure that both boxes are either unchecked or checked, and it should be fine.

    Negative speed float: It's automatic, you just need to amend your FSM to play a different animation if the speed becomes less than zero.
  • Oh, sorry, I have commented about the "negative speed float" here before but haven't got the new version. I have updated the AC here and now the animation works like a charm.

    About the gravity, just checking both boxes doesn't work. I searched about that in the internet and found that I need to change "Root Transformation (Y)" to Original and check the "Bake into Pose" box in every animation I want to work with.
    After this change, the gravity just back to normal.

    Thanks for all the help. :D
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.