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

Skill problem tfs 1.2

Stanos

Veteran OT User
Joined
Jun 12, 2018
Messages
587
Solutions
4
Reaction score
315
Location
Europe
Hello,
i have serious problem with player skill so i have like 36vocations vocation id 1 works just fine you can skill and etc same with id 2-3-4-5-6-9-10 they work fine and etc, when i created char with id 29-28-30 and etc i noticed when i reach for example axe fighting 11 it stops skilling you cant skill anymore same with fishing and etc it stops skilling at 11. Ideas?

Note:
they all created completely same
using tfs 1.2
 
Vocation id : 16 & 17 try them and tell me what happened because i think its because the multiplier some vocs have 2.5 for all and some have 0.5 for all
 
You have 0.5 multiplier in these vocations and it's wrong the base shouldn't be less than 1.1
the formula for skill "tries" is:
Code:
uint64_t tries = static_cast<uint64_t>(skillBase[skill] * std::pow(static_cast<double>(skillMultipliers[skill]), level - 11));
so for skill 11 you have: 500.5^0=501=50 then for skill 12 you have: 500.5^1=500.5=25
then the function that add "tries" to your skill check for data overflow (currentskilltries >= nextskilltries) should mean that you have data overflow thus reached "max" possible skill using the uint64_t value limit.
 
Vocation id : 16 & 17 try them and tell me what happened because i think its because the multiplier some vocs have 2.5 for all and some have 0.5 for all
Eagle eye it makes sense because vocation who have 2.5 works fine and those who have 0.5 doesnt work stucks at 11skill. I will test it later at that time can you explain what what
XML:
        <skill id="1" multiplier="2.5" />
        <skill id="2" multiplier="2.5" />
        <skill id="3" multiplier="2.5" />
does?
 
then as i told you use this one and it will work then , changed all 0.5 to 2.5

Eagle eye it makes sense because vocation who have 2.5 works fine and those who have 0.5 doesnt work stucks at 11skill. I will test it later at that time can you explain what what
XML:
        <skill id="1" multiplier="2.5" />
        <skill id="2" multiplier="2.5" />
        <skill id="3" multiplier="2.5" />
does?
for example i think skill id 1 is fist its is the mulitplier of gaining skill levels in it when you made it 0.5 it was less than 1 so it wasn't giving you any skills
 
You have 0.5 multiplier in these vocations and it's wrong the base shouldn't be less than 1.1
the formula for skill "tries" is:
Code:
uint64_t tries = static_cast<uint64_t>(skillBase[skill] * std::pow(static_cast<double>(skillMultipliers[skill]), level - 11));
so for skill 11 you have: 500.5^0=501=50 then for skill 12 you have: 500.5^1=500.5=25
then the function that add "tries" to your skill check for data overflow (currentskilltries >= nextskilltries) should mean that you have data overflow thus reached "max" possible skill using the uint64_t value limit.
Mine formula is a little bit different
uint64_t tries = static_cast<uint64_t>(skillBase[skill] + static_cast<double>((level + static_cast<double>(level * skillMultipliers[skill])) * skillMultipliers[skill]) * skillMultipliers[skill]);
then as i told you use this one and it will work then , changed all 0.5 to 2.5


for example i think skill id 1 is fist its is the mulitplier of gaining skill levels in it when you made it 0.5 it was less than 1 so it wasn't giving you any skills
Yea
 
You have different formula but it doesn't mean it don't meet the condition "(currentskilltries >= nextskilltries)"
with your formula for 11 skill you have 54.125 tries and for 12 skill 54.5 after casting it to uint64_t you have in both cases 54
you can remove this part:
Code:
uint64_t currReqTries = vocation->getReqSkillTries(skill, skills[skill].level);
uint64_t nextReqTries = vocation->getReqSkillTries(skill, skills[skill].level + 1);
if (currReqTries >= nextReqTries) {
//player has reached max skill
return;
}
in player.cpp function "addSkillAdvance" however I don't recommend doing this.
 
Back
Top