Page 1 of 2 1 2 LastLast
Results 1 to 10 of 11

Thread: GetHeroLastSeenInfo

  1. #1
    Basic Member
    Join Date
    Dec 2016
    Posts
    638

    Question GetHeroLastSeenInfo

    @ChrisC (or anyone that has time to test),

    What information is returned by GetHeroLastSeenInfo() in the case of a hero with illusions present?

    What I really mean is the following scenario:
    1) A hero has 2 illusions (say they picked up illusion rune)
    2) The hero appears top, mid and bot lane at the same time (we don't know which is illusions, which is real)

    a) What happens when I call GetHeroLastSeenInfo().location? Do I get 3 locations? Do I get only the "real hero" location?
    b) All 3 of them disappear from sight and I call GetHeroLastSeenInfo().location, can it be used to determine "real" hero?

  2. #2
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,693
    Hm, looking at that code, it's basically going to give you a random location for one of "heroes" you can see for that player, which I can't imagine is useful. I'll change it to return a table of all of the locations and time-since-seen for heroes, illusion or not, that you can current or previously have seen.

  3. #3
    Basic Member
    Join Date
    Dec 2016
    Posts
    638
    Quote Originally Posted by ChrisC View Post
    I'll change it to return a table of all of the locations and time-since-seen for heroes, illusion or not, that you can current or previously have seen.
    How long will this return information for illusions that expired? Is that instant (as in we won't get more than one entry in table once it is gone)?

  4. #4
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,693
    Quote Originally Posted by nostrademous View Post
    How long will this return information for illusions that expired? Is that instant (as in we won't get more than one entry in table once it is gone)?
    It'll return until the illusion is destroyed. Which is admittedly a little cheat-y -- once one of the "last seen" elements disappears, you'll know that a) that illusion expired and b) that the hero that you last saw at that location was actually an illusion. There's not a great way to fix that that I can see, though.

  5. #5
    Basic Member
    Join Date
    Dec 2016
    Posts
    638
    Quote Originally Posted by ChrisC View Post
    It'll return until the illusion is destroyed. Which is admittedly a little cheat-y -- once one of the "last seen" elements disappears, you'll know that a) that illusion expired and b) that the hero that you last saw at that location was actually an illusion. There's not a great way to fix that that I can see, though.
    Yeah, I don't know of a good way to fix it. I was thinking perhaps continue reporting on expired illusions until the next time the hero is seen and then stop. That way at least there is continued ambiguity until vision is re-established.

  6. #6
    Basic Member
    Join Date
    Mar 2012
    Posts
    1,758
    Slightly off-topic, yet similar in some regards (sorry for hijacking the thread ), but I was also curious about this:
    Code:
    int GetUnitPotentialValue( hUnit, vLocation, fRadius )
    Does it still use hUnit like in the wiki or does it use playerID now ?
    Explanations on the normal, high and very high brackets in replays: here, here & here
    Why maphacks won't work in D2: here

  7. #7
    Basic Member
    Join Date
    Dec 2016
    Posts
    638
    Quote Originally Posted by The Nomad View Post
    Slightly off-topic, yet similar in some regards (sorry for hijacking the thread ), but I was also curious about this:
    Code:
    int GetUnitPotentialValue( hUnit, vLocation, fRadius )
    Does it still use hUnit like in the wiki or does it use playerID now ?
    My understanding is that it was never fixed.... so currently not usable/working.

  8. #8
    Basic Member
    Join Date
    Mar 2012
    Posts
    1,758
    Thought so
    Explanations on the normal, high and very high brackets in replays: here, here & here
    Why maphacks won't work in D2: here

  9. #9
    Valve Developer
    Join Date
    Sep 2011
    Posts
    1,693
    Oh, that's dumb. I'll fix that too (though maybe not for next update).

  10. #10
    Basic Member
    Join Date
    Mar 2012
    Posts
    1,758
    No hurries. It's not like I wanna use it atm, but it's just so we don't forget
    Chris, if you have time, please check if there are any other functions that need "visible" units (such as this one) that might need to be ported to playerid. I don't think there are, but a second look never hurts. If you have time, of course. (not now, but I mean, as a TODO)



    Still, let's be honest, nothing is more important than the bot API



    P.S. off-topic: the shark attack from the treasure preview of today's patch scared me (in a good way); it was a cool effect
    Last edited by The Nomad; 06-02-2017 at 03:56 PM.
    Explanations on the normal, high and very high brackets in replays: here, here & here
    Why maphacks won't work in D2: here

Posting Permissions

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