Revert "In RemoveCellsFromPlayerShroud, don't call RemoveSource unless required."
This reverts commit 86b9227577.
This commit relied on the relationship not changing, but when a player is defeated their relationship can change due to becoming a spectator. This can cause a crash if the shroud is not removed. Revert the commit to resolve this crash.
This commit is contained in:
committed by
Gustas Kažukauskas
parent
89a4823a83
commit
ba632fbf8b
@@ -49,13 +49,7 @@ namespace OpenRA.Mods.Common.Effects
|
||||
p.Shroud.AddSource(this, sourceType, uv);
|
||||
}
|
||||
|
||||
void RemoveCellsFromPlayerShroud(Player p)
|
||||
{
|
||||
if (!validStances.HasRelationship(player.RelationshipWith(p)))
|
||||
return;
|
||||
|
||||
p.Shroud.RemoveSource(this);
|
||||
}
|
||||
void RemoveCellsFromPlayerShroud(Player p) { p.Shroud.RemoveSource(this); }
|
||||
|
||||
PPos[] ProjectedCells(World world)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user