Пример #1
0
        public WeaponModule CreateEnemyWeaponFanShot(
            float frequency,
            float damage,
            float projectileSpeed,
            float rotAngleMin,
            float rotAngleMax,
            float rotCycleDuration
            )
        {
            WeaponModule     module = new WeaponModule();
            WeaponModuleUnit unit   = CreateWeaponModuleUnitHorizontal(
                frequency,
                damage,
                projectileSpeed,
                new SKPoint(0, Settings.Enemy2.Weapon.yCoords),
                new SKSize(
                    Settings.WeaponFanShot.projSizeX,
                    Settings.WeaponFanShot.projSizeY
                    ),
                new SKSize(
                    Settings.WeaponFanShot.explSizeX,
                    Settings.WeaponFanShot.explSizeY
                    )
                );

            unit.SetRotating(rotAngleMin, rotAngleMax, rotCycleDuration);
            module.AddWeaponUnit(unit);
            return(module);
        }
Пример #2
0
        public WeaponModule CreatePlayerWeapon(
            float frequency,
            float damage,
            float projectileSpeed
            )
        {
            WeaponModule module = new WeaponModule();

            module.AddWeaponUnit(
                CreateWeaponModuleUnitHorizontal(
                    frequency,
                    damage,
                    projectileSpeed,
                    new SKPoint(0, Settings.Player.Weapon.yCoord),
                    new SKSize(
                        Settings.WeaponPlayer.projSizeX,
                        Settings.WeaponPlayer.projSizeY
                        ),
                    new SKSize(
                        Settings.WeaponPlayer.explSizeX,
                        Settings.WeaponPlayer.explSizeY
                        )
                    )
                );
            return(module);
        }
Пример #3
0
        public WeaponModule CreateEnemyWeaponFourShot(
            float frequency,
            float damage,
            float projectileSpeed
            )
        {
            SKSize projSize = new SKSize(
                Settings.WeaponFourShot.projSizeX,
                Settings.WeaponFourShot.projSizeY
                );
            SKSize explSize = new SKSize(
                Settings.WeaponFourShot.explSizeX,
                Settings.WeaponFourShot.explSizeY
                );
            WeaponModule module = new WeaponModule();

            module.AddWeaponUnit(CreateWeaponModuleUnitHorizontal(
                                     frequency,
                                     damage,
                                     projectileSpeed,
                                     new SKPoint(0, Settings.Enemy1.Weapon.yCoords1),
                                     projSize,
                                     explSize,
                                     Settings.Enemy1.Weapon.phaseShift1
                                     ));
            module.AddWeaponUnit(CreateWeaponModuleUnitHorizontal(
                                     frequency,
                                     damage,
                                     projectileSpeed,
                                     new SKPoint(0, Settings.Enemy1.Weapon.yCoords2),
                                     projSize,
                                     explSize,
                                     Settings.Enemy1.Weapon.phaseShift2
                                     ));
            module.AddWeaponUnit(CreateWeaponModuleUnitHorizontal(
                                     frequency,
                                     damage,
                                     projectileSpeed,
                                     new SKPoint(0, Settings.Enemy1.Weapon.yCoords3),
                                     projSize,
                                     explSize,
                                     Settings.Enemy1.Weapon.phaseShift3
                                     ));
            module.AddWeaponUnit(CreateWeaponModuleUnitHorizontal(
                                     frequency,
                                     damage,
                                     projectileSpeed,
                                     new SKPoint(0, Settings.Enemy1.Weapon.yCoords4),
                                     projSize,
                                     explSize,
                                     Settings.Enemy1.Weapon.phaseShift4
                                     ));
            return(module);
        }