Example #1
0
 protected void initializeBullet()
 {
     spawn_timer = spawn_time;
     rb2d        = gameObject.GetComponent <Rigidbody2D>();
     tsfm        = gameObject.GetComponent <Transform>();
     ID_player   = gameObject.GetComponent <player_ID>();
 }
Example #2
0
    // Use this for initialization when application runs but after script is initialized
    void Start()
    {
        rb2d           = gameObject.GetComponent <Rigidbody2D> ();
        tsfm           = gameObject.GetComponent <Transform> ();
        hitBox         = transform.FindChild("Driver_Hitbox");
        p_id           = GetComponent <player_ID>();
        speed_level    = min_speed;
        rewired_player = ReInput.players.GetPlayer(p_id.player_number);

        makeDefender();
    }
Example #3
0
    // Use this for initialization
    void Start()
    {
        tsfm       = gameObject.GetComponent <Transform> ();
        shot_spawn = tsfm.GetChild(0);
        p_id       = GetComponent <player_ID>();


        if (driver != null)
        {
            p_id.player_number = driver.getPlayerID();
            rewired_player     = ReInput.players.GetPlayer(p_id.player_number);
        }
    }
Example #4
0
 // use that for instantiation
 void Awake()
 {
     rb2d = GetComponent <Rigidbody2D>();
     tsfm = GetComponent <Transform>();
     p_id = GetComponent <player_ID>();
 }
Example #5
0
 // Use this for initialization
 void Start()
 {
     driver = gameObject.GetComponentInParent <player_driver>();
     p_id   = gameObject.GetComponentInParent <player_ID>();
 }