correct cursor for healing
This commit is contained in:
@@ -138,6 +138,7 @@ namespace OpenRa.Game
|
|||||||
switch( s )
|
switch( s )
|
||||||
{
|
{
|
||||||
case "Attack": return Cursor.Attack;
|
case "Attack": return Cursor.Attack;
|
||||||
|
case "Heal": return Cursor.Heal;
|
||||||
case "C4": return Cursor.C4;
|
case "C4": return Cursor.C4;
|
||||||
case "Move":
|
case "Move":
|
||||||
if (movement.CanEnterCell(location))
|
if (movement.CanEnterCell(location))
|
||||||
|
|||||||
@@ -25,5 +25,6 @@ namespace OpenRa.Game
|
|||||||
public static Cursor Chronoshift { get { return new Cursor("chrono"); } }
|
public static Cursor Chronoshift { get { return new Cursor("chrono"); } }
|
||||||
public static Cursor C4 { get { return new Cursor("c4"); } }
|
public static Cursor C4 { get { return new Cursor("c4"); } }
|
||||||
public static Cursor Capture { get { return new Cursor("capture"); } }
|
public static Cursor Capture { get { return new Cursor("capture"); } }
|
||||||
|
public static Cursor Heal { get { return new Cursor("heal"); } }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -146,12 +146,12 @@ namespace OpenRa.Game.Traits
|
|||||||
if (((underCursor.Owner == self.Owner) ^ isHeal)
|
if (((underCursor.Owner == self.Owner) ^ isHeal)
|
||||||
&& !mi.Modifiers.HasModifier( Modifiers.Ctrl )) return null;
|
&& !mi.Modifiers.HasModifier( Modifiers.Ctrl )) return null;
|
||||||
if (!Combat.HasAnyValidWeapons(self, underCursor)) return null;
|
if (!Combat.HasAnyValidWeapons(self, underCursor)) return null;
|
||||||
return new Order("Attack", self, underCursor, int2.Zero, null);
|
return new Order(isHeal ? "Heal" : "Attack", self, underCursor, int2.Zero, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void ResolveOrder(Actor self, Order order)
|
public void ResolveOrder(Actor self, Order order)
|
||||||
{
|
{
|
||||||
if (order.OrderString == "Attack")
|
if (order.OrderString == "Attack" || order.OrderString == "Heal")
|
||||||
{
|
{
|
||||||
self.CancelActivity();
|
self.CancelActivity();
|
||||||
QueueAttack(self, order);
|
QueueAttack(self, order);
|
||||||
|
|||||||
@@ -388,7 +388,7 @@
|
|||||||
<sequence name="guard-minimap" start="146" length="1" />
|
<sequence name="guard-minimap" start="146" length="1" />
|
||||||
<sequence name="guard" start="147" length="1" x="12" y="12" />
|
<sequence name="guard" start="147" length="1" x="12" y="12" />
|
||||||
<sequence name="sell-vehicle" start="148" length="12" />
|
<sequence name="sell-vehicle" start="148" length="12" />
|
||||||
<sequence name="heal" start="160" length="4" />
|
<sequence name="heal" start="160" length="4" x="12" y="12"/>
|
||||||
<sequence name="capture" start="164" length="3" />
|
<sequence name="capture" start="164" length="3" />
|
||||||
<sequence name="capture-minimap" start="167" length="3" />
|
<sequence name="capture-minimap" start="167" length="3" />
|
||||||
<sequence name="repair2" start="170" length="24" />
|
<sequence name="repair2" start="170" length="24" />
|
||||||
|
|||||||
Reference in New Issue
Block a user