Steve Starwell

Steve Starwell is a platformer that utilizes backwards momentum that comes from a star cannon, similar to a rocket jump. It is a game submitted for the April 2022 Game Jam in the Gamecraft club. For this project we had 48 hours of development time with the given theme "All Star." Links to the GitHub and Itch.io webpage are below

Contributions
  • Star Collectable

  • Player Aim

  • Stargun Controller

  • Falling Platforms

  • Sound Objects

Scripts

Star Collectable

This script was made so that when the player touches a star, it plays a sound effect, adds an ammo, and destroys the star

Player Aim

In this code snippet if the player puts the cursor at a certain position, the game calculates the angle at which the gun should be pointing

Stargun Controller

This section of the stargun controller script has three methods: Shoot(), increaseAmmo() and getAmmo(). The shoot method determines if the player has ammo and if they do plays a sound, animation, creates a star prefab, applies force on the player, and decreases the ammo by one. The increase ammo method adds one ammo. Lastly, the get ammo method returns the amount of ammo the player has.

Falling Platform

The falling platform script does exactly what you thing it would. The awake method sets the initial 2D rigidbody. The update method detects if the player is close enough to begin falling, if it is, the rigidbody of the platform will set it's velocity to a downwards value

Sound

Each individual sound object is given a name, audio clip, volume, pitch, spatial blend, max distance, loop, and source. The spatial blend determines if the sound is 2D or 3D (changes based on distance). The max distance determines the max distance the sound can be heard. Loop determines if the sound is loopable or not. Lastly, source determines where the sound comes from. The public variables allow for each sound object to have individually selectable attributes.