Category Archives: Unity

Posts about my work with the Unity 3D game engine

Unity – How to make things see where they’re going

While developing a game, I wanted to enable the autonomous characters to see where they’re going – that is, to tell them what they’re about to stumble into, without using colliders. The answer was to cast a Ray, angled slightly downward, in front of the character, so it can see if it’s about to walk into a tree, or off a cliff, before it happens. Continue reading Unity – How to make things see where they’re going

Unity – Animation Blend Trees

How to create infinitely varied animation with your Unity characters.

A very powerful feature in the Unity Editor is the Blend Tree. This is an extension to an Animation Controller, which allows you to ‘blend’ the joint movements of multiple animations and control the ratio of blending with one or more parameters.

Continue reading Unity – Animation Blend Trees

Getting started with UnitySteer

UPDATE: The last 2 major releases of Unity adversely affected how UnitySteer steering behaviours play with non-kinematic RigidBody components. If you’re having trouble combining your physics with steering forces, see this workaround I added, which may or may not become a pull request at some point (although I think the UnitySteer project is not actively maintained any more).

There are several AI steering libraries available for Unity, but I settled on UnitySteer due its similarity to OpenSteer for C++. Continue reading Getting started with UnitySteer