Skip to content
View in the app

A better way to browse. Learn more.

WRobot

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Checking if Spell is Launched

Featured Replies

 

if (Corruption.IsSpellUsable && Corruption.IsDistanceGood && Corruption.KnownSpell)
         {

             if (CorrAura.SpellId == )
             {
                Logging.Write("herea");
                Corruption.Launch();
                 return;
             }else if(corr20 == false && corr60 == false && ObjectManager.Me.HaveBuff("Eradication") && !ObjectManager.Me.HaveBuff("Bloodlust") && !ObjectManager.Me.HaveBuff("Heroism"))
            {
                Logging.Write("hereb");
                Corruption.Launch();
                corr0 = false;
                corr20 = true;
                corr60 = false;
                return;
            }else if(corr60 == false && ObjectManager.Me.HaveBuff("Eradication"))
            {
                if(ObjectManager.Me.HaveBuff("Bloodlust") || ObjectManager.Me.HaveBuff("Heroism"))
                {
                    Logging.Write("herec");
                    Corruption.Launch();
                    corr0 = false;
                    corr20 = false;
                    corr60 = true;
                    return;
                }
            }

         }

So, my issue is that it changes the variables (corr0/corr20/corr60) without actually Launching the spell. Because it loops through this while casting previous spell / on GCD.  Is it possible to do something like

Corruption.Launch();
//pseudo code
if(launch is successful){
	corr0 = false;
	corr20 = false;
	corr60 = true;
}

How would I check if the launch is successful? Its an instant spell, so I cant check current spell casting.  Also, I don't want to do something like 

 

if(Not ON GCD || Not Casting) {

}

I do not want to do this because I will slow down the routine script way to much.  How else to fix issue?

Hello, this code is not 100% reliable but you can try:

        Spell Corruption = new Spell("Corruption");
        //...
        var errorCount = wManager.Wow.Helpers.EventsLua.UsedCountByLuaEventsId(wManager.Wow.Enums.LuaEventsId.UI_ERROR_MESSAGE);
        Corruption.Launch();
        bool failled = wManager.Wow.Helpers.EventsLua.UsedCountByLuaEventsId(wManager.Wow.Enums.LuaEventsId.UI_ERROR_MESSAGE) > errorCount;

 

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.