Hi,
I can't manage to find an event or function to get the name of the player who took a healstone in the soulwell...
I need to know who does have a healstone and who doesn't, is that even possible ?
My idea was to create an array with all the party members's name and changing it everytime someone take a healstone from the soulwell, and then be able to print who doesn't take one.
So far i have this :
Lua Code:
-- SPELL ID
-- Puit des âmes
local soulwellID = 29893
local soulstoneID = 6201
local onSoulwellCasted = CreateFrame("Frame")
onSoulwellCasted:RegisterEvent("UNIT_SPELLCAST_SUCCEEDED")
onSoulwellCasted:SetScript("OnEvent",
function(self, event, ...)
local caster, spellName, spellRank, spellLineID, spellID = ...
if(spellID == soulwellID) then
SendChatMessage("Puits des âmes à mes pieds !" , "YELL", nil, -1);
end
end)
local onSoulstoneTaken = CreateFrame("Frame")
onSoulstoneTaken:RegisterEvent("CHAT_MSG_LOOT")
onSoulstoneTaken:SetScript("OnEvent",
function(self, event, ...)
local chatMsg, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, chatLineID = ...
if string.match(chatMsg, "Pierre de soins") then
--SendChatMessage("Someone took a healstone !" , "YELL", nil, -1);
message(chatLineID)
end
end)
Thanks in advance
EDIT : Ok i used /eventtrace and figured out the wiki lied to me
Thanks anyway
EDIT 2 : Now i struggle to get a list of all party members... any idea?