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

fix inaccurate elapsed time #10

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

davidkra230
Copy link

No description provided.

@Baileyeatspizza
Copy link
Contributor

while its true tick may be a little bit inaccurate it has a higher resolution then os.time

Screenshot 2022-01-11 at 22 28 32

os.time is accurate but lacks in precision
where tick is precise but lacks in accuracy

so it just depends if the plugin needs accuracy or precision
image

@iArxic
Copy link

iArxic commented Dec 18, 2022

it doesn't matter that it lacks "precision" or "accuracy"

the plugin incorrectly sets the elapsed time, fix for it is to set the os.time() or tick() on boot of the plugin (an attribute of the script) and that'd be used to get the start time.

@davidkra230
Copy link
Author

The inaccuracy i was referencing was that tick does not or atleast did not at the time obey timezone offsets, os.time did.
i do not know if this is or was a roblox glitch but my fix did fix it.

@iArxic
Copy link

iArxic commented Dec 19, 2022

oh wait you were talking about obeying timezone offsets,
yeah os.time is always the same on all servers and tick is client specific

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