• 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!

An usable item which makes you lose all your frags

Lava Titan

Developer
Joined
Jul 25, 2009
Messages
1,529
Solutions
1
Reaction score
85
Location
Portugal
Yo otland ppl.
I wanted to request help in a script:

I wanted a item that when players click "Use" it would remove all the frags that they had.
It also would remove the redskull.

Item ID: 9003
Script Type: Action maybe?
Using Crying Damson 0.3.5 pl1

After the players click "use" on it, the item would desapear.

Regards Lava Titan!
 
try:
Lua:
<action itemid="9003" event="script" value="removeskull.lua"/>

removeskull.lua :
Lua:
function onUse(cid, item, frompos, item2, topos)
doCreatureSay(cid,"Frags Remove :)",TALKTYPE_ORANGE_1)
db.executeQuery("UPDATE `killers` SET `unjustified` = 0 WHERE `id` IN (SELECT `kill_id` FROM `player_killers` WHERE `player_id` = " .. getPlayerGUID(cid) .. ")")
doPlayerSetSkullEnd(cid, 0, SKULL_RED)            
doCreatureSetSkullType(cid, SKULL_NONE)
doRemoveItem(item.uid, 1)
return true
end
 
Back
Top