Skip to content

fix(ecs): Use DateTime.UtcNow.Ticks instead of Stopwatch.GetTimestamp#444

Closed
DevD4v3 wants to merge 1 commit into
ikkentim:mainfrom
DevD4v3:patch-3
Closed

fix(ecs): Use DateTime.UtcNow.Ticks instead of Stopwatch.GetTimestamp#444
DevD4v3 wants to merge 1 commit into
ikkentim:mainfrom
DevD4v3:patch-3

Conversation

@DevD4v3

@DevD4v3 DevD4v3 commented Nov 9, 2024

Copy link
Copy Markdown
Contributor

Stopwatch.GetTimestamp is causing issues on Linux. On this platform, timers run immediately instead of executing at the specified interval. This behavior does not occur on Windows, where the timer works as expected and runs at the correct interval.

@ikkentim

ikkentim commented Mar 1, 2025

Copy link
Copy Markdown
Owner

GetTimestamp uses QueryPerformanceFrequency which should be better performant and acurate. if you show me some repro code i can take a look at the bug you're running into

@DevD4v3

DevD4v3 commented Mar 16, 2025

Copy link
Copy Markdown
Contributor Author

@ikkentim I don't really have a specific code for you to reproduce the problem, since I had this problem some time ago on my server and I had to publish my own version of SampSharp.Entities.

Perhaps the example of aSpine could be used: https://discord.com/channels/758751593725558794/758944561132994570/959920070363070504

@DevD4v3

DevD4v3 commented Jun 13, 2026

Copy link
Copy Markdown
Contributor Author

I'm closing this PR.
This was fixed at #602

@DevD4v3 DevD4v3 closed this Jun 13, 2026
@DevD4v3 DevD4v3 deleted the patch-3 branch June 13, 2026 20:48
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.

2 participants