top of page
DevLogStart

Trailer by Maximillian Wallis Hjorth

Gun Puppeteer - Dev Log

Gun Puppeteer is a 2D physics based action shooter set in soviet russia where you and all your enemies are matryoshka dolls. In this project my main task was to design and code the enemy ai behaviour. We created 3 different enemy types, each with their own weapons, stats, movement and strategies. 

GunPuppeteerPoster.PNG
GPclassdiagram.PNG
Classes and inheritence

The enemy AI behaviour was programmed in C# and structured by classes and inheritence. First we made the parent enemy script called EnemyMatryoshka.cs that contained the basic behaviours, funtionality and parameters that all enemies needed. Then we made 3 seperate scripts that inherited from EnemyMatryoshka.cs, 1 for each enemy type.

​

​

States

Even though all enemies had different ways of behaving, each enemy had the same different set of states they transitioned between depending on the situation. We used an enum to differentiate between these states and a switch to change the current active state.

GPstatemachineEnum.png
GPswitch.png
Small enemy
Patrol
Attack
Normal Enemy
Patrol
Attack
Big Enemy
Patrol
Attack
Bottom
bottom of page