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

Handle being silenced during casting animation #2686

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Aug 15, 2024

  1. Handle being silenced during casting animation

    If player is silenced, only readySpell is reset by SilenceCheck():
    https://github.com/Interkarma/daggerfall-unity/blob/master/Assets/Scripts/Game/MagicAndEffects/EntityEffectManager.cs#L1941
    
    If this happens during spellcasting animation, castInProgress is true,
    and stays at true after the animation is finished because the first
    thing PlayerSpellCasting_OnReleaseFrame() checks is whether readySpell
    is not null:
    https://github.com/Interkarma/daggerfall-unity/blob/master/Assets/Scripts/Game/MagicAndEffects/EntityEffectManager.cs#L2101
    
    Consequently, player cannot cast spells until (s)he reload a game.
    
    This PR resets castInProgress unconditionally at the beginning of
    PlayerSpellCasting_OnReleaseFrame(), which is consistent with the
    animation being over.
    
    Forums: https://forums.dfworkshop.net/viewtopic.php?t=6763
    petchema committed Aug 15, 2024
    Configuration menu
    Copy the full SHA
    77b23be View commit details
    Browse the repository at this point in the history