• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Amulet of loss

Erexo

Kage
Premium User
Joined
Mar 27, 2010
Messages
743
Solutions
5
Reaction score
200
Location
Pr0land
GitHub
Erexo
Hello,
i looking for a script for a AOL, but when you die, they transform to item ID 3303.

Someone can do this script?


Thanks,
Erexo :)
 
LUA:
function onDeath(cid, corpse, deathList)
	if getPlayerSlotItem(cid, CONST_SLOT_NECKLACE).itemid == 2173 then
		doCreatureSetStorage(cid, 1, 1)
	end
	return true
end

function onLogin(cid)
	registerCreatureEvent('death')
	if getCreatureStorage(cid, 1) == 1 then
		doCreatureSetStorage(cid, 1)
		doPlayerAddItem(cid, 3303, 1)
	end
	return true
end
 
XML:
-
	<event type="login" name="login" event="script" value="script.lua"/>
	<event type="death" name="death" event="script" value="script.lua"/>
 
Its a bug,
first time when you die, they add you a 3301,
but second time, amulet gone.

@Edit
all works fine :)
I have 0.3.6 TFS, so i must change some functions.
 
Last edited:
Back
Top