You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The border bug where the game crashes when panning out to the border is due to missing boundry checks in EntityConfigManager_LoadGeneratedEntities_Patch.Prefix. (LightsOutPatches.cs)
Code below crashes when trying to access cell -1 as CellAbove, CellUpRight etc returns -1 when at the border.
The border bug where the game crashes when panning out to the border is due to missing boundry checks in EntityConfigManager_LoadGeneratedEntities_Patch.Prefix. (LightsOutPatches.cs)
Code below crashes when trying to access cell -1 as CellAbove, CellUpRight etc returns -1 when at the border.
var light = (Grid.LightIntensity[Grid.CellAbove(cell)]
+ Grid.LightIntensity[Grid.CellUpRight(cell)]
+ Grid.LightIntensity[Grid.CellRight(cell)]
+ Grid.LightIntensity[Grid.CellDownRight(cell)]
+ Grid.LightIntensity[Grid.CellBelow(cell)]
+ Grid.LightIntensity[Grid.CellDownLeft(cell)]
+ Grid.LightIntensity[Grid.CellLeft(cell)]
+ Grid.LightIntensity[Grid.CellUpLeft(cell)])
/ 8;
Creating a helper that checks for < 0 seems to fix the problem.
The text was updated successfully, but these errors were encountered: