Merge pull request #3009 from ScottNZ/mtm-shroud
Fixes a couple of shroud issues
This commit is contained in:
@@ -48,13 +48,7 @@ namespace OpenRA.Traits
|
||||
get { return Disabled ? null : exploredBounds; }
|
||||
}
|
||||
|
||||
public event Action Dirty = () => { };
|
||||
|
||||
public void Jank()
|
||||
{
|
||||
Dirty();
|
||||
}
|
||||
|
||||
public Action Dirty = () => { };
|
||||
|
||||
public Shroud(World world)
|
||||
{
|
||||
|
||||
@@ -281,13 +281,23 @@ namespace OpenRA.Mods.RA.Missions
|
||||
void OnSuperTankDomeInfiltrated(Actor spy)
|
||||
{
|
||||
if (superTankDomeInfiltratedTick != -1) return;
|
||||
|
||||
superTankDome.QueueActivity(new Transform(superTankDome, "dome") { SkipMakeAnims = true });
|
||||
turkey.Stances[greece] = turkey.Stances[neutral] = Stance.Ally;
|
||||
greece.Stances[turkey] = neutral.Stances[turkey] = Stance.Ally;
|
||||
greece.Shroud.ExploreAll(world);
|
||||
|
||||
world.AddFrameEndTask(_ =>
|
||||
{
|
||||
superTanks.Do(world.Remove);
|
||||
turkey.Stances[greece] = turkey.Stances[neutral] = Stance.Ally;
|
||||
greece.Stances[turkey] = neutral.Stances[turkey] = Stance.Ally;
|
||||
greece.Shroud.ExploreAll(world);
|
||||
superTanks.Do(world.Add);
|
||||
});
|
||||
|
||||
foreach (var tank in superTanks.Where(t => !t.IsDead() && t.IsInWorld))
|
||||
MissionUtils.AttackNearestLandActor(false, tank, ussr);
|
||||
|
||||
superTankDomeInfiltratedTick = world.FrameNumber;
|
||||
|
||||
objectives[InfiltrateRadarDomeID].Status = ObjectiveStatus.Completed;
|
||||
OnObjectivesUpdated(true);
|
||||
}
|
||||
|
||||
@@ -41,11 +41,11 @@ namespace OpenRA.Mods.RA.Widgets.Logic
|
||||
var views = world.Players.Where(p => !p.NonCombatant).ToDictionary(p => p.PlayerName,
|
||||
p => new CameraOption("{0}'s view".F(p.PlayerName),
|
||||
() => world.RenderedPlayer == p,
|
||||
() => { world.RenderedPlayer = p; world.RenderedShroud.Jank(); }
|
||||
() => { world.RenderedPlayer = p; world.RenderedShroud.Dirty(); }
|
||||
));
|
||||
views.Add("", new CameraOption("World view",
|
||||
() => world.RenderedPlayer == null,
|
||||
() => { world.RenderedPlayer = null; world.RenderedShroud.Jank(); }
|
||||
() => { world.RenderedPlayer = null; world.RenderedShroud.Dirty(); }
|
||||
));
|
||||
|
||||
var shroudSelector = widget.Get<DropDownButtonWidget>("SHROUD_SELECTOR");
|
||||
|
||||
Reference in New Issue
Block a user