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

SSA Exhaust on tfs 0.4

Axelor

Member
Joined
Sep 2, 2010
Messages
505
Reaction score
9
The SSA Exhaust works on this script, but the charges won't get removed when get hit by monster or sd.

PHP:
local storage = 9500
local fixStorage = 8000
local time = 4

function onEquip(cid, item, slot, boolean)
    if getPlayerStorageValue(cid, fixStorage) == 1 then
        doPlayerSetStorageValue(cid, fixStorage, -1)
        return callFunction(cid, item.uid, slot, boolean)
    end
    if getPlayerStorageValue(cid, storage) >= os.time() then
        print("exhausted")
        return false
    end
    doPlayerSetStorageValue(cid, storage, os.time() + time)
    doPlayerSetStorageValue(cid, fixStorage, 1)
    print("exhaustion set for 5 seconds")
    return true
end

function onDeEquip(cid, item, slot, boolean)
    return callFunction(cid, item.uid, slot, boolean)
end

I can say you that, when I logged in with the stone skin amulet on. On console it says the message: "You are exhausted for 5 seconds". After I get hit by an monster for first 4-5 second I lose charges and after I dont. And only when I relog and I do this again I will lose charges again.

Anyone have any idea how to make this work?

This is added to movements.xml

PHP:
    <movevent type="Equip" itemid="2197" slot="necklace" event="script" value="ssaexhaust.lua"/>
    <movevent type="DeEquip" itemid="2197" slot="necklace" event="script" value="ssaexhaust.lua"/>


Edit: Will pay 15- 20 EUR For the person that can help me make this ssa exhaust implement on the sources <-- maybe better
 
Back
Top