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

Make AOE game condition causer use correct map time, fixes #210 #494

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

Conversation

SokyranTheDragon
Copy link
Member

In simple terms, this will fix issues with condition causers, like smoke spewer or psychic suppressor sites.

CompCauseGameCondition iterates over the list of each maps that it affects, where it either creates the game condition, or updates the remaining ticks for it.

The issue is that it uses Find.TickManager.TicksGame when doing so, which causes the affected maps to receive the time from either the world (if the Thing the comp is part of happens to be attached to a world object), or the specific map (if the Thing is spawned on an actual map).

The change here is to properly use the actual ticks from the specific map that is affected.

A slight side note - this won't fix maps where the game condition is active, but the condition causer was destroyed. This is due to the condition causer updating the game condition, while the game condition itself does not have any references to the causer itself.

In simple terms, this will fix issues with condition causers, like smoke spewer or psychic suppressor sites.

`CompCauseGameCondition` iterates over the list of each maps that it affects, where it either creates the game condition, or updates the remaining ticks for it.

The issue is that it uses `Find.TickManager.TicksGame` when doing so, which causes the affected maps to receive the time from either the world (if the `Thing` the comp is part of happens to be attached to a world object), or the specific map (if the `Thing` is spawned on an actual map).

The change here is to properly use the actual ticks from the specific map that is affected.

A slight side note - this won't fix maps where the game condition is active, but the condition causer was destroyed. This is due to the condition causer updating the game condition, while the game condition itself does not have any references to the causer itself.
@SokyranTheDragon SokyranTheDragon added async Bugs or issues only in async time mode. 1.5 Fixes or bugs relating to 1.5 (Not Anomaly). labels Aug 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1.5 Fixes or bugs relating to 1.5 (Not Anomaly). async Bugs or issues only in async time mode.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant