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.

Fight.StartFight deadlock?

  • Version: All
  • Product: WRobot General
  • Type: Bug
  • Status: Confirmed

Hello @Droidz,

I have the following problem. The bot doesn't recognize I am in fight (vanilla) after casting polymorph on another mob.
Now I use this snippet of code to force it to attack polied targets. However it completely locks at Fight.StartFight UNTIL the mob is dead (from external sources) or I die.
Check out the log below.

What can cause this?

if(!Fight.InFight || !Me.InCombat)
{
  WoWUnit polyTarget = ObjectManager.GetObjectWoWUnit().FirstOrDefault(u => u.HaveDebuff("Polymorph") && u.GetDistance <= 20);
  if (polyTarget != null)
  {
    Logging.WriteFight("Found polied target " + polyTarget.Name);
    Logging.WriteFight("Polytarget Valid: " + polyTarget.IsValid);

    //Fight.StopFight();
    Conditions.ForceIgnoreIsAttacked = false;
    CombatUtil.TargetUnit(polyTarget);
    Logging.WriteFight("Targeting poly");

    Fight.StopFight();
    Fight.StartFight(polyTarget.Guid, false);
    Logging.WriteFight("Starting fight again");
    SpellManager.CastSpellByNameLUA(Frostbolt.Spell.Name);
    Logging.WriteFight("Casting Frostbolt on polied target! Already InFight: " + Fight.InFight);
  }
}
[F] 13:32:06 - Fightclass successfully casted: Frostbolt
[F] 13:32:06 - Found polied target Highland Strider
[F] 13:32:06 - Polytarget Valid: True
[F] 13:32:06 - Targeting poly
13:32:07 - [HumanMasterPlugin] cancelling regen while in combat
13:32:07 - [Fight] Player Attack Highland Strider (lvl 31)
[F] 13:32:36 - Starting fight again
[F] 13:32:36 - Casting Frostbolt on polied target! Already InFight: False
13:32:37 - [HumanMasterPlugin] Looting Highland Strider
13:32:38 - [Fight] Player Attack Highland Strider (lvl 30)

 

User Feedback

Recommended Comments

Hello, can you share info of target with a Polymorph buff (in dev tools with button "memory info", share only target info, check if you haven't info about your character before to post info).

Matenia

Elite user

For now, I solved this by manually setting Fight.InFight = true and it will just continue working normally.
But I have noticed that whenever you crowd control a mob in vanilla (fear, polymorph, repentance) it will un-target you adn the bot will stop fighting it and completely ignore it.

I'll get back to you with memory info if I find the time.

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.