ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   Lua/XML Help (https://www.esoui.com/forums/forumdisplay.php?f=175)
-   -   What exactly triggers EVENT_POI_UPDATED? (https://www.esoui.com/forums/showthread.php?t=6030)

SnowmanDK 01/24/16 07:04 AM

What exactly triggers EVENT_POI_UPDATED?
 
From what I can see, it triggers at odd times, which makes addons utilize extra cpu time for no reason.

A good example I have been made aware off, is if you run between the wayshrine and the guild traders in Belkarth.
It triggers around the bridge every time, but there is NO changes in the values it returns, and I already know all POI's in that zone. It doesn't even change between zone/submap.
Does it have to do with distance to POI's?

haggen 01/24/16 07:09 AM

I have no idea what's POI but the game use it to detect changes in the difficulty:
http://esodata.uesp.net/100010/src/i...ll.lua.html#35

SnowmanDK 01/24/16 07:18 AM

Quote:

Originally Posted by haggen (Post 25604)
I have no idea what's POI but the game use it to detect changes in the difficulty:
http://esodata.uesp.net/100010/src/i...ll.lua.html#35

That doesn't make sense to me :confused:
Then the difficulty changes in town when crossing a bridge in Belkarth? ;)

Shinni 01/24/16 07:37 AM

Whenever that event is fired, the worldmap removes and re adds all the poi pins. As undisovered POI are only visible when being nearby, I guess it's really just a distance indicator. It probably fires every time the player crosses the visiblity radius for a POI.

ZOS_ChipHilseberg 01/25/16 09:07 AM

It's sent when a POI changes state. When you enter or exit visibility range, discover it permanently, or complete it.

haggen 01/25/16 12:43 PM

Earlier when I read the post I thought to myself "how cool would be if Chip himself commented here" and now my dream has come true. Thank you Chip, you're the best.

SnowmanDK 01/25/16 01:34 PM

Quote:

Originally Posted by haggen (Post 25627)
Earlier when I read the post I thought to myself "how cool would be if Chip himself commented here" and now my dream has come true. Thank you Chip, you're the best.

:p
Quote:

Originally Posted by ZOS_ChipHilseberg (Post 25624)
It's sent when a POI changes state. When you enter or exit visibility range, discover it permanently, or complete it.

Thanks for the reply Chip :)
I can see someone updated the wiki with that information today ;)
I guess the returned eventCode changes depending on how it was triggered then, or?

I ask as I need to be able to detect when it's permanently discovered and when it's completed, so I'd like to be able to "ignore" other state changes.

And can I assume that EVENT_POI_DISCOVERED fires when a POI is discovered, both temporary and permanently then (and that the returned eventCode also changes here depending on how its triggered)?

ZOS_ChipHilseberg 01/25/16 02:06 PM

Discovered is sent when you first accept a quest associated with that POI. Event code is just the numeric equivalent of the event id, it's sent with every event. You'll want to take the zoneIndex and poiIndex and use it with the POI functions like GetPOIMapInfo to learn more.

SnowmanDK 01/26/16 03:01 PM

To finish this off, and to make sure I don't misunderstand something...
EVENT_POI_UPDATED is fired everytime there is a change in regards to a POI, while
EVENT_POI_DISCOVERED fires when it's discovered (which means BOTH fires when a POI is discovered)?


All times are GMT -6. The time now is 11:30 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI