Ejemplo n.º 1
0
    void Destroy()
    {
        fleetManager.RemoveShip(owner.GetComponent <Boid>());

        //fleetManager.ships.Remove(owner.GetComponent<Boid>());
        //fleetManager.borg.GetComponent<Borg>().ships.Remove(owner.GetComponent<Boid>());
        fleetManager.shipsDestroyed++;
        owner.GetComponent <ObstacleAvoidance>().enabled = false;
        owner.GetComponent <StateMachine>().ChangeState(new WreckState());
    }