Saturday, 23 February 2013

Brains Eden Games Jam 2012: Ascend

Ascend was created for the 2012 Brains Eden Games Jam in a group of 5 representing Anglia Ruskin University. I was one of two programmers for the team, and created the basic movements for the player and the enemy for the game. The goal of the game is to ascend from hell to heaven before the black smoke catches up to you.
 
//Fixes movement to the direction of the camera for moving Left & Backward
else if(Input.GetAxis("Vertical") < 0 && Input.GetAxis("Horizontal") < 0) //Left Backward
  {
       move += Vector3(Input.GetAxis("Horizontal") / 2,0,Input.GetAxis("Vertical") / 2);
       transform.rotation = Quaternion.Euler(0,Camera.mainCamera.transform.eulerAngles.y,0);
  }
 
//Change the volume of the smoke sound depending of the players distance for the smoke.
function smokeSoundUpdate()
{
     var resultA : float;
     var resultB : float;
     var volume : float;

     resultA = (cloudEnd + cloudPosStart.position.y) - cloudPosStart.position.y;
     resultB = playerPos.position.y - cloudPosStart.position.y;
     volume = (resultB / resultA);
     if(volume < 0.2)
         volume = 0.2;

     cloudMusic.audio.volume = volume;
}
 
 
 



No comments:

Post a Comment