[SPQR] Warlock Afli profile menu

User Tag List

Results 1 to 13 of 13
  1. #1
    lockslash's Avatar Member
    Reputation
    3
    Join Date
    Sep 2012
    Posts
    42
    Thanks G/R
    3/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [SPQR] Warlock Afli profile

    Hi,

    here one basic profile for Lock Afli...


    ============================================

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using SPQR;
    using MySPQR;

    namespace SPQR.Engine
    {
    class Warlock : Engine.FightModule
    {
    public override string DisplayName
    {
    get { return "Warlock Afli"; } //This is the name displayed in SPQR's Class selection DropdownList
    }

    internal enum Spells : int //This is a convenient list of all spells used by our combat routine
    { //you can have search on wowhead.com for spell name, and get the id in url
    MaleficGrasp = 686, // yesss 686 in afli are correct
    Haunt = 48181,
    DrainSoul = 1120,
    Corruption = 172,
    Agony = 980,
    UnstableAffliction = 30108,
    DSMisery = 77801, // yess afli
    LifeTap = 1454,
    DrainLife = 689,
    UnendingResolve = 104773,
    }
    internal enum Auras : int //This is another convenient list of Auras used in our combat routine
    { //you can have those in wowhead.com (again) and get the id in url
    Haunt = 48181,
    Corruption = 172,
    Agony = 980,
    UnstableAffliction = 30108,
    }

    public override void CombatLogic() //This is the DPS / healing coutine, called in loop by SPQR all code here is executed
    {
    var TARGET = MySPQR.Internals.ObjectManager.Target;
    var ME = MySPQR.Internals.ObjectManager.WoWLocalPlayer;

    if(TARGET.HealthPercent > 80)
    CastSpellById((int)Spells.DSMisery);

    if(!TARGET.HasAurabyId((int)Auras.Agony))
    CastSpellById((int)Spells.Agony);

    if(!TARGET.HasAurabyId((int)Auras.Corruption))
    CastSpellById((int)Spells.Corruption);

    if (!TARGET.HasAurabyId((int)Auras.UnstableAffliction))
    CastSpellById((int)Spells.UnstableAffliction);

    if(!TARGET.HasAurabyId((int)Auras.Haunt))
    CastSpellById((int)Spells.Haunt);

    if(TARGET.HealthPercent < 21 )
    CastSpellById((int)Spells.DrainSoul);

    CastSpellById((int)Spells.MaleficGrasp);

    }

    public static void CastSpellById(int spellId) //This is a *usermade* function to evaluate if the given spell (spellId) can be cast
    {
    if (MySPQR.Internals.ObjectManager.Target.IsValid) /*return true if the Target is valid(exist) or not dead*/
    {
    if (MySPQR.Internals.ActionBar.CanCast(spellId)) /*return true if your char can use the spell (check cooldown and global cooldown*/
    {
    MySPQR.Internals.ActionBar.GetSlotById(spellId).Execute(); /*if all is ok, this will get the ActionBarSlot for your spell,
    and execute the right Keybind to cast it*/
    }
    }
    }

    public override void OnLoad() //This is called when the Customclass is loaded in SPQR
    {

    }

    public override void OnClose() //This is called when the Customclass is unloaded in SPQR
    {

    }

    public override void OnStart() //This is called once, when you hit CTRL+X to start SPQR combat routine
    {

    }

    public override void OnStop() //This is called once, when you hit CTRL+X to stop SPQR combat routine
    {

    }
    }
    }

    [SPQR] Warlock Afli profile
  2. #2
    Nonowmana's Avatar Contributor
    Reputation
    125
    Join Date
    Apr 2009
    Posts
    259
    Thanks G/R
    0/4
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Nice to you to share profiles
    Anthraxbot & SPQR Creator / Administrator

  3. #3
    lockslash's Avatar Member
    Reputation
    3
    Join Date
    Sep 2012
    Posts
    42
    Thanks G/R
    3/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    thanks to you for your work!!

    One question, if are casting one channeling spell, I think is it interrupted if another "upper" spell condition are true

    Maybe you can add one condition (Interruptable (Y/N) to spell or similar...

  4. #4
    Nonowmana's Avatar Contributor
    Reputation
    125
    Join Date
    Apr 2009
    Posts
    259
    Thanks G/R
    0/4
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by lockslash View Post
    thanks to you for your work!!

    One question, if are casting one channeling spell, I think is it interrupted if another "upper" spell condition are true

    Maybe you can add one condition (Interruptable (Y/N) to spell or similar...
    i'll add, one condition for next version to check if we are casting/channeling before launch another spell.
    Anthraxbot & SPQR Creator / Administrator

  5. #5
    lockslash's Avatar Member
    Reputation
    3
    Join Date
    Sep 2012
    Posts
    42
    Thanks G/R
    3/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Nonowmana View Post
    i'll add, one condition for next version to check if we are casting/channeling before launch another spell.
    OK, but in certain cases is necessary interrupt the actual channeling to cast another... for exemple in warlock afli
    if target.life>20% channel Malefic Grasp
    when target.life<=20% channel Drain Soul

    Another question, all logic comparators are fuctionally? this <> <= => works?

    Thanks

  6. #6
    lockslash's Avatar Member
    Reputation
    3
    Join Date
    Sep 2012
    Posts
    42
    Thanks G/R
    3/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Life Tap conditions

    Ei nonowmana,

    in your profile I read this conditions

    if(ME.HealthPercent > 60 && ME.ManaPercent < 40)
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.LifeTap);

    The correct are the inverse, if not you burn all your mana...

    if(ME.HealthPercent < 60 && ME.ManaPercent > 40)
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.LifeTap);

    not??

  7. #7
    lockslash's Avatar Member
    Reputation
    3
    Join Date
    Sep 2012
    Posts
    42
    Thanks G/R
    3/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    > 160K DPS versus only 1 dummy with no FPS lost

    Here you are the basic Afli warlock... With only the basic logic I make >160K DPS on dummy (only 1 dummy, not AOE) and FPS good

    XD

    =======================================

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using SPQR;
    using MySPQR;

    namespace SPQR.Engine
    {
    class Warlock : Engine.FightModule
    {
    public override string DisplayName
    {
    get { return "Warlock Afli"; } //This is the name displayed in SPQR's Class selection DropdownList
    }

    internal enum Spells : int //This is a convenient list of all spells used by our combat routine
    { //you can have search on wowhead.com for spell name, and get the id in url
    MaleficGrasp = 686, //
    Haunt = 48181,
    DrainSoul = 1120,
    Corruption = 172,
    Agony = 980,
    UnstableAffliction = 30108,
    DSMisery = 77801, //
    LifeTap = 1454,
    DrainLife = 689,
    UnendingResolve = 104773,
    }
    internal enum Auras : int //This is another convenient list of Auras used in our combat routine
    { //you can have those in wowhead.com (again) and get the id in url
    Haunt = 48181,
    Corruption = 146739, //
    Agony = 980,
    UnstableAffliction = 30108,
    }

    public override void CombatLogic() //This is the DPS / healing coutine, called in loop by SPQR all code here is executed
    {
    var TARGET = MySPQR.Internals.ObjectManager.Target;
    var ME = MySPQR.Internals.ObjectManager.WoWLocalPlayer;

    if(TARGET.HealthPercent > 80)
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.DSMisery);

    if(!TARGET.HasAurabyId((int)Auras.Agony))
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.Agony);

    if(!TARGET.HasAurabyId((int)Auras.Corruption))
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.Corruption);

    if (!TARGET.HasAurabyId((int)Auras.UnstableAffliction))
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.UnstableAffliction);

    if(!TARGET.HasAurabyId((int)Auras.Haunt))
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.Haunt);

    if(TARGET.HealthPercent <= 20)
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.DrainSoul);

    if(TARGET.HealthPercent > 20)
    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.MaleficGrasp);

    }

    public override void OnLoad() //This is called when the Customclass is loaded in SPQR
    {

    }

    public override void OnClose() //This is called when the Customclass is unloaded in SPQR
    {

    }

    public override void OnStart() //This is called once, when you hit CTRL+X to start SPQR combat routine
    {

    }

    public override void OnStop() //This is called once, when you hit CTRL+X to stop SPQR combat routine
    {

    }
    }
    }

  8. #8
    Nonowmana's Avatar Contributor
    Reputation
    125
    Join Date
    Apr 2009
    Posts
    259
    Thanks G/R
    0/4
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Push it on the wiki
    SPQR - Passive Rotation Bot
    Anthraxbot & SPQR Creator / Administrator

  9. #9
    lockslash's Avatar Member
    Reputation
    3
    Join Date
    Sep 2012
    Posts
    42
    Thanks G/R
    3/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Last edited by lockslash; 04-23-2014 at 05:11 PM.

  10. #10
    lockslash's Avatar Member
    Reputation
    3
    Join Date
    Sep 2012
    Posts
    42
    Thanks G/R
    3/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Added somme functions

    Code:
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using SPQR;
    using MySPQR;
    
    namespace SPQR.Engine
    {
        class Warlock : Engine.FightModule
        {
            public override string DisplayName
            {
                get { return "Affliction Warlock Affliction"; }                      //This is the name displayed in SPQR's Class selection DropdownList
            }
    
            internal enum Spells : int                      //This is a convenient list of all spells used by our combat routine
            {                                               //you can have search on wowhead.com for spell name, and get the id in url
                CurseOfElements = 1490,
    			MaleficGrasp = 686,			//
                Haunt = 48181,
                DrainSoul = 1120,
                Corruption = 172,
                Agony = 980,
                UnstableAffliction = 30108,
                DSMisery = 77801,			//
                LifeTap = 1454,
                DrainLife = 689,
                UnendingResolve = 104773,
            }
            internal enum Auras : int                       //This is another convenient list of Auras used in our combat routine
            {												//you can have those in wowhead.com (again) and get the id in url
                Haunt = 48181,
                Corruption = 146739,		// aura
                Agony = 980,				
                UnstableAffliction = 30108,
    			FireBreath = 34889,			// CoE equiv
    			LightningBreath = 24844,	// CoE equiv
    			MasterPoisoner = 93068,		// CoE equiv
    			CurseOfElements = 1490,		// CoE
    			SoulShards = 117198,
            }
    
    		
            public override void CombatLogic()              //This is the DPS / healing coutine, called in loop by SPQR all code here is executed
            {
                var TARGET = MySPQR.Internals.ObjectManager.Target;
                var ME = MySPQR.Internals.ObjectManager.WoWLocalPlayer;
    
                // if(TARGET.HealthPercent > 80)
                //     MySPQR.Internals.ActionBar.CastSpellById((int)Spells.DSMisery);
    
                if(!TARGET.HasAurabyId((int)Auras.CurseOfElements) && !TARGET.HasAurabyId((int)Auras.FireBreath) && !TARGET.HasAurabyId((int)Auras.LightningBreath) && !TARGET.HasAurabyId((int)Auras.MasterPoisoner))
                    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.CurseOfElements);
    			
                if(!HasMyDebuff((int)Auras.Agony))
                    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.Agony);
    
                if(!HasMyDebuff((int)Auras.Corruption))
    				MySPQR.Internals.ActionBar.CastSpellById((int)Spells.Corruption);
    
                if (!HasMyDebuff((int)Auras.UnstableAffliction))
                    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.UnstableAffliction);
    				
                if(!HasMyDebuff((int)Auras.Haunt))
                    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.Haunt);
    
               if(ME.HealthPercent > 60 && ME.ManaPercent < 40)
                    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.LifeTap);
    				
                if(TARGET.HealthPercent <= 20)
                    MySPQR.Internals.ActionBar.CastSpellById((int)Spells.DrainSoul);
    				
    			if(TARGET.HealthPercent > 20)
    				MySPQR.Internals.ActionBar.CastSpellById((int)Spells.MaleficGrasp);
    
            }
    	
    		public static bool HasMyDebuff(int spellID)
    		{
    			var TARGET = MySPQR.Internals.ObjectManager.Target;
    			foreach (var aura in TARGET.AuraList)
                {
    				if( (aura.Id==spellID) &&  aura.IsMine)
    					return true;
                 }
    			 return false;
    		}
    		
            public override void OnLoad()   //This is called when the Customclass is loaded in SPQR
            {
       
            }
    
            public override void OnClose() //This is called when the Customclass is unloaded in SPQR
            {
                
            }
    
            public override void OnStart() //This is called once, when you hit CTRL+X to start SPQR combat routine
            {
    
            }
    
            public override void OnStop() //This is called once, when you hit CTRL+X to stop SPQR combat routine
            {
    		
            }
        }
    }

  11. #11
    exec85's Avatar Member
    Reputation
    3
    Join Date
    Mar 2009
    Posts
    43
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hi nice work! is this still the most current version to go with?

  12. #12
    lockslash's Avatar Member
    Reputation
    3
    Join Date
    Sep 2012
    Posts
    42
    Thanks G/R
    3/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I try to make better but I can not...

    Looking inside dll I see this:

    MySPQR.Patchables.Enums.WowPowerType.SoulShards

    but is not working for me... this control are primordial to Afli Warlock

    also I don't know why the profile is casting Haunt and UnstableAffliction 2 times (maybe the instants also but I dont see this)

  13. #13
    Nonowmana's Avatar Contributor
    Reputation
    125
    Join Date
    Apr 2009
    Posts
    259
    Thanks G/R
    0/4
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This profile is now ported for Anthrax built-in SPQR here : https://www.anthraxbot.com/forums/fo...-Customclasses
    Anthraxbot & SPQR Creator / Administrator

Similar Threads

  1. Probably/possibly warlock destro profile
    By averykey in forum WoW Bot Maps And Profiles
    Replies: 10
    Last Post: 03-09-2014, 01:52 AM
  2. LF warlock levelling profile
    By saintsrlfc in forum WoW Bot Maps And Profiles
    Replies: 3
    Last Post: 07-28-2013, 05:23 PM
  3. Warlock Leveling profile?
    By idiom444 in forum WoW Bot Maps And Profiles
    Replies: 4
    Last Post: 06-06-2013, 02:40 AM
  4. [PQR] There warlock pvp profile?
    By Stein6 in forum WoW Bot Maps And Profiles
    Replies: 4
    Last Post: 03-02-2013, 08:08 AM
  5. [REQ] Demo Warlock PVP Profile
    By Techz in forum WoW Bot Maps And Profiles
    Replies: 7
    Last Post: 12-10-2012, 12:38 AM
All times are GMT -5. The time now is 02:22 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search