Ejemplo n.º 1
0
 private ShipManager()
 {
     this.shipReadyState         = new ShipReadyState();
     this.shipMissileFlyingState = new ShipMissileFlyingState();
     this.shipEndState           = new ShipEndState();
     this.cannonShip             = null;
     this.missile = null;
 }
        private ShipManager()
        {
            // Store the states
            this.pStateReady                  = new ShipStateReady();
            this.pStateMissileFlying          = new ShipMissileFlyingState();
            this.pStateDead                   = new ShipDeadState();
            this.pStateStopLeft               = new ShipStopLeftState();
            this.pStateStopRight              = new ShipStopRightState();
            this.pStateStopLeftMissileFlying  = new ShipStopLeftMissileFlyingState();
            this.pStateStopRightMissileFlying = new ShipStopRightMissileFlyingState();


            // set active
            pShip    = null;
            pMissile = null;
        }