AppendCommand
Objects
Commands
1.0 OC
bool
string
command
Command name (as string). See the table below.
object
target
target object for the command
int
x
X target coordinate
int
y
Y target coordinate
object
target2
secondary target object
int
delay
Time (in ticks or frames) until the command is terminated.
any
Data
additional data for the command
int
retries
Number of retries if the command fails, until the command fails completely.
int
base_mode
Command stack mode. See AddCommand for values.
Appends a command to the command stack of an object. The appended command will be executed after the current other commands.
For command descriptions see SetCommand
Notice: commands set by AppendCommand are not transferred to controlled vehicles (see VehicleControl).
var base = FindBase();
SetCommand("MoveTo", base);
AppendCommand("Throw", nil, base->GetX(), base->GetY());
Gives the clonk the command to go to the first found base and then throw the first carried object at the base.
SetCommand
GetCommand
AddCommand
FinishCommand
PeterW2001-11