EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Quests::LUA (https://www.eqemulator.org/forums/forumdisplay.php?f=680)
-   -   event_hp seems to do nothing (https://www.eqemulator.org/forums/showthread.php?t=44215)

t0neg0d 11-17-2024 12:09 PM

event_hp seems to do nothing
 
Like the title says, this example does nothing.

Code:

function event_hp(e)
        -- NPC-event_hp
        -- Exported event variables
        eq.debug("hp_event " .. e.hp_event);
        eq.debug("inc_hp_event " .. e.inc_hp_event);
end


fryguy 11-17-2024 01:36 PM

Quote:

Originally Posted by t0neg0d (Post 270184)
Like the title says, this example does nothing.

Code:

function event_hp(e)
        -- NPC-event_hp
        -- Exported event variables
        eq.debug("hp_event " .. e.hp_event);
        eq.debug("inc_hp_event " .. e.inc_hp_event);
end


Works as expected however you need to set a value threshold for a trigger:

Code:

eq.set_next_hp_event(int hp);
eq.set_next_inc_hp_event(int hp);


t0neg0d 11-18-2024 02:40 AM

Quote:

Originally Posted by fryguy (Post 270185)
Works as expected however you need to set a value threshold for a trigger:

Code:

eq.set_next_hp_event(int hp);
eq.set_next_inc_hp_event(int hp);


Thanks so much. Where did you find this info? (so I can avoid posting if there is already an answer)

fryguy 11-18-2024 08:39 AM

Looking at use cases of it in the PEQ quest repository, not sure its documented anywhere.

t0neg0d 11-18-2024 02:00 PM

Quote:

Originally Posted by fryguy (Post 270188)
Looking at use cases of it in the PEQ quest repository, not sure its documented anywhere.

ty! most appreciated.


All times are GMT -4. The time now is 12:30 PM.

Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.