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

Player - Spell Experience - 1.2

I changed to
Code:
function onExtendedOpcode(player, opcode, buffer)
     local skillStorage = math.max(10, getPlayerStorageValue(player, 15000)
    local skillTries =  math.max(0, getPlayerStorageValue(player, 15000 + 1))
    local triesNeeded = math.floor(20 * math.pow(1.1, (skillStorage - 11)) / 10)
    local percent = math.floor(100 * (1 - skillTries / triesNeeded))
    if percent > 1 and percent <= 100 then
        return percent
    else
        percent = 1
        return percent
    end
    player:sendExtendedOpcode(54, percent)
    return true
end

getPlayerStorageValue(player, 15000)


receives the storage but does not show the client the percentage have any other way to display the percentage of skill ?
 
I changed to
Code:
function onExtendedOpcode(player, opcode, buffer)
     local skillStorage = math.max(10, getPlayerStorageValue(player, 15000)
    local skillTries =  math.max(0, getPlayerStorageValue(player, 15000 + 1))
    local triesNeeded = math.floor(20 * math.pow(1.1, (skillStorage - 11)) / 10)
    local percent = math.floor(100 * (1 - skillTries / triesNeeded))
    if percent > 1 and percent <= 100 then
        return percent
    else
        percent = 1
        return percent
    end
    player:sendExtendedOpcode(54, percent)
    return true
end

getPlayerStorageValue(player, 15000)


receives the storage but does not show the client the percentage have any other way to display the percentage of skill ?
I have no idea, besides this goes beyond the scope of the original post, I will not write or fix your scripts go to support boards.
 
Back
Top