fixes #3178 invisible superpower charge bars in spectator mode

This commit is contained in:
Matthias Mailänder
2013-05-11 12:52:11 +02:00
parent b301bc1d79
commit 904c6b76b5

View File

@@ -27,7 +27,7 @@ namespace OpenRA.Mods.RA
public float GetValue() public float GetValue()
{ {
// only people we like should see our charge status. // only people we like should see our charge status.
if (self.World.LocalPlayer != null && self.Owner.Stances[self.World.LocalPlayer] != Stance.Ally) if (!self.Owner.IsAlliedWith(self.World.RenderPlayer))
return 0; return 0;
var spm = self.Owner.PlayerActor.Trait<SupportPowerManager>(); var spm = self.Owner.PlayerActor.Trait<SupportPowerManager>();