Page 2 of 3 FirstFirst 1 2 3 LastLast
Results 11 to 20 of 28

Thread: February 23 Bot Update

  1. #11
    Basic Member
    Join Date
    Jan 2017
    Posts
    25
    Quote Originally Posted by fandogh View Post
    Hello! Me Again

    ChrisC, Can you please search for "item_recipe_satanic" on npc_heroes and delete/replace them with "item_mithril_hammer" ? (Total 4 Heroes --> Phantom Assassin, Razor (Just Delete the Recipe), Juggernaut, Drow Ranger (Better totally delete satanic because she has Mask of Madness))

    And also if you have time, please correct the Aegis bug (Most AI Bots cant pickup aegis, so they stay and look at Aegis whole game)
    I think the aegis bug is related to item slot swap code. If the bot has all 6 slots filled, it will try to swap some item to backpack to make space for aegis. However, as soon as the item is moved to backpack, before picking up aegis, some other code will cut in and swap the item back to item slot, thus an infinite loop.

  2. #12
    Quote Originally Posted by insraq View Post
    I think the aegis bug is related to item slot swap code. If the bot has all 6 slots filled, it will try to swap some item to backpack to make space for aegis. However, as soon as the item is moved to backpack, before picking up aegis, some other code will cut in and swap the item back to item slot, thus an infinite loop.
    Does that make the unfair bots better with their backpack, or is it still bugged?

  3. #13
    EDIT: ignore the below

    was a bug in my lua

    Code:
    GetHeroLastSeenInfo(target:GetPlayerID()).location
    is correct.
    so is
    Code:
    next(GetHeroLastSeenInfo(target:GetPlayerID()))

    I was using

    Code:
    next(GetHeroLastSeenInfo(target:GetPlayerID())).location
    next is returning the first table entry (the location. so I was doing location.location)



    Fixed GetHeroLastSeenInfo() to never return nil


    this still returns nil for me?
    Last edited by TheP1anoDentist; 02-25-2017 at 09:53 PM.
    https://github.com/ThePianoDentist/t...dentistdotabot Lina bot which pulls small camp when 'laning' (Aim to work on pulling and stacking bots initially)
    https://github.com/ThePianoDentist/dotabots-ml-tools Parsing data from bot games

  4. #14
    Basic Member
    Join Date
    Dec 2016
    Posts
    123
    Is that possible you lose the handle of 'target' so you can't get the right ID? I use GetTeamPlayers(GetOpposingTeam( )) to get enemy ID and store them in a table, it's more stable than get ID every time.

  5. #15
    Basic Member
    Join Date
    Dec 2016
    Posts
    123
    It would be helpful if we could get turn speed of bot so when bot try to dodge projectiles, he will know how much time he have to spend on turn around. Now I just assume bot need no time to turn around when dodge/ lasthit, which is not true.

  6. #16
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,704
    Quote Originally Posted by lunarbreez View Post
    I'm having the same problem with MinionThink( hMinionUnit ), trying to use alchemist illusion to farm but can't execute the action "hMinionUnit:Action_AttackMove(target_loc)". Can print out 'illusion farm lane' one step before the action. but can't execute the AttackMove action. ActionQuene is the same.
    This very simple script works for me, is it possible that you're thrashing between two different actions, leaving the bot stuck?

    Code:
    function MinionThink( hMinionUnit )
    	if ( hMinionUnit:IsIllusion() ) then
    		hMinionUnit:Action_AttackMove(Vector(0,0,0))
    	end
    end

  7. #17
    Basic Member
    Join Date
    Dec 2016
    Posts
    123
    Quote Originally Posted by ChrisC View Post
    This very simple script works for me, is it possible that you're thrashing between two different actions, leaving the bot stuck?

    Code:
    function MinionThink( hMinionUnit )
    	if ( hMinionUnit:IsIllusion() ) then
    		hMinionUnit:Action_AttackMove(Vector(0,0,0))
    	end
    end
    No, the same simple one don't work for me. Console shows that my illusion is thinking about 'use manta to farm', which should only be thought by main hero, and I didn't implement any code for manta use in MinionThink() but the illusion keep trying to use ability manta, and it certainly can't so it get stuck. I add (not npcBot:IsIllusion( )) to my manta usage code and it stop spamming ' use manta to farm ' in console, but it's still stuck because I'm sure it is thinking about other behavior which I only put in Think() function.

    Below is my MinionThink code that is as simple as it is.

    Code:
    function  MinionThink(  hMinionUnit ) 
    	if (hMinionUnit:IsIllusion( ) ) then ---if it is alchemist illusion
    		local toplane_loc = GetLaneFrontLocation(GetOpposingTeam( ) , LANE_TOP, 0);
    		hMinionUnit:Action_AttackMove(Vector(0,0,0)); end; end;
    Last edited by lunarbreez; 02-27-2017 at 11:46 PM.

  8. #18
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,704
    Quote Originally Posted by lunarbreez View Post
    No, the same simple one don't work for me. Console shows that my illusion is thinking about 'use manta to farm', which should only be thought by main hero, and I didn't implement any code for manta use in MinionThink() but the illusion keep trying to use ability manta, and it certainly can't so it get stuck. I add (not npcBot:IsIllusion( )) to my manta usage code and it stop spamming ' use manta to farm ' in console, but it's still stuck because I'm sure it is thinking about other behavior which I only put in Think() function.

    Below is my MinionThink code that is as simple as it is.

    Code:
    function  MinionThink(  hMinionUnit ) 
    	if (hMinionUnit:IsIllusion( ) ) then ---if it is alchemist illusion
    		local toplane_loc = GetLaneFrontLocation(GetOpposingTeam( ) , LANE_TOP, 0);
    		hMinionUnit:Action_AttackMove(Vector(0,0,0)); end; end;
    Ah, I see, yeah I don't think we shouldn't be calling the main Think() function for illusions at all. They get MinionThink() instead.

  9. #19
    Basic Member
    Join Date
    Dec 2016
    Posts
    733
    Quote Originally Posted by ChrisC View Post
    Ah, I see, yeah I don't think we shouldn't be calling the main Think() function for illusions at all. They get MinionThink() instead.
    This is going to be rather confusing I feel since there are many "types" of illusions/minions.

    For example:
    * Minions - to me are neutral mobs under control of the hero that have independently castable abilities different from the hero and might or might not be able to move. We control the movement and ability use of these units - this includes Necronomicon heroes, Beastmaster bird/boar, HotD mobs, Techies mines/trap, TA's trap, Brewmaster's Ult spirits, etc.

    * Illusions - to me are hero copies that are unable to use any abilities or items but have all the hero stats and items (just can't use them). All we have to do for these is control the movement and right click damage of these units - this includes Manta illusions, Morphling's Replicate, Dark Seers Ultimate enemy hero illusions, Shadow Demon's Soul Catcher illusions, Terrorblade's illusions, Illusion Rune illusions, Naga Siren, Phantom Lancer, etc.

    UNSURE - I am unsure how to classify:
    ** Lifestealer's Infested mob - it is a Minion in many respects, but with a "new" ability
    ** Vengeful Spirit's Agh Scepter Unit - it is a Minion but it's the "same" as the hero (when it was alive)
    ** Wraith Kings' Agh Scepter Units
    ** Arc Warden's Tempest Double - it's a Minion with "same" abilities but also with "limited" item-use allowance - for all purposes this actually might be best considered as a "6th" hero on a team

    Perhaps it would be best to separate the types with specific definition of what is what and then have a:
    * MinionThink()
    * IllusionThink()
    * CloneThink() <-- made this up to tackle Arc Warden and perhaps Meepo clones

  10. #20
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,704
    Hm, yeah. I'll ship the initial change (a given unit gets either a MinionThink or a Think but not both), but will need to think about if we need to further divide it up at the API level.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •