Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refresh speed on vocation change. #4215

Merged
merged 1 commit into from
Sep 24, 2022
Merged

Refresh speed on vocation change. #4215

merged 1 commit into from
Sep 24, 2022

Conversation

Tofame
Copy link
Contributor

@Tofame Tofame commented Sep 22, 2022

Pull Request Prelude

Changes Proposed

By default, after changing vocation tfs will refresh baseSpeed only after login/leveling up/losing a level. It shouldn't work like that, it should refresh baseSpeed directly on changing vocation to an another one.

Example:
vocation 1 has baseSpeed = 250
vocation 2 has baseSpeed = 300

Then you have code: player:setVocation(2)
You will still have 250 baseSpeed until you do one of the following:

  • Level up
  • Level down
  • Logout->Login

Adding those 3 lines that I suggested to add will make it refresh baseSpeed instantly.

Issues addressed:

By default, after changing vocation tfs will refresh baseSpeed only after login/leveling up/losing a level. It shouldn't work like that, it should refresh baseSpeed directly on changing vocation to an another one.
@Tofame Tofame changed the title Update player.cpp Refresh speed on vocation change. Sep 22, 2022
@EPuncker
Copy link
Contributor

since vocation speed can be changed, this makes sense

@EPuncker EPuncker merged commit 649fd9c into otland:master Sep 24, 2022
EPuncker pushed a commit to EPuncker/forgottenserver that referenced this pull request May 23, 2023
By default, after changing vocation tfs will refresh baseSpeed only after login/leveling up/losing a level. It shouldn't work like that, it should refresh baseSpeed directly on changing vocation to an another one.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants