Exemplo n.º 1
0
 void Awake()
 {
     gameControllerGameObject = GameObject.FindGameObjectWithTag(gameControllerTag);
     screenBoundariesX        = gameControllerGameObject.GetComponent <GameControllerScript>().ScreenBoundariesX; //Define local screen boundaries variables according to the GameController variables.
     screenBoundariesY        = gameControllerGameObject.GetComponent <GameControllerScript>().ScreenBoundariesY; //Define local screen boundaries variables according to the GameController variables.
     cannonTransform          = playerCannon.GetComponent <Transform>();
     rb2d  = GetComponent <Rigidbody2D>();
     trsfm = GetComponent <Transform>();
     playerResizeOnShoot = GetComponent <PlayerResizeOnShoot>();
 }