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

DNM: Tgchat fixes #2467

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

DNM: Tgchat fixes #2467

wants to merge 4 commits into from

Conversation

Koshenko
Copy link
Collaborator

About The Pull Request

Test merge to fix tgchat issues

Why It's Good For The Game

Changelog

Kylerace and others added 3 commits October 12, 2023 17:24
reintroduces the intermittent queuing behavior found in #65791 since i can actually recover that part. now after MeasureText() puts us in the player input portion of the tick it will queue a callback for the next tick to resume chat message creation

generate_image() is a highly overtiming proc, now its less so
## About The Pull Request

Ok so like, the agreed upon assumption for "verb like code" (stuff that
triggers when a client sents a network packet to the server), is it runs
in verb time, that sliver of time between maptick and the start of the
next tick.
We thought MeasureText worked like this. It doesn't.

It will, occasionally, resume not during verb time but as a sleeping
proc, at the start of the next tick.
Before the MC has started working.
This appears to only happen when the tick is already overloaded.

Unfortunately, it doesn't invoke after all sleeping procs as we were
lead to believe, but just like, like any sleeping proc.

This means it fights with the mc for cpu time, and doesn't respect the
TICK_CHECK macro we use to ensure this situation doesn't happen.

SOOO lets use a var off the MC instead, tracking when it last fired.
We can use this in companion with TICK_CHECK to ensure verbs schedule
properly if they invoke before the MC runs.

Hopefully this should fix 0 cpu when running at highpop

Thanks to Kylerace and MrStonedOne for suffering together with me on
this, I hate this engine.
@Koshenko Koshenko reopened this Oct 13, 2023
@Koshenko Koshenko added the DNM Do not merge label Oct 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DNM Do not merge Merge Conflict Merge conflict
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants