示例#1
0
        public CrossFusionFormation(Game game, int shipWidth, int shipHeight, Vector2 pos)
        {
            //Remember the initial position
            base.fixedPoint = pos;
            base.game       = game;
            //Set up the Line Formation
            NormalFormation p1NormalFormation = new NormalFormation(4, shipWidth, shipHeight, pos);

            p1NormalFormation.playerIndex       = PlayerIndex.One;
            p1NormalFormation.usedByBothPlayers = false;

            //Set up the Line Formation
            LineFormation p2LineFormation = new LineFormation(4, shipWidth, shipHeight, pos);

            p2LineFormation.playerIndex       = PlayerIndex.Two;
            p2LineFormation.usedByBothPlayers = false;

            base.playerFormationList.Add(PlayerIndex.One, p1NormalFormation);
            base.playerFormationList.Add(PlayerIndex.Two, p2LineFormation);

            CrossFusionShockwave swave = new CrossFusionShockwave(game, 1);

            //Change the shockwave's color to green
            swave.color = Color.Green;
            if (!Defines.particleManager.HasTypeAlready(typeof(CrossFusionShockwave)))
            {
                Defines.particleManager.Register(swave);
            }
        }
        public CrossFusionFormation(Game game, int shipWidth, int shipHeight, Vector2 pos)
        {
            //Remember the initial position
            base.fixedPoint = pos;
            base.game = game;
            //Set up the Line Formation
            NormalFormation p1NormalFormation = new NormalFormation(4, shipWidth, shipHeight, pos);
            p1NormalFormation.playerIndex = PlayerIndex.One;
            p1NormalFormation.usedByBothPlayers = false;

            //Set up the Line Formation
            LineFormation p2LineFormation = new LineFormation(4, shipWidth, shipHeight, pos);
            p2LineFormation.playerIndex = PlayerIndex.Two;
            p2LineFormation.usedByBothPlayers = false;

            base.playerFormationList.Add(PlayerIndex.One, p1NormalFormation);
            base.playerFormationList.Add(PlayerIndex.Two, p2LineFormation);

            CrossFusionShockwave swave = new CrossFusionShockwave(game, 1);
            //Change the shockwave's color to green
            swave.color = Color.Green;
            if(!Defines.particleManager.HasTypeAlready(typeof(CrossFusionShockwave)))
                Defines.particleManager.Register(swave);
        }