Search Unity

Ledge Grab Mechanics

Discussion in 'Scripting' started by arthur_fukushima, Dec 19, 2014.

  1. arthur_fukushima

    arthur_fukushima

    Joined:
    Nov 12, 2014
    Posts:
    28
    Hi!

    I know this must be one of the most asked topics, but this one has a different focus, I swear!

    So, I've searched a lot about the climbing, ledge-grab and others Assassins Creed (and other games) mechanics, and I found some really good materials (examples below) that can help me reach my goal.

    Uncharted Animation System (Amazing video!)
    http://www.gdcvault.com/play/1012300/Animation-and-Player-Control-in

    Final IK Plugin (Looks awesome, just saw the videos...)
    http://forum.unity3d.com/threads/fi...m-look-at-fabrik-ccd-ik-beta-released.222685/

    And others more 'informal' ideias related to the solution, but none of them mentions my doubt.

    - The games that use this mechanics, use physics or something similar to mecanim root motion solution (movement controlled by animations clip)?
    - What is the best way to reach the results? (Not asking codes, just ideas).

    The problems using physics (That I found):
    - Tricky to sync the movement with the player animation (Like when he climbs a ledge, breaks the physics rulles...)
    - Sliding on not regular floors (I've tried a lot (really, a lot) of different solutions, none of them works in every single situation, just workarounds so far...).

    The problems using mecanim animations (That I found):
    - Do not work very nice with physics objects.
    - Feels like I have fewer control over the mechanics!

    So, can anyone who worked with this mechanics (or not) share his experience and ideias about this, please?

    Thanks!
     
    vivekboss99 and sami1592 like this.
  2. MakeCodeNow

    MakeCodeNow

    Joined:
    Feb 14, 2014
    Posts:
    1,246
    Here are a few basic ideas common to most of these AAA games:
    * The player controller is a giant, complex, hierarchical finite state machine, which you need just to manage all of the complex control logic.
    * The player constantly goes between physics movement and root motion movement depending on activity. Usually running is physics based, climbing is more animation based.
    * Procedural animations like IK are layered over the basic blends to "fix up" the positions of hands and feet to match the environment.
    * Small bits of dangly cloth, long hair, or other simple dynamics objects are added to help visually smooth out any pops (and to look cool).
    * The characters have hundreds of animations, many of which are very short and special case.
    * It takes many programmers and animators man years to get it all right.
     
  3. recon0303

    recon0303

    Joined:
    Apr 20, 2014
    Posts:
    1,634
    I been programming a long time, this is one of the harder things I think to do, the above poster is correct.

    You can use triggers near the top of the ledge, distance from hands to the trigger and time animations.

    I actually been making an asset that takes others sprites and 3D characters to work with ledge, climbing, and maybe ropes as well, for 2d and 3D.

    But do not want to give out to much info on it yet. Good luck, you will need it!
     
    sami1592 and arthur_fukushima like this.
  4. sami1592

    sami1592

    Joined:
    Sep 18, 2013
    Posts:
    57
    so ... for a team of 3 people who are making a 3D side-scrolling game using root motion will be a bad choice?