Example #1
0
    // From GUI Class 02



    // Use this for initialization
    void Start()
    {
        companion    = GameObject.FindGameObjectWithTag("Companion");
        playerphysic = GameObject.FindGameObjectWithTag("Player").GetComponent <PlayerPhysic> ();

        //animatorPlayer = GetComponent <Animator> ();
    }
Example #2
0
    void Start()
    {
        singleton = this;
        rb        = GetComponent <Rigidbody2D> ();

        //initilize Player
        thrustMaxSpeed     = PlayerModels.PlayerInstance.GetMaxSpeedPlayer();
        thrustAcceleration = PlayerModels.PlayerInstance.GetAccelerationPlayer();
        revThrustMaxSpeed  = PlayerModels.PlayerInstance.GetRevMaxSpeedPlayer();
        rotationSpeed      = PlayerModels.PlayerInstance.GetRotationSpeedPlayer();
        fuelTank           = PlayerModels.PlayerInstance.GetFuelPlayer();
        playerStrength     = PlayerModels.PlayerInstance.GetStrengthPlayer();
    }
Example #3
0
 void Start()
 {
     // you have to have the camera first and then give the camera a target, which is th play
     wind.Play();
     Intro.Play();
     companion = GameObject.FindGameObjectWithTag("Companion");
     if (companion != null)
     {
         companion.GetComponent <Companion>().enabled = false;
     }
     playerphysic   = player.GetComponent <PlayerPhysic>();
     playerScript   = player.GetComponent <Player>();
     Time.timeScale = 1;
 }
Example #4
0
 void Awake()
 {
     input  = GetComponent <PlayerInput>();
     physic = GetComponent <PlayerPhysic>();
 }
Example #5
0
 // Use this for initialization
 void Start()
 {
     playerphysic = GetComponent <PlayerPhysic>();
     platforms    = GameObject.FindGameObjectsWithTag("Platform");
     player       = GetComponent <Player> ();
 }
Example #6
0
 void Awake()
 {
     playerInput      = GetComponent <PlayerInputHandler> ();
     playerProperties = GetComponent <PlayerProperties> ();
     physics          = GetComponent <PlayerPhysic> ();
 }
 void Start()
 {
     Player = FindObjectOfType <PlayerPhysic>();
 }