president vankk
Web Developer & AuraOT Owner
- Joined
- Jul 10, 2009
- Messages
- 5,719
- Solutions
- 9
- Reaction score
- 339
Hi folks! Actually I'm having some problems with the script below, it just does not works, the main idea of this script is if you kill a Morgaroth or Ghazbaran then you'll get a achievement.
It is already registred in login.lua/monsters files/creaturescripts.xml. What is the problem in here?
Already tried to print everything but just does not works.
Thanks.
Code:
function onKill(creature, target)
local targetMonster = target:getMonster()
if not targetMonster then
return true
end
if targetMonster:getName():lower() ~= "morgaroth" or targetMonster:getName():lower() ~= "ghazbaran" then
return true
end
local player = creature:getPlayer()
player:addAchievement('Slayer')
return true
end
It is already registred in login.lua/monsters files/creaturescripts.xml. What is the problem in here?
Already tried to print everything but just does not works.
Thanks.