ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   General Authoring Discussion (https://www.esoui.com/forums/forumdisplay.php?f=174)
-   -   Reviving (https://www.esoui.com/forums/showthread.php?t=9804)

g0dpain 06/21/21 01:29 AM

Reviving
 
Hello all,

I'm keeping it short:
Is there an event or similiar to grab information of reviving someone else?

I am new to addon creation, so please have mercy :)

Thanks in advance!

Baertram 06/21/21 01:51 AM

https://wiki.esoui.com/Main_Page
-> Right top side -> Getting Started
You should read a bit about lua and ESO lua there to make yourself comfortable with it ;)
Here is a forum thread for new devs as well:
https://www.esoui.com/forums/showthread.php?t=8413

Events are listed here:
https://wiki.esoui.com/Events
But the most up2date list of API functions, events etc. will be found here:
https://wiki.esoui.com/APIVersion -> Scroll to the current API version on live/pts (depending on which server you code and test) and check the txt file link at "API TXT Documentation"

Your event would be something around "Life and Death", maybe
EVENT_UNIT_DEATH_STATE_CHANGED (number eventCode, string unitTag, boolean isDead)
You should filter the event so that it does not fire for EVERY unit as a unit is even any enemy:
https://wiki.esoui.com/AddFilterForEvent
Filters are applied before lua code and are speeding everything up, so that the event callbacks in your lua code do not fire for nothing.
e.g. REGISTER_FILTER_UNIT_TAG_PREFIX with the unitTag prefix = "group" for group members

Reviving events:
EVENT_RESURRECT_REQUEST (number eventCode, string requesterCharacterName, number timeLeftToAccept, string requesterDisplayName)
EVENT_RESURRECT_REQUEST_REMOVED (number eventCode)
EVENT_START_SOUL_GEM_RESURRECTION (number eventCode, number durationMs)
EVENT_RESURRECT_RESULT (number eventCode, string targetCharacterName, ResurrectResult result, string targetDisplayName)

The possible ResurrectResult constants can be found withint the API documentation txt file.

g0dpain 06/21/21 02:13 AM

Quote:

Originally Posted by Baertram (Post 44236)
https://wiki.esoui.com/Main_Page
-> Right top side -> Getting Started
You should read a bit about lua and ESO lua there to make yourself comfortable with it ;)
Here is a forum thread for new devs as well:
https://www.esoui.com/forums/showthread.php?t=8413

Events are listed here:
https://wiki.esoui.com/Events
But the most up2date list of API functions, events etc. will be found here:
https://wiki.esoui.com/APIVersion -> Scroll to the current API version on live/pts (depending on which server you code and test) and check the txt file link at "API TXT Documentation"

Your event would be something around "Life and Death", maybe
EVENT_UNIT_DEATH_STATE_CHANGED (number eventCode, string unitTag, boolean isDead)
You should filter the event so that it does not fire for EVERY unit as a unit is even any enemy:
https://wiki.esoui.com/AddFilterForEvent
Filters are applied before lua code and are speeding everything up, so that the event callbacks in your lua code do not fire for nothing.
e.g. REGISTER_FILTER_UNIT_TAG_PREFIX with the unitTag prefix = "group" for group members

Reviving events:
EVENT_RESURRECT_REQUEST (number eventCode, string requesterCharacterName, number timeLeftToAccept, string requesterDisplayName)
EVENT_RESURRECT_REQUEST_REMOVED (number eventCode)
EVENT_START_SOUL_GEM_RESURRECTION (number eventCode, number durationMs)
EVENT_RESURRECT_RESULT (number eventCode, string targetCharacterName, ResurrectResult result, string targetDisplayName)

Thank you very much for this detailed response!
After work I will look into it :)


All times are GMT -6. The time now is 03:08 AM.

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