Back to Portfolio

Functions for player dodging and special attack. The dodge function emits particles, changes the player's color slightly, removes their collision with enemies and projectiles, sends them in the direction they're moving quickly, and then starts a short cooldown. The special attack instantiates a scene which fires projectiles in a circle, and plays a sound effect and animation.


Function for firing a projectile. The Muzzle node is always pointed towards the player's mouse, so when the projectile is instantiated, it fires in that direction.