Hello,
I'm new here to EQemulator and are in the process of building a unique server called The Hungry Vulture. The problem that I am having is getting an NPC to play the custom voice mp3 that I created for it. I appreciate any help somebody could offer.
Edited & Solved: After a little troubleshooting and experimenting, I figured out you need to do it with a quick Set_Timer while also finding the client with the npc. I'll leave this working example here.
Code:
function event_say(e)
if(e.message:findi("hail")) then
client_to_check=eq.get_entity_list():GetClientByID(e.other:GetID());
eq.set_timer("greeting", 100); -- 0.1 seconds
e.self:Say("Test");
end
end
function event_timer(e)
if (e.timer == ("greeting")) then
e.self:Say("Timer Works");
client_to_check:PlayMP3("Corpsepicker_Greeting.mp3");
eq.stop_timer("greeting");
end
end