- Unity Artificial Intelligence Programming
- Dr. Davide Aversa Aung Sithu Kyaw Clifford Peters
- 162字
- 2021-06-10 18:57:48
Finite State Machines
In this chapter, we'll learn how to implement a Finite State Machine (FSM) in a Unity3D game by studying the simple tank game-mechanic example that comes with this book.
In our game, the player controls a tank. The enemy tanks move around the scene, following four waypoints. Once the player's tank enters the vision range of the enemy tanks, they will start chasing it; then, once they are close enough to attack, they'll start shooting at our player's tank.
To control the AI of our enemy tanks, we use FSM. First, we'll use simple switch statements to implement our tank AI states, then we'll use an FSM framework based on and adapted from the C# FSM framework that can be found at http://wiki.unity3d.com/index.php?title=Finite_State_Machine.
The topics we will be covering in this chapter are the following:
- The player's tank
- The Bullet class
- Setting up waypoints
- The abstract FSM class
- The enemy tank AI
- Using an FSM framework
- RCNP實驗指南:構建高級的路由互聯網絡(BARI)
- Aptana Studio Beginner's Guide
- 物聯網識別技術
- Building Django 2.0 Web Applications
- 智能網聯汽車V2X與智能網聯設施I2X
- Learning Karaf Cellar
- 物聯網關鍵技術及應用
- 智慧城市中的移動互聯網技術
- 中國互聯網發展報告2018
- Spring 5.0 Projects
- jQuery Mobile Web Development Essentials
- INSTANT LinkedIn Customization How-to
- Dart Cookbook
- 5G非正交多址接入技術:理論、算法與實現
- 物聯網與智慧農業