O'Reilly logo

Beginning 3D Game Development with Unity 4: All-in-One, Multi-Platform Game Development, Second Edition by Sue Blackman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 10

image

Exploring Transitions

In the previous chapter, you got the first part of the state engine working. The ObjectLookup script is now able to change the state of an object and process the actions that are identified with the transitions into its new state. It does so by using the first two pieces of data in the correct element in the correct Lookup State array. While the first two are essentially a lookup table for the picked object, the rest are instructions for handling the optional auxiliary objects that are also a part of the same transition.

As a reminder, the auxiliary objects are processed in pairs. The first piece of data is the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required