Skip to content

Fixed timer being off by 1 tick#18

Merged
LexManos merged 1 commit into
LexManos:masterfrom
LatvianModder:timer-patch
Nov 16, 2021
Merged

Fixed timer being off by 1 tick#18
LexManos merged 1 commit into
LexManos:masterfrom
LatvianModder:timer-patch

Conversation

@LatvianModder
Copy link
Copy Markdown
Contributor

Intent of this timer was to be "every x ticks", but the current version is always 1 extra because if (timer-- <= 0) compares first, then decrements the number.

@LexManos
Copy link
Copy Markdown
Owner

Ya, it was meant to be the number of ticks per update, so 1 being every tick.
Thats why the default values are what they are.
Yay order of things.

@LexManos LexManos merged commit 2a01475 into LexManos:master Nov 16, 2021
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.

3 participants