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

Rate Multipliers Aren't Working TFS 1.0>1.1

Jeffro

Alpha
Joined
Jan 17, 2015
Messages
235
Reaction score
262
Location
New York
[EDIT] SOLVED: FORGOT TO UPDATE EVENTS :S

Hello,
The issue I am having is the rate multipliers. So what I did before the issue. I had TFS 1.0, rates were working perfectly. Then I had upgraded to TFS 1.1. No issues while compiling. It's the latest TFS 1.1.

Now, I've tried disabling stages and using the config.lua rates, but none of the rates are working, not even skills. I've disabled the stamina system even. Still when I kill a monster, which as 1x rate gives 20exp., with 500x or 7x, this monster still gives 20exp.


Here is in-game info:
Code:
18:30 Server Info:
Exp rate: 7
Skill rate: 40
Magic rate: 30
Loot rate: 2
______________________
18:30 You gained 20 experience points.

Here is a monster example:
Code:
<monster name="Azure Frog" namedescription="a azure frog" race="blood" experience="20" speed="200" manacost="305">

Here is my config.lua:
Code:
-- Rates
-- NOTE: rateExp is not used if you have enabled stages in data/XML/stages.xml
rateExp = 500
rateSkill = 40
rateLoot = 2
rateMagic = 30
rateSpawn = 1

And my Stages.xml:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<stages>
    <config enabled="1"/>
    <stage minlevel="1" maxlevel="8" multiplier="7"/>
    <stage minlevel="9" maxlevel="20" multiplier="6"/>
    <stage minlevel="21" maxlevel="50" multiplier="5"/>
    <stage minlevel="51" maxlevel="100" multiplier="4"/>
    <stage minlevel="101" multiplier="5"/>
</stages>
 
Last edited:
had some skillrate issues too for my server.
What i did was went back for TFS 1.0 :|

Sry if i was no help. But honestly TFS 1.0 is better. only missing few metamethods. But you can replace them all with scripts.
 
had some skillrate issues too for my server.
What i did was went back for TFS 1.0 :|

Sry if i was no help. But honestly TFS 1.0 is better. only missing few metamethods. But you can replace them all with scripts.

Well it wasn't so much as a bug, just my dumb-ass forgetting to fully update. I updated from 1.0 to 1.1, while there were updates within the events folder that consisted with players receiving the correct experience after being multiplied by the rate. Where I updated everything but what was in the events.

So it looks like experience has changed with how the players technically receive it, where it was originally source coded.

\data\events\scripts\player.lua:
Code:
function Player:onGainExperience(source, exp, rawExp)
    if not source or source:isPlayer() then
        return exp
    end

    -- Soul regeneration
    local vocation = self:getVocation()
    if self:getSoul() < vocation:getMaxSoul() and exp >= self:getLevel() then
        soulCondition:setParameter(CONDITION_PARAM_SOULTICKS, vocation:getSoulGainTicks() * 1000)
        self:addCondition(soulCondition)
    end

    -- Apply experience stage multiplier
    exp = exp * Game.getExperienceStage(self:getLevel())

    -- Stamina modifier
    if configManager.getBoolean(configKeys.STAMINA_SYSTEM) then
        useStamina(self)

        local staminaMinutes = self:getStamina()
        if staminaMinutes > 2400 and self:isPremium() then
            exp = exp * 1.5
        elseif staminaMinutes <= 840 then
            exp = exp * 0.5
        end
    end

    return exp
end
 
Back
Top