Exemplo n.º 1
0
    public Escort(Transform me)
    {
        Name = "Escort";

        Ship = me;

        DecayFactor  = 5;        //Set new variables here to ensure they're overwritten
        delayCounter = 0;        //I don't understand the other methods of doing this so
        fireDelay    = 0.1f;     //this will have to do for now

        ShipTypes sl    = GameObject.FindGameObjectsWithTag("Library")[0].GetComponent <ShipTypes>();
        int       index = sl.GetIndexFromName(Name);

        sprite = sl.Sprites[index];
        Bullet = sl.Bullets[index];
        shield = sl.Secondary[index];
    }