Jump to content

Matenia

Elite user
  • Posts

    2226
  • Joined

  • Last visited

Bug Report Comments posted by Matenia

  1. @Droidz did you change something recently? 
    wRobot pathing just changes randomly. Sometimes it takes a good, straight path and everything works out.
    Next week, it runs around, much longer pathin, maybe even goes through water, seems to ignore some blacklisted areas etc

    Maybe accidental bug when you fixed pathing server?

  2. I realized why this works perfectly for TBC, btw.
    Warmane (only TBC server atm) calculates spell distance from center to center (like on Blizzard realms). Vanilla private servers calculate distance end to end (hitbox to hitbox). This is a bug that wRobot has to work around, unfortunately.
    After re-considering this, it's good if you add 

    GetHitBoxtDistance

    but I don't think this needs to be fixed really.

  3. I want to prevent stuttering movement from my fightclass starting a cast when the bot is in range but for Frostbolt, but the fightclass thinks it's not in range, so it walks closer.
    How do you decide when to walk closer to the target? You take CustomClass.GetRange and do (pseudo code) - I think?:

    while (Me.GetDistance(ObjectManager.Target) > CustomClass.GetRange){
      MovementManager.MoveTo(ObjectManager.Target.Position);
    }
    MovementManager.StopMoveTo(false, 500);

    So if I make my code:
     

    public Spell Frostbolt = new Spell("Frosbolt");
    public float HitBox => ObjectManager.Target.CombatReach + Me.CombatReach;
    public float Range => .MaxRange + HitBox;
    
    public void Rotation()
    {
      if(Fight.InFight && GetGlobalCooldown() == 0 && ObjectManager.Target.GetDistance - HitBox <= Range)
      {
        Lua.LuaDoString($"CastSpellByName('{spell.Name}')");
      }
    }

    it should work and never cast before it's close enough, right?

  4. GetDistance is the method wRobot uses for CustomClass to get close to the enemy. Due to hitbox differences (combatreach) it sometimes doesn't get close enough, then just stands there and says "out of range, out of range!".

    There's 2 options:
    - Add a new method "GetCombatDistance" and use this in CustomClass, Spell.IsDistanceGood, etc (and users can use this in their own stuff too) 
    - for WoWUnit and WoWPlayer, fix GetDistance method and make it "PositionWithoutType.DistanceTo(ObjectManager.Me.PositionWithoutType) - this.CombatReach - ObjectManager.Me.CombatReach"

    (I didn't know currently it uses PositionWithoutType, I thought it was just Position).

    Currently this code returns real distance:

     

    var RealRange = ObjectManager.Target.GetDistance - ObjectManager.Target.CombatReach - ObjectManager.Me.CombatReach;

     

  5. Tested the update. It gets to 15% CPU (maybe more if I let it run longer).
    Is there maybe some bug in TBC version? I cannot really imagine vanilla and wotlk objectmanager working so differently from TBC.

  6. 1 hour ago, Droidz said:

    Hello, in tbc all items seems to be keep in memory (in the objectmanager), when you go to big city (with a lot of players and a lot of items (equipped)) or after few hours you can get bigger CPU usages.

    Is there any way I can trigger a clean on the WoW ObjectManager? A /run ReloadUI() ingame does not work, unfortunately.

  7. On 6/9/2018 at 12:12 PM, eniac86 said:

    hello, fix your fucking navigation mesh. you got my money you asshole!

    Bon fires are spawned game objects, they're not part of the map. You can't fix meshes for them because you can't generate meshes. They don't exist. So you need to add blacklisted zone to tell the pathfinder to avoid it.

  8. @Ordush 

    @Droidz

    public static float GetGlobalCooldown()
        {
            string luaString = @"
            local i = 1
            while true do
                local spellName, spellRank = GetSpellName(i, BOOKTYPE_SPELL);
                if not spellName or i >= 10 then
                    break;
                end
       
                local start, duration, enabled = GetSpellCooldown(i, BOOKTYPE_SPELL);
                if enabled == 1 and start > 0 and duration > 0 then
                    local cooldownLeft = duration - (GetTime() - start)
                    --DEFAULT_CHAT_FRAME:AddMessage('GCD check for ' .. spellName .. ' ' .. cooldownLeft);
                    if (cooldownLeft < 1500 and cooldownLeft ~= 0) then
                        return cooldownLeft / 1000;
                    end
                end
    
                i = i + 1;
            end
    
            return 0;
            ";
    
            return Lua.LuaDoString<float>(luaString);
        }

    Correct me if I'm wrong, but this should work (pure Lua, vanilla). Checks 10 first spells in spellbook for their cd. Rogues have 1 second GCD tho, so idk

  9. How can I know which coordinate the path ends by? The problem with the barrens elevator is that wRobot can make a path. But the path goes through a bunch of highlevel elite. So from what I understand, it will never even load OffMeshConnection.
    Same problem for Darnassus portal and ships, the bot will just try to swim or walk up a wall. Doesn't realize there is no path available. 

  10. This is a feature of my plugin, that must've broken in one of the recent updates.
    wRobot can not take elevators or anything by default.

    From what I can tell, it's a bug/problem with wRobot not resetting movement correctly. Once I've taken the elevator, I want wRobot to calculate a new path from scratch whereever it needs to go. So I pause the bot and unpause it. Then it tries to go back to the last spot it was at/wanted to go to before and probably takes the elevator back down. This used to work just fine, but seems to not work well anymore. Maybe Droidz can shed some light on how to reset movement entirely.

    That being said, without the plugin you'd run into the elites 100% of the time.

  11. Hmmm, it seems to work fine, but for some of my users, it bugs out. At first I thought it was this, then I thought it was maybe SpellManager.CastSpellByNameOn, but I tried it all and it all works.

×
×
  • Create New...