Skip to content

Fix performance on locked "Head- Tail lights" by removing unnecessary state updates - #14

Open
notstevy wants to merge 1 commit into
ProgrammerLP:1.20.1C6from
notstevy:fix/performance-on-locked-htlbs
Open

Fix performance on locked "Head- Tail lights" by removing unnecessary state updates#14
notstevy wants to merge 1 commit into
ProgrammerLP:1.20.1C6from
notstevy:fix/performance-on-locked-htlbs

Conversation

@notstevy

@notstevy notstevy commented Aug 6, 2026

Copy link
Copy Markdown

When these lights were in the locked mode, they were updated when the driving direction did not match their configured value and immediately updated back to the old value (since they were locked).
This behavior caused lag spikes because Create had to update the train twice for each misconfigured light, even though updates were unwanted.
Now, the light mode checks are only run in the unlocked mode, which improves performance immensely.

This fixes the issue #13

When these lights were in the locked mode, they were updated when the driving direction did not match their configured value and immediately updated back to the old value (since they were locked).
This behavior caused lag spikes because Create had to update the train twice for each misconfigured light, even though updates were unwanted.
Now, the light mode checks are only run in the unlocked mode, which improves performance immensely.
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.

1 participant