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

Magic improvements #676

Merged
merged 1 commit into from
Aug 25, 2024
Merged

Magic improvements #676

merged 1 commit into from
Aug 25, 2024

Conversation

thokkat
Copy link
Contributor

@thokkat thokkat commented Aug 24, 2024

Some refactor/cleanup of the switch statements e.g. fallback for teleport spells is no longer needed after changes to animation start function.

PR has fixes for these issues:

  • SPL_DONTINVEST allows the player to hold the charged spell until key is released. investedMana is then no longer accumulated.

Gothic 1 exclusive:

  • A lot of spells ( i.e teleport, firerain) use the SHOOT animation as cast animation. If castLevel is in CS_Cast range SHOOT animation would be started a second time after spell is already sent. To prevent this play animation only if CAST animation exists.
  • When a teleport spell is aborted transition to idle animation could be skipped by walking forward. CS_Finalize is now handled like CS_Emit except spell is not committed.
  • For code=SPL_NEXTLEVEL change castLevel only if castLvl<15 instead of castLvl<=15. Otherwise it was possible to jump from CS_Invest to CS_Cast which broke spells like summon demon with a long cast phase.

@Try Try merged commit 5157560 into Try:master Aug 25, 2024
1 check passed
@Try
Copy link
Owner

Try commented Aug 25, 2024

Look good - merged.
Thanks @thokkat !

@thokkat thokkat deleted the magic-p1 branch August 25, 2024 17:50
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.

2 participants