ghettobird
LUA newbie
Hello otlanders, sorry for releasing so many scripts that maybe you have seen before but i'm just so excited that i can make scripts now...
so let's get started, go to creaturescripts/scripts make a file called death.lua and put this inside,
now you need to register it to login.lua
now go to creaturescripts.xml and put this
i hope you guys like it !
so let's get started, go to creaturescripts/scripts make a file called death.lua and put this inside,
Lua:
function onDeath(cid, corpse, deathList)
if(isPlayer(cid) == true) then
for _, pos in pairs(getArea(getCreaturePosition(cid), 1, 1)) do
doSendMagicEffect(pos, 65)
end
doCreatureSay(cid, getCreatureName(cid) .. " killed by " .. getCreatureName(deathList[1]) .. " [R.I.P]", TALKTYPE_ORANGE_1)
end
return true
end
now you need to register it to login.lua
Lua:
registerCreatureEvent(cid, "death")
now go to creaturescripts.xml and put this
Lua:
<event type="death" name="death" event="script" value="death.lua"/>
i hope you guys like it !