Skip to content

[IDEA] Make AbilityCooldown read InitialTime #111

@xaze1

Description

@xaze1

Goal Description

The AbilityCooldown class only sends the NextUse variable and sets InitialTime to NetworkTime.time every time
SCP-3114 uses a Cooldown for the Remaining time of it's disguise

Resending the current Identity of SCP-3114, if they are disguised, would reset the Remaining Duration circle to full.
It would probably confuse players and this would fix it

Notes

This is how I would just do the reading and writing in the AbilityCooldown class:

public virtual void ReadCooldown(NetworkReader reader)
{
    NextUse = reader.ReadDouble();
    InitialTime = reader.ReadDouble();
}

public virtual void WriteCooldown(NetworkWriter writer)
{
    writer.WriteDouble(NextUse);
    writer.WriteDouble(InitialTime);
}

This is mostly for Plugin Developers wanting to do stuff with Ability Cooldowns without making the Player notice it visually

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions