예제 #1
0
        public override void Destroy()
        {
            //spawn powerup
            if (Utility.RandomDouble() < BombermanSettings.UPGRADE_SPAWN_CHANCE)
            {
                if (BoardGameControlItem.State == BoardGameState.Active)
                {
                    BombermanUpgrade upgrade = BombermanUpgrade.GetRandomUpgrade();
                    upgrade.RegisterToBoardGameControlItem(BoardGameControlItem, new Point3D(Offset.X, Offset.Y, Offset.Z + 3));
                }
            }

            base.Destroy();
        }
예제 #2
0
        public override void Destroy()
        {
            //spawn powerup
            if (Utility.RandomDouble() < BombermanSettings.UPGRADE_SPAWN_CHANCE)
            {
                if (BoardGameControlItem.State == BoardGameState.Active)
                {
                    //BombermanUpgrade upgrade = BombermanUpgrade.GetRandomUpgrade();
                    BombermanUpgrade upgrade = BombermanUpgrade.GetRandomUpgrade(BoardGameControlItem._AllowSpeedUpgrade, BoardGameControlItem._AllowDetonatorUpgrade,
                                                                                 BoardGameControlItem._AllowBaddaBoomUpgrade, BoardGameControlItem._AllowBlastStrengthUpgrade);
                    upgrade.RegisterToBoardGameControlItem(BoardGameControlItem, new Point3D(Offset.X, Offset.Y, Offset.Z + 3));
                }
            }

            base.Destroy();
        }