PLAYER


To start our deeper dive into more specific areas of my senior project, why not talk about what is easily the most important thing, you! The player! Let me properly introduce you to the protagonist of Paint Knight… Paint Knight. Our plucky little knight is the newest of the courtly painters and simply cannot catch a break. Unable to win support from the crowd, Paint Knight resides himself to a sad slumber only to find the world drained of color when he awakes. It is up to him to enter the now corrupted castle and stop the spread of this monochromatic terror. 

In the game itself, Paint Knight has the classic abilities to run and jump to traverse the levels along with a group of different paint brushes to help him defeat the enemies patrolling the different castle rooms. Each brush, a different style of brush and color, gives the player a different way to interact with the levels and enemies around them while also spurting paint splats everywhere!

The Red brush (representing the basic paint brush) acts as Paint Knight’s sword. He can deal 1 damage to any enemy he whacks with it. The Blue Roller Brush is the first brush found from exploring the castle and belongs to the now corrupted Roller Knight (the games boss). This brush can stun enemies it touches. The Yellow Angle brush is the second brush found from exploring the castle and belongs to Angle Knight (mysteriously missing within the corruption). This brush takes the two abilities and merges them along with allowing Paint Knight dash. The Green Fan Brush (and its owner Fan Knight) have disappeared in the corruption, unable to be obtained. This is to say that the brush is actually in the game files, but not accessible. Only its banner in the public court remains to remind you of it.

From a technical perspective, getting the player working and staying modular a tricky task. As displayed in the images below, you can see under the hood of how he is actually running. A state machine tells the game which brush the player is holding at that moment and what animations to play. In total, the player has about 20 different animations between the four brushes and what actions can take place.

The player object is a simple box collider while a toggled circle collider acts as a trigger for the player's “attack area.” This is synced to the attack animations so to only be active during those animations. Each major section of the player was broken into its own script.


Previous
Previous

OVERVIEW

Next
Next

ENEMIES