XenoBot Forums - Powered by vBulletin

User Tag List

Page 2 of 2 FirstFirst 12
Results 11 to 17 of 17

Thread: Attack only my creatures!

  1. #11
    l4z's Avatar
    Join Date
    Oct 2015
    Posts
    133
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    kk gona test it.
    Last edited by l4z; 12-02-2015 at 07:06 PM.

  2. #12

    Join Date
    Jun 2015
    Posts
    72
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by shadowart View Post
    This will turn off targeting when there's another player on the screen:

    lua code:

    local function playersOnScreen()
    local count = 0
    for name, _ in Creature.iPlayers(7) do
    if name ~= Self.Name() then
    count = count + 1
    end
    end
    return count
    end

    Module("Anti-kill steal", function(self)
    local playerCount = playersOnScreen()
    if Targeting.IsIgnoring() and playerCount == 0 then
    Targeting.StopIgnoring()
    elseif not Targeting.IsIgnoring() and playerCount > 0 then
    Targeting.StartIgnoring()
    end
    self:Delay(1000)
    end)


    However, it might not play nicely with more advanced scripts that use the ignore function for other stuff. It might also not work on some OTs.
    I believe there is a more effective solution to iso. Using a possible packet of agro monster.

  3. #13

    Join Date
    Nov 2015
    Posts
    61
    Mentioned
    5 Post(s)
    Tagged
    0 Thread(s)
    +1

    Good idea!

  4. #14
    Moderator shadowart's Avatar
    Join Date
    Dec 2014
    Location
    Sweden
    Posts
    1,985
    Mentioned
    225 Post(s)
    Tagged
    3 Thread(s)
    Quote Originally Posted by brindeds View Post
    I believe there is a more effective solution to iso. Using a possible packet of agro monster.
    That information is not revealed in the lua API. Darkstar would have to add it to the bot core.

  5. #15

    Join Date
    Jul 2015
    Posts
    18
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Thnx a lot @shadowart

  6. #16

    Join Date
    Jun 2015
    Posts
    72
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    It seems like @DarkstaR will implement cooming soon this

  7. #17

    Join Date
    Jul 2014
    Posts
    6
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Not my script, credit to whoever made it. (lukefisher?)
    Attached Files Attached Files

Posting Permissions

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