3 Demos and New Blending Feature

Jul 20, 2008 in ,
Lots of demos you can try this time - yay! Tip: For better performance, unload one demo before you view the next.

Instructions for all demos below

Walking-directionarrow keysanalog stick 1
Facing-directionW, A, S, Danalog stick 2
Jumpspacebutton A
Time slow down / speed upnumpad - / +-

You can control the characters with either the keyboard or with a game pad. With a game pad, such as an XBox 360 controller, the direction and speed can be controlled precisely with ease, while independently controlling facing direction with the secondary stick.

Climb the crates and boards. Use shift to run; default is walking. Note that this demo only uses one animation for walking and one for running.

In this demo the terrain can be dynamically controlled with the sliders at the top. You can create stairs, slopes, and various combinations. The terrain will reflect the changes once the character has walked a little distance to the left or right. Enable manual mode to control the character yourself, as described above. This demo uses four animations for walking (forward, backwards, and sideways) and also four for running.

Walk around this structure in space with crazy gravity! (Nobody said anything about Mario Galaxy...)

Animation groups

I have worked hard on finding a way of making the Locomotion System easy to integrate with an existing animation framework in a game while keeping it flexible.

I have now implemented a feature where animations used by the Locomotion System are grouped together in animation groups. For example, animations for walking and running in different directions could be put in a single animation group.

The group as a whole can be controlled manually the same way as regular animations are controlled in Unity, while the blending of the individual animations in a group are automatically controlled by the Locomotion System. Furthermore, the system supports using multiple animation groups, so e.g. one group can be used for normal walking and running (in all directions), and another group for sneaking (in all directions).

The new feature can be seen in the demos above in two ways:
  • When the character jumps, an animation is cross-faded in that is not controlled by the Locomotion System. This way the feet do not attempt to stay on the ground while the character is jumping.
  • When the character is standing still for a little while, an "waiting" animation is cross-faded in. Since this animation is also controlled by the Locomotion System, the feet stay properly grounded.

Testing the Locomotion System

I make the Locomotion System as my Master Thesis in collaboration with Unity Technologies. It will be available for free for users of Unity once it is finished.

As a part of my thesis, I want to test the usability of the system. If you are a Unity user and would like to try out the system and help me by evaluating it, please let me know! The Locomotion System is by no means finished yet, but it is now almost at a stage where it is ready for preliminary testing.

Also, comments are much appreciated!
Read More »

Locomotion System Overview

When people see the Locomotion System in action, they sometimes get incorrect ideas about what the system can and cannot. Here is a brief description that can hopefully make things a bit more clear.

The Locomotion System for Unity automatically blends your keyframed or motion-captured walk and run cycles and then adjusts the movements of the bones in the legs to ensure that the feet step correctly on the ground. The system can adjust animations made for a specific speed and direction on a plain surface to any speed, direction, and curvature, on any surface, including arbitrary steps and slopes.

The Locomotion System does not enforce any high level control scheme but rather lets you move your character around by any means you desire. The Locomotion System silently observes the position, alignment, velocity and rotational velocity of your character and deduces everything from that, along with some raycasts onto the ground.

This flexibility means that you can use a CharacterController, a RigidBody (those are standard components in Unity) or something else entirely to move your character around in the world, exactly as you would normally do.

The Locomotion System is not:
  • A physics-based system or active animated ragdoll system.
    The system has no integration with the physics simulation. It is purely kinematic, though it does base the kinematics on some raycasts onto the geometry of the ground.
  • A behavior-based system.
    The system cannot make the character react instinctively to external forces such as being punched, tripping and falling, or being shot. The system only blends and slightly adjusts your existing animations.
  • A unified system that can be used for all animation of a character.
    The system only controls the legs. (The whole body is typically implicitly controlled since the system blends together multiple full body animations. However, this can be overridden by the user with specific animations for the upper body, using the usual means available in Unity.)
Read More »