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

Remove Red Skull And Black Skull in 0.3.5 [SOLVED BY RICHUX]

bolero

MikeHere
Joined
Apr 13, 2009
Messages
1,146
Reaction score
12
Location
Venezuela
I need that on having said the command !removefrags remove the red skull or the black skull having the item: 8983
URGENT PLEASE!
 
Last edited:
I have this script and work for only red skull in TFS 0.3.4

Fix please T.T

local config =
{
item = 8983,
count = 1
}

function onSay(cid, words, param)
if getPlayerItemCount(cid, config.item) >= config.count then
doPlayerRemoveItem(cid, config.item, config.count)
doPlayerSetRedSkullTicks(cid, 0)
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Tus frag ya fueron liberadas.")
else
doPlayerSendCancel(cid, "You dont have this item.")
end
return TRUE
end
 
that's not even in the script

Yes, it is.

OP, do you have an item with the id of 8983?

Because your script is perfect. You get that message because "(getPlayerItemCount(cid, config.item) >= config.count)" is returning false. Wish means you don't have the required item.
 
Last edited:
Yes, it is.
Boxxy_srsly.png
 
here ya go:

actions.xml(XXX-ur item id)

Code:
	<action itemid="XXXX" event="script" value="red_skull.lua"/>

actions/scripts/red_skull.lua

LUA:
  function onUse(cid, item, frompos, item2, topos)
       
        local nonremskulls =  -- These are the skulls it cant remove. If player has any of these, the rune wont work.
{
        white = SKULL_WHITE
}

        if isInArray(nonremskulls, getPlayerSkullType(cid)) then
                doPlayerSendCancel(cid,"You can't remove this type of skull.")
                doSendMagicEffect(getPlayerPosition(cid),2)
        else
                db.executeQuery("UPDATE `killers` SET `unjustified` = 0 WHERE `id` IN (SELECT `kill_id` FROM `player_killers` WHERE `player_id` = " .. getPlayerGUID(cid) .. ")")
                doCreatureSetSkullType(cid,0)
                doPlayerSendTextMessage(cid,27,"Your frags & your skull have been removed, thank you for donating!")
                doSendMagicEffect(getPlayerPosition(cid),CONST_ME_MAGIC_RED)
                                doSendAnimatedText(getPlayerPosition(cid), "Skull removed!", 180)
                doRemoveItem(item.uid, 1)
                                doPlayerSetSkullEnd(cid, 0, getPlayerSkullType(cid))

        return TRUE
        end
end
 
Code:
        local nonremskulls =  -- These are the skulls it cant remove. If player has any of these, the rune wont work.
{
        white = SKULL_WHITE
}
should be
Code:
	local nonremskulls = {SKULL_WHITE} -- These are the skulls it cant remove. If player has any of these, the rune wont work.
 
Back
Top