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

Makes the emergency shuttle and status display process timed to the second #36388

Conversation

SECBATON-GRIFFON
Copy link
Contributor

@SECBATON-GRIFFON SECBATON-GRIFFON commented Apr 21, 2024

[bugfix]

What this does

so displays don't skip from 0:06 to 0:04 for example
changes emergency shuttle subsystem update from 2 to 1 seconds, supply shuttle one was already on 1 anyways

Changelog

🆑

  • bugfix: Shuttle timers on status displays no longer skip a second on countdown.
  • bugfix: The emergency shuttle no longer docks a second late, arriving at the correct ETA of 0:00 instead of -0:01.

@DamianX
Copy link
Contributor

DamianX commented Apr 21, 2024

Awful way to go about it.
The proper way would be to move this machine into a subsystem that ticks every 1 second instead of 2.

@SECBATON-GRIFFON
Copy link
Contributor Author

Awful way to go about it. The proper way would be to move this machine into a subsystem that ticks every 1 second instead of 2.

i was debating making the shuttles do this too but yea, wasnt sure

@jwhitak jwhitak added the Bug / Fix This is either a bug or a fix for a bug. label Apr 22, 2024
@jwhitak
Copy link
Collaborator

jwhitak commented Apr 22, 2024

I'm going to recommend Damian's implementation over this version. Having a 1 second tick subsystem (or, imo, slightly less than a second, Half a second?) for things like the status screens and other specific machinery that needs the precision would be pretty nice.

@SECBATON-GRIFFON SECBATON-GRIFFON changed the title Fixes status displays skipping a second with shuttles Makes the emergency shuttle and status display process timed to the second Apr 23, 2024
@SECBATON-GRIFFON
Copy link
Contributor Author

redid it

code/controllers/shuttle_controller.dm Outdated Show resolved Hide resolved
Copy link
Collaborator

@jwhitak jwhitak left a comment

Choose a reason for hiding this comment

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

On testing with the escape shuttle, the timers are more accurate on their updating, but are still not perfect. In my testing, I found that about 50% of the time it skips a second. Pretty close though - we might need to make the wait time even shorter in order to properly update so that it guarantees an update to the second even accounting for other strange tick delay stuff.

@SECBATON-GRIFFON
Copy link
Contributor Author

On testing with the escape shuttle, the timers are more accurate on their updating, but are still not perfect. In my testing, I found that about 50% of the time it skips a second. Pretty close though - we might need to make the wait time even shorter in order to properly update so that it guarantees an update to the second even accounting for other strange tick delay stuff.

i'll see what i can do, but if i run into other issues during it i'll leave it as is, i still find it to be an improvement.

@jwhitak jwhitak merged commit 29536e3 into vgstation-coders:Bleeding-Edge Jul 4, 2024
5 checks passed
@SECBATON-GRIFFON SECBATON-GRIFFON deleted the shuttle-display-time-fix branch July 5, 2024 00:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug / Fix This is either a bug or a fix for a bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants