Skip to content

Countdown example not working #21

@goofee76

Description

@goofee76

I was looking for a countdown timer with pause for a project I'm doing. Unfortunately, the countdown timer example doesn't work as written. The call to ResumeTimer in every loop resets the timer so it can never advance. This adjustment seems to work.
void ResumeTimer() // You can resume the timer if you ever stop it. { if (Paused) { Paused = false; time = _InternalClock(); } }

Also, I'm not sure why there's an if (Paused) inside the if (!Stop && !Paused) condition. It should never make it there, or is there something I'm missing?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions