Add self argument to Move constructors.
This commit is contained in:
@@ -324,9 +324,9 @@ namespace OpenRA.Mods.RA.Scripting
|
||||
public void AttackMove(Actor actor, CPos location, double nearEnough)
|
||||
{
|
||||
if (actor.HasTrait<AttackMove>())
|
||||
actor.QueueActivity(new AttackMove.AttackMoveActivity(actor, new Move.Move(location, (int)nearEnough)));
|
||||
actor.QueueActivity(new AttackMove.AttackMoveActivity(actor, new Move.Move(actor, location, (int)nearEnough)));
|
||||
else
|
||||
actor.QueueActivity(new Move.Move(location, (int)nearEnough));
|
||||
actor.QueueActivity(new Move.Move(actor, location, (int)nearEnough));
|
||||
}
|
||||
|
||||
[LuaGlobal]
|
||||
|
||||
@@ -25,14 +25,14 @@ namespace OpenRA.Mods.RA.Scripting
|
||||
"(in cells) that will be considered close enough to complete the activity.")]
|
||||
public void Move(CPos cell, int closeEnough = 0)
|
||||
{
|
||||
self.QueueActivity(new Move.Move(cell, WRange.FromCells(closeEnough)));
|
||||
self.QueueActivity(new Move.Move(self, cell, WRange.FromCells(closeEnough)));
|
||||
}
|
||||
|
||||
[ScriptActorPropertyActivity]
|
||||
[Desc("Moves within the cell grid, ignoring lane biases.")]
|
||||
public void ScriptedMove(CPos cell)
|
||||
{
|
||||
self.QueueActivity(new Move.Move(cell));
|
||||
self.QueueActivity(new Move.Move(self, cell));
|
||||
}
|
||||
|
||||
[ScriptActorPropertyActivity]
|
||||
|
||||
Reference in New Issue
Block a user