Exemplo n.º 1
0
        private void AddBeam(Vector2 position)
        {
            RapidFire beam = new RapidFire();

            beam.Initialize(GraphicsDevice.Viewport, beamTexture, position);
            rapidFire.Add(beam);
        }
Exemplo n.º 2
0
    private void ProjectileMenu(RapidFire rapid){
        showProjectile = EditorGUILayout.Foldout(showProjectile, "Projectile");
        if(showProjectile){
            EditorGUI.indentLevel++;

            rapid.ProjectileMass = EditorGUILayout.Slider(
                    new GUIContent(
                        "Mass",
                        "Mass of projectile at zero charge."),
                    rapid.ProjectileMass,
                    0.1f,
                    5f);

            rapid.ProjectileSize = EditorGUILayout.Slider(
                    new GUIContent(
                        "Size",
                        "Size of projectile at zero charge."),
                    rapid.ProjectileSize,
                    0.1f,
                    10f);

            rapid.ProjectileForce = EditorGUILayout.Slider(
                    new GUIContent(
                        "Force",
                        "Force of projectile at zero charge."),
                    rapid.ProjectileForce,
                    0.1f,
                    1000f);

            EditorGUI.indentLevel--;
        }
    }
Exemplo n.º 3
0
 void InitRapidFire()
 {
     if (rapid_fire == null)
     {
         rapid_fire = this.gameObject.AddComponent <RapidFire>();
     }
 }
Exemplo n.º 4
0
    private void ProjectileMenu(RapidFire rapid)
    {
        showProjectile = EditorGUILayout.Foldout(showProjectile, "Projectile");
        if (showProjectile)
        {
            EditorGUI.indentLevel++;

            rapid.ProjectileMass = EditorGUILayout.Slider(
                new GUIContent(
                    "Mass",
                    "Mass of projectile at zero charge."),
                rapid.ProjectileMass,
                0.1f,
                5f);

            rapid.ProjectileSize = EditorGUILayout.Slider(
                new GUIContent(
                    "Size",
                    "Size of projectile at zero charge."),
                rapid.ProjectileSize,
                0.1f,
                10f);

            rapid.ProjectileForce = EditorGUILayout.Slider(
                new GUIContent(
                    "Force",
                    "Force of projectile at zero charge."),
                rapid.ProjectileForce,
                0.1f,
                1000f);

            EditorGUI.indentLevel--;
        }
    }
Exemplo n.º 5
0
 private void CooldownField(RapidFire rapid){
     rapid.CooldownTime = EditorGUILayout.Slider(
             new GUIContent(
                 "Cooldown Time",
                 "Time required between rapids, in seconds. Minimum is 0.001s."),
             rapid.CooldownTime,
             rapid.MinimumCooldown,
             1);
 }
        public RapidFireVM(DynamoViewModel dynVM, RapidFire rapidFire)
        {
            DynamoVM  = dynVM;
            RapidFire = rapidFire;

            //todo create the relay command
            OpenRepoCommand = new RelayCommand(OpenRepo);

            _shortcuts = InitializeShortcutList();
        }
Exemplo n.º 7
0
 private void CooldownField(RapidFire rapid)
 {
     rapid.CooldownTime = EditorGUILayout.Slider(
         new GUIContent(
             "Cooldown Time",
             "Time required between rapids, in seconds. Minimum is 0.001s."),
         rapid.CooldownTime,
         rapid.MinimumCooldown,
         1);
 }
Exemplo n.º 8
0
 private void ProjectileRange(RapidFire rapid)
 {
     rapid.ProjectileRange = EditorGUILayout.Slider(
         new GUIContent(
             "Projectile Range",
             "Maximum range of the projectile."),
         rapid.ProjectileRange,
         20f,
         500f);
 }
Exemplo n.º 9
0
 private void HomingMenu(RapidFire rapid){
     showHoming = EditorGUILayout.Foldout(showHoming, "Homing");
     if(showHoming){
         EditorGUI.indentLevel++;
         rapid.ProjectileHomingRadius = EditorGUILayout.FloatField(
                 "Radius", rapid.ProjectileHomingRadius);
         rapid.ProjectileHomingForce = EditorGUILayout.FloatField(
                 "Force", rapid.ProjectileHomingForce);
         EditorGUI.indentLevel--;
     }
 }
Exemplo n.º 10
0
    // Initialization
    void Start()
    {
        slowMo     = transform.root.GetComponentInChildren <SlowMo> ();
        rapidFire  = transform.root.GetComponentInChildren <RapidFire> ();
        turretMode = transform.root.GetComponentInChildren <TurretMode> ();
        // Assign other ability references here

        // Testing:
        //UnlockSlowMo(1);
        //UnlockRapidFire(1);
        //UnlockTurretMode(1);
        //UnlockStarMode(1);
    }
Exemplo n.º 11
0
 private void HomingMenu(RapidFire rapid)
 {
     showHoming = EditorGUILayout.Foldout(showHoming, "Homing");
     if (showHoming)
     {
         EditorGUI.indentLevel++;
         rapid.ProjectileHomingRadius = EditorGUILayout.FloatField(
             "Radius", rapid.ProjectileHomingRadius);
         rapid.ProjectileHomingForce = EditorGUILayout.FloatField(
             "Force", rapid.ProjectileHomingForce);
         EditorGUI.indentLevel--;
     }
 }
Exemplo n.º 12
0
        public ActionResult <ApiResponse> SyncData(ApiPacketRequest apr)
        {
            ApiResponse apiResponse = new ApiResponse();
            RapidFire   rf          = new RapidFire(new AppConfig(), false);

            switch (apr.TableName)
            {
            default:
                var sqlString = GetUUIDBasedSQL(apr);
                apiResponse = rf.Api.ProcessSync(apr, null, string.IsNullOrEmpty(sqlString) ? null : sqlString, new SyncHandler());
                break;
            }

            apiResponse.Command = apr.Command;
            return(apiResponse);
        }
Exemplo n.º 13
0
    public override void OnInspectorGUI()
    {
        RapidFire rapid = (RapidFire)target;

        EditorGUILayout.LabelField("Active", rapid.Active.ToString());

        rapid.WeaponDamage = EditorGUILayout.FloatField(
            "Weapon Damage", rapid.WeaponDamage);
        rapid.EnergyCost = EditorGUILayout.FloatField(
            "Energy Cost", rapid.EnergyCost);

        HomingMenu(rapid);

        EditorGUILayout.LabelField("Cooldown Ready", rapid.CooldownReady.ToString());
        CooldownField(rapid);

        ProjectileMenu(rapid);

        ProjectileColor(rapid);

        ProjectileRange(rapid);
    }
Exemplo n.º 14
0
 private void ProjectileRange(RapidFire rapid){
 	rapid.ProjectileRange = EditorGUILayout.Slider(
 		new GUIContent(
 			"Projectile Range",
 			"Maximum range of the projectile."),
 		rapid.ProjectileRange,
 		20f,
 		500f);
 }
Exemplo n.º 15
0
 private void ProjectileColor(RapidFire rapid){
     rapid.ProjectileColor = colors[EditorGUILayout.Popup(
             "Projectile Color", colorDict[rapid.ProjectileColor], colors)];
 }
Exemplo n.º 16
0
    internal static void CombatRotation()
    {
        WoWUnit Target = ObjectManager.Target;

        if (Target.GetDistance < 10f && !_isBackingUp)
        {
            ToolBox.CheckAutoAttack(Attack);
        }

        if (Target.GetDistance > 10f && !_isBackingUp)
        {
            ReenableAutoshot();
        }

        // Aspect of the viper
        if (AspectViper.KnownSpell && AspectViper.IsSpellUsable && !Me.HaveBuff("Aspect of the Viper") &&
            Me.ManaPercentage < 30)
        {
            AspectViper.Launch();
        }

        // Aspect of the Hawk
        if (AspectHawk.KnownSpell && AspectHawk.IsSpellUsable && !Me.HaveBuff("Aspect of the Hawk") &&
            (Me.ManaPercentage > 90 || Me.HaveBuff("Aspect of the Cheetah")))
        {
            AspectHawk.Launch();
        }

        // Aspect of the Monkey
        if (AspectMonkey.KnownSpell && AspectMonkey.IsSpellUsable && !Me.HaveBuff("Aspect of the Monkey") &&
            !AspectHawk.KnownSpell)
        {
            AspectMonkey.Launch();
        }

        // Disengage
        if (Disengage.KnownSpell && Disengage.IsSpellUsable && ObjectManager.Pet.Target == Me.Target &&
            Target.Target == Me.Guid && Target.GetDistance < 10 && !_isBackingUp)
        {
            Disengage.Launch();
        }

        // Bestial Wrath
        if (BestialWrath.KnownSpell && BestialWrath.IsSpellUsable && Target.GetDistance < 34f &&
            Target.HealthPercent >= 60 && Me.ManaPercentage > 10 && BestialWrath.IsSpellUsable &&
            ((_settings.BestialWrathOnMulti && ObjectManager.GetUnitAttackPlayer().Count > 1) || !_settings.BestialWrathOnMulti))
        {
            BestialWrath.Launch();
        }

        // Rapid Fire
        if (RapidFire.KnownSpell && RapidFire.IsSpellUsable && Target.GetDistance < 34f &&
            Target.HealthPercent >= 80.0 &&
            ((_settings.RapidFireOnMulti && ObjectManager.GetUnitAttackPlayer().Count > 1) || !_settings.RapidFireOnMulti))
        {
            RapidFire.Launch();
        }

        // Kill Command
        if (KillCommand.KnownSpell && KillCommand.IsSpellUsable)
        {
            KillCommand.Launch();
        }

        // Raptor Strike
        if (RaptorStrike.KnownSpell && RaptorStrike.IsSpellUsable && Target.GetDistance < 6f && !RaptorStrikeOn())
        {
            RaptorStrike.Launch();
        }

        // Mongoose Bite
        if (MongooseBite.KnownSpell && MongooseBite.IsSpellUsable && Target.GetDistance < 6f)
        {
            MongooseBite.Launch();
        }

        // Feign Death
        if (FeignDeath.KnownSpell && FeignDeath.IsSpellUsable && Me.HealthPercent < 20)
        {
            FeignDeath.Launch();
            Fight.StopFight();
        }

        // Freezing Trap
        if (FreezingTrap.KnownSpell && FreezingTrap.IsSpellUsable && ObjectManager.Pet.HaveBuff("Mend Pet") &&
            ObjectManager.GetUnitAttackPlayer().Count > 1 && _settings.UseFreezingTrap)
        {
            FreezingTrap.Launch();
        }

        // Mend Pet
        if (ObjectManager.Pet.IsValid && MendPet.KnownSpell && MendPet.IsSpellUsable && ObjectManager.Pet.HealthPercent <= 30.0 &&
            !ObjectManager.Pet.HaveBuff("Mend Pet"))
        {
            MendPet.Launch();
        }

        // Hunter's Mark
        if (HuntersMark.KnownSpell && HuntersMark.IsSpellUsable && ObjectManager.Pet.IsValid && !HuntersMark.TargetHaveBuff &&
            Target.GetDistance > 13f && Target.IsAlive)
        {
            HuntersMark.Launch();
        }

        // Steady Shot
        if (SteadyShot.KnownSpell && SteadyShot.IsSpellUsable && Me.ManaPercentage > 30 && SteadyShot.IsDistanceGood && !_isBackingUp)
        {
            SteadyShot.Launch();
            Thread.Sleep(_steadyShotSleep);
        }

        // Serpent Sting
        if (SerpentSting.KnownSpell && SerpentSting.IsSpellUsable && !Target.HaveBuff("Serpent Sting") &&
            Target.GetDistance < 34f && ToolBox.CanBleed(Me.TargetObject) &&
            Target.HealthPercent >= 80 && Me.ManaPercentage > 50u && !SteadyShot.KnownSpell &&
            Target.GetDistance > 13f)
        {
            SerpentSting.Launch();
        }

        // Intimidation
        if (Intimidation.KnownSpell && Intimidation.IsSpellUsable && Target.GetDistance < 34f &&
            Target.GetDistance > 10f && Target.HealthPercent >= 20 && Me.ManaPercentage > 10 &&
            Intimidation.IsSpellUsable)
        {
            Intimidation.Launch();
        }

        // Arcane Shot
        if (ArcaneShot.KnownSpell && ArcaneShot.IsSpellUsable && Target.GetDistance < 34f &&
            Target.HealthPercent >= 30 && Me.ManaPercentage > 80 &&
            !SteadyShot.KnownSpell)
        {
            ArcaneShot.Launch();
        }
    }
Exemplo n.º 17
0
 private void ProjectileColor(RapidFire rapid)
 {
     rapid.ProjectileColor = colors[EditorGUILayout.Popup(
                                        "Projectile Color", colorDict[rapid.ProjectileColor], colors)];
 }