Skip to content

Adds new timer functions #3683

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

Merged
merged 34 commits into from
Aug 28, 2024
Merged

Conversation

jvstns
Copy link
Contributor

@jvstns jvstns commented Aug 27, 2024

Just practicing and this is something I thought of, surprised it's not already implemented.

bool pauseTimer(timer theTimer, bool paused)
bool setTimerPaused(timer theTimer, bool paused) -- Setting paused to true pauses the timer, while false resumes it.
bool isTimerPaused(timer theTimer) -- returns true if paused

@tederis
Copy link
Member

tederis commented Aug 27, 2024

setTimerPaused is the better name I think.

@tederis tederis added the enhancement New feature or request label Aug 27, 2024
@jvstns
Copy link
Contributor Author

jvstns commented Aug 27, 2024

setTimerPaused is the better name I think.

I thought so too, but i thought other people would think that sounded too weird. I'll change it later when im doing all of the other changes

@tederis
Copy link
Member

tederis commented Aug 27, 2024

paused

If you wish to use pauseTimer then there have to be resumeTimer. pauseTimer means an action and it cannot contain paused(state) argument. So let's just stick to setTimerPaused.

@jvstns jvstns requested a review from TracerDS August 27, 2024 16:03
@jvstns jvstns requested a review from tederis August 27, 2024 16:03
Copy link
Member

@tederis tederis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. And since it overcome several reviews ready to merge.

@tederis tederis merged commit 69aa420 into multitheftauto:master Aug 28, 2024
6 checks passed
MTABot pushed a commit that referenced this pull request Aug 28, 2024
@jvstns jvstns deleted the Implement/NewTimerFuncs branch August 28, 2024 20:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants