我最近才开始研究《魔兽世界》的LUA和附加组件。我想在聊天中显示魔术学校和伤害程度,但是我的代码不起作用。请查看我在做什么错。
local Congrats_EventFrame = CreateFrame("Frame")
CombatTextSetActiveUnit("player")
Congrats_EventFrame:RegisterEvent("COMBAT_TEXT_UPDATE")
Congrats_EventFrame:SetScript("OnEvent",
function(arg1, arg2, arg3)
print(arg1 .. ' - ' .. arg2 .. ' - ' .. arg3)
end)
请参见SPELL_DAMAGE
下https://wow.gamepedia.com/COMBAT_LOG_EVENT的“金额”参数>