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

Lua 0 frags and red skull relog doesnt help

Zoolek

Member
Joined
Jul 3, 2017
Messages
93
Solutions
1
Reaction score
11
Why when i use frag remover it clean frags, but when i relog red skull still exists?
I have 0 frags i shoudnt be rs?

Code:
 Frag remover
local config =
{
    item = 9999,  -- item id
    level = 1, -- min lvl
    count = 0
}
function onUse(cid, item, frompos, item2, topos)
if getPlayerLevel(cid) >= config.level then
        doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Your frags reseted.")
        doSendMagicEffect(getPlayerPosition(cid), 20)
        doRemoveItem(item.uid)
        db.executeQuery("UPDATE `killers` SET `unjustified` = 0 WHERE `id` IN (SELECT `kill_id` FROM `player_killers` WHERE `player_id` = " .. getPlayerGUID(cid) .. ")")
    else
        doPlayerSendCancel(cid, "Nie masz odpowiedniego poziomu")
    end
    return TRUE
end
 
Last edited:
bump
skulltime.lua
Code:
function onThink(cid, interval)
    if(not isCreature(cid)) then
        return
    end
    local skull, skullEnd = getCreatureSkull(cid), getPlayerSkullEnd(cid)
    if(skullEnd > 0 and skull > SKULL_WHITE and os.time() > skullEnd and not getCreatureCondition(cid, CONDITION_INFIGHT)) then
        doPlayerSetSkullEnd(cid, 0, skull)
    end
end
 
Last edited:
Back
Top