Difference between revisions of "Unit commands"

From Zero-K
Jump to navigation Jump to search
(Using local images in the table.)
 
(21 intermediate revisions by 12 users not shown)
Line 2: Line 2:
  
 
== Command Types ==
 
== Command Types ==
There are three main types of command: targeted commands, instant commands and state toggles.  
+
There are three main types of command: targeted commands, instant commands and state toggles.
 
+
* '''Targeted commands''' are issued with a target. Targets can include units and map features (rocks, trees, wrecks) as well as positions, areas and lines drawn that you draw on the map when the command is issued. Targeting lines, areas or multiple units or features is commonly achieved by clicking an dragging.
'''Targeted commands''' are issued with a target. Targets can include units and map features (rocks, trees, wrecks) as well as positions, areas and lines drawn that you draw on the map when the command is issued. Targeting lines, areas or multiple units or features is commonly achieved by clicking an dragging.
+
* '''Instant commands''' activate unit abilities that require no target.
 
+
* '''State toggles''' are standing orders that modify behaviour or toggle certain abilities.
'''Instant commands''' activate unit abilities that require no target.
 
 
 
'''State toggles''' are standing orders that modify behaviour or toggle certain abilities.
 
  
 
== Giving Commands ==
 
== Giving Commands ==
Line 14: Line 11:
  
 
Targeted commands can be issued with either the left or right mouse buttons.
 
Targeted commands can be issued with either the left or right mouse buttons.
* Click the '''left mouse button''' to issue a context sensitive command. The command that will be issued is indicated by the mouse cursor and depends on both your unit selection and the target of the command. Common examples are [[Force Fire Command|force fire]] when the target is an enemy unit and [[Move Command|move]] when the the target is empty ground.
+
* Click the '''right mouse button''' to issue a context sensitive command. The command that will be issued is indicated by the mouse cursor and depends on both your unit selection and the target of the command. Common examples are [[Force Fire Command|force fire]] when the target is an enemy unit and [[Move Command|move]] when the the target is empty ground.
* Click the '''right mouse button''' to issue a command selected. To select a command click on its button in the command panel or press its hotkey. The selected command is indicated by the mouse cursor and a highlighted command button. Issue the command (without holding Shift) or left click to deselect the command.
+
* Click the '''left mouse button''' to issue a command selected. To select a command click on its button in the command panel or press its hotkey. The selected command is indicated by the mouse cursor and a highlighted command button. Issue the command (without holding Shift) or right click to deselect the command.
  
 
Targeted commands can be modified in many ways.
 
Targeted commands can be modified in many ways.
Line 24: Line 21:
 
== Queuing and Inserting Commands ==
 
== Queuing and Inserting Commands ==
 
Units maintain a list of commands, known as their command queue, that are executed in order as each command is completed. Most targeted and instant commands can be added to the end of the queue or inserted or inserted into the queue. State toggles cannot be added to the queue and always take effect instantly.
 
Units maintain a list of commands, known as their command queue, that are executed in order as each command is completed. Most targeted and instant commands can be added to the end of the queue or inserted or inserted into the queue. State toggles cannot be added to the queue and always take effect instantly.
* Hold '''Shift''' while issuing a targeted or instant command to add it to the end of the command queue.
+
* Hold '''SHIFT''' while issuing a targeted or instant command to add it to the end of the command queue.
* Hold '''Space''' while issuing a targeted command to add it to the start of the command queue, pushing the current command to the second spot in the queue.
+
* Hold '''SPACE''' while issuing a targeted command to add it to the start of the command queue, pushing the current command to the second spot in the queue.
* Hold '''Shift and Space''' while issuing a targeted command to insert it at the point in the command queue that would result in the least extra travel time.
+
* Hold '''SHIFT+SPACE''' while issuing a targeted command to insert it at the point in the command queue that would result in the least extra travel time.
  
 
A targeted command that is issued without holding Shift or Space cancels the entire command queue, replacing it with the newly issued command. An instant command that is issued without holding Shift or Space immediately executes the command without affecting the rest of the queue. Nobody knows what happens if an instant command is issued with Space held.
 
A targeted command that is issued without holding Shift or Space cancels the entire command queue, replacing it with the newly issued command. An instant command that is issued without holding Shift or Space immediately executes the command without affecting the rest of the queue. Nobody knows what happens if an instant command is issued with Space held.
 +
 +
== Factory Production Commands ==
 +
Factories can make use of unit commands to make produced units take specific actions when leaving the factory.  For example, units can be set to move to a point or patrol as soon as they are produced.
 +
 +
Unit commands given to factories can also be queued and modified, as above.
 +
 +
== Most Common Commands and Modifiers ==
 +
Commands can have their behaviour modified using ALT and CTRL, and can be combined with SHIFT and SPACE to queue commands. Some commands also change their behaviour when targeted on a unit or the ground. See each command's page for details.
 +
 +
{|
 +
!style="width: 10%"|Command
 +
!style="width: 10%"|Click+drag behaviour
 +
!style="width: 20%"|Drag behaviour
 +
!style="width: 20%"|+CTRL
 +
!style="width: 20%"|+ALT
 +
!style="width: 20%"|+CTRL+ALT
 +
|-
 +
|[[Move Command|Move]] (M) [[File:Move.png|none|32px|link=Move Command]]
 +
|Move units to a point.
 +
|Move units into a line.
 +
|Move, maintaining current formation.
 +
|When dragging, move along a line.
 +
|When dragging, move along a line in formation.
 +
|-
 +
|[[Attack Move Command|Attack move]] (A) [[File:Fight.png|none|32px|link=Attack Move Command]]
 +
|Move to a point, using unit AI while moving.
 +
|Same as move, using AI.
 +
|Same as move, using AI.
 +
|Same as move, using AI.
 +
|Same as move, using AI.
 +
|-
 +
|[[Patrol Command|Patrol]] (P) [[File:Patrol.png|none|32px|link=Patrol Command]]
 +
|Move back and forth between current position and a point, using unit AI while moving.
 +
|Same as move, using AI.
 +
|Same as move, using AI.
 +
|Same as move, using AI.
 +
|Same as move, using AI.
 +
|-
 +
|[[Force Fire Command|Force Fire]] (F) [[File:Attack.png|none|32px|link=Force Fire Command]]
 +
|Fire at a point
 +
|Fire at all targets in an area, in a queue.
 +
|When dragging, fire at all targets in an area, splitting fire.
 +
|When dragging, fire along a line.
 +
|
 +
|-
 +
|[[Set Target Command|Set Target]] (T) [[File:Settarget.png|none|32px|link=Set Target Command]]
 +
|Target a unit or point, without moving. Fire at target if in range.  Fire normally if out of range.
 +
|Target the nearest enemy in the circle.
 +
|Target all enemies in the circle, splitting targets.
 +
|Target the ground along a line, firing if in range.
 +
|
 +
|-
 +
|[[Guard Command|Guard]] (G) [[File:Guard.png|none|32px|link=Guard Command]]
 +
|Protect, repair, and assist a unit.
 +
|On unit: guard in circle formation.
 +
On ground: guard all units in the circle.
 +
|For circle formation: guard in a specific direction.
 +
|For circle formation: guard in a direction relative to unit facing.
 +
|For circle formation: do not match guarding unit speeds/positions.
 +
|-
 +
|[[Repair Command|Repair]] (R) [[File:Repair.png|none|32px|link=Repair Command]]
 +
|Repair a live unit; Assist construction.
 +
|Area command. Applies the click command to valid targets in the area, as long as there are any.
 +
|Only repair live units, do not assist construction.
 +
|For area only. Persist the area even when no valid targets inside (continue if any new show up).
 +
|For area only. Persist the area even when no valid targets inside while only repairing live units.
 +
|-
 +
|[[Area Mex Command|Area Mex]] (W) [[File:mex.png|none|32px|link=Area Mex Command]]
 +
|Build a mex at given spot||Queue mexes across the area.
 +
|Surround each mex in the area with 2 solars. Works on already-built mexes.  If a mex is underwater, 2 Tidal Generators are built instead. If on land and flat space is limited, a Wind Generator will be substituted where a Solar does not fit.
 +
|As with +CTRL, except with only one generator per mex, chosen as appropriate.
 +
|As with +CTRL, except with four generators per mex, chosen as appropriate, one on each side.
 +
|
 +
|-
 +
|[[Reclaim Command|Reclaim]] (E) [[File:Reclaim.png|none|32px|link=Reclaim Command]]
 +
|Reclaim target (unit or feature).
 +
|Reclaim features across the area.
 +
|Area only. If centered on a live unit, reclaim all units of this type in the area. Else, ignore metal-less features, such as trees. There is a menu option to do this by default, in which case trees can be reclaimed either with CTRL or by centering the area on a tree.
 +
|Area only. Persist the command even when no features are in the area.
 +
|Area only. Persist the command even when no features are in the area while ignoring(or not, depending on setting) metal-less features
 +
|-
 +
|[[Resurrect Command|Resurrect]] (T) [[File:Resurrect.png|none|32px|link=Resurrect Command]]
 +
|Resurrect target wreck||Area version. Resurrect wrecks in given area as long as there are any; ignore ones that are partially reclaimed.
 +
|Area only. Resurrect even partially reclaimed wrecks (but still not those actively being reclaimed - this requires single target command).
 +
|Area only. Persist the command even when no resurrectables are in the area. Ignores partially reclaimed wrecks.
 +
|Area only. Persist the command even when no resurrectables are in the area. Resurrects partially reclaimed wrecks.
 +
|-
 +
|}
  
 
== Full List of Commands ==
 
== Full List of Commands ==
Common targeted commands:
+
=== Common targeted commands ===
 
* [[Move Command|Move]]
 
* [[Move Command|Move]]
 
* [[Attack Move Command|Attack Move]]
 
* [[Attack Move Command|Attack Move]]
Line 42: Line 127:
 
* [[Patrol Command|Patrol]]
 
* [[Patrol Command|Patrol]]
  
Common economic commands:
+
=== Common economic commands ===
 
* [[Repair Command|Repair]]
 
* [[Repair Command|Repair]]
 
* [[Reclaim Command|Reclaim]]
 
* [[Reclaim Command|Reclaim]]
Line 51: Line 136:
 
* [[Terraform|Terraforming commands]]
 
* [[Terraform|Terraforming commands]]
  
Instant commands:
+
=== Instant commands ===
 
* [[Stop Command|Stop]]
 
* [[Stop Command|Stop]]
 
* [[Wait Command|Wait]]
 
* [[Wait Command|Wait]]
Line 62: Line 147:
 
* [[Stockpile Command|Stockpile]]
 
* [[Stockpile Command|Stockpile]]
  
Transport commands:
+
=== Transport commands ===
 
* [[Load Command|Load]]
 
* [[Load Command|Load]]
 
* [[Unload Command|Unload]]
 
* [[Unload Command|Unload]]
Line 70: Line 155:
 
* [[Transport AI#Embark and Disembark|Disembark]]
 
* [[Transport AI#Embark and Disembark|Disembark]]
  
Unusual commands:
+
=== Unusual commands ===
 
* [[Newton Firezones|Newton firezone commands]]
 
* [[Newton Firezones|Newton firezone commands]]
 
* [[Morph Command|Morph]]
 
* [[Morph Command|Morph]]
Line 82: Line 167:
 
* [[Evacuate Command|Evacuate]]
 
* [[Evacuate Command|Evacuate]]
  
Global commands:
+
=== Global commands ===
 
* [[Ferry Command|Ferry]]
 
* [[Ferry Command|Ferry]]
 
* [[Retreat|Retreat]]
 
* [[Retreat|Retreat]]
* [[Resources Reserve|Reserve]]
+
* [[Economy Guide#Reserving resources|Reserve]]
  
State commands:
+
=== State commands ===
 
* [[Unit states#Fire State|Fire State]]
 
* [[Unit states#Fire State|Fire State]]
 
* [[Unit states#Move State|Move State]]
 
* [[Unit states#Move State|Move State]]
Line 110: Line 195:
 
* [[Unit states#Impulse Mode|Impulse Mode]]
 
* [[Unit states#Impulse Mode|Impulse Mode]]
  
== Modifiers ==
 
  
Commands can have their behaviour modified using ALT and CTRL.
+
{{Navbox commands}}
  
{|
+
{{Navbox manual}}
!style="width: 10%"|Command
 
!style="width: 15%"|Click behaviour
 
!style="width: 20%"|Drag behaviour
 
!style="width: 25%"|+ALT
 
!style="width: 30%"|+CTRL
 
|-
 
|Repair<br/><img src="https://raw.githubusercontent.com/ZeroK-RTS/Zero-K/master/Anims/cursorrepair_0.png"/>
 
|Repair a live unit; Assist construction
 
|Area command. Applies the click command to valid targets in the area, as long as there are any
 
|For area only. Persist the area even when no valid targets inside (continue if any new show up)
 
|Only repair live units, do not assist construction.
 
|-
 
|Mex<br/><img src="https://raw.githubusercontent.com/ZeroK-RTS/Zero-K/master/LuaUI/Images/commands/Bold/mex.png" width="32" height="32"/>
 
|Build a mex at given spot||Queue mexes across the area
 
|Surround each mex in the area with 4 solars. Works on already-built mexes.
 
|None.
 
|-
 
|Reclaim<br/><img src="https://raw.githubusercontent.com/ZeroK-RTS/Zero-K/master/Anims/cursorreclamate_0.png"/>
 
|Reclaim target (unit or feature)
 
|Reclaim features across the area.
 
|Area only. Persist the command even when no features are in the area.
 
|Area only. If centered on a live unit, reclaim all units of this type in the area. Else, ignore metal-less features, such as trees. There is a menu option to do this by default, in which case trees can be reclaimed either with CTRL or by centering the area on a tree.
 
|-
 
|Resurrect<br/><img src="https://raw.githubusercontent.com/ZeroK-RTS/Zero-K/master/Anims/cursorrevive_0.png"/>
 
|Resurrect target wreck||Area version. Resurrect wrecks in given area as long as there are any; ignore ones that are partially reclaimed.
 
|Area only. Persist the command even when no resurrectables are in the area.
 
|Area only. Resurrect even partially reclaimed wrecks (but still not those actively being reclaimed - this requires single target command).
 
|-
 
|}
 
  
{{Navbox manual}}
+
[[Category:Commands|#]]

Latest revision as of 10:53, 16 October 2024

Commands are the orders or directions that players issue to their units throughout a game of Zero-K. Most of the actions and decisions that players make throughout a game are implemented via issuing various types of commands. This page lists and categorizes all the commands with links for details on specific commands.

Command Types[edit]

There are three main types of command: targeted commands, instant commands and state toggles.

  • Targeted commands are issued with a target. Targets can include units and map features (rocks, trees, wrecks) as well as positions, areas and lines drawn that you draw on the map when the command is issued. Targeting lines, areas or multiple units or features is commonly achieved by clicking an dragging.
  • Instant commands activate unit abilities that require no target.
  • State toggles are standing orders that modify behaviour or toggle certain abilities.

Giving Commands[edit]

Instant commands and state toggles can be issued by clicking their button in the command panel or pressing their hotkey. Right clicking a state toggle cycles the toggle backwards or reset it to a deactivated state, depending on the command. Hotkeys to set a state toggle to a particular state can be bound in the hotkeys menu.

Targeted commands can be issued with either the left or right mouse buttons.

  • Click the right mouse button to issue a context sensitive command. The command that will be issued is indicated by the mouse cursor and depends on both your unit selection and the target of the command. Common examples are force fire when the target is an enemy unit and move when the the target is empty ground.
  • Click the left mouse button to issue a command selected. To select a command click on its button in the command panel or press its hotkey. The selected command is indicated by the mouse cursor and a highlighted command button. Issue the command (without holding Shift) or right click to deselect the command.

Targeted commands can be modified in many ways.

  • Click and drag to draw a circle or a line. Most commands support either line or circle drawing and some support both depending on other modifers.
  • Many commands are modified by holding Alt or Ctrl while clicking to issue the command.
  • Some commands change depending on whether they are targeted on a unit or the ground.

Queuing and Inserting Commands[edit]

Units maintain a list of commands, known as their command queue, that are executed in order as each command is completed. Most targeted and instant commands can be added to the end of the queue or inserted or inserted into the queue. State toggles cannot be added to the queue and always take effect instantly.

  • Hold SHIFT while issuing a targeted or instant command to add it to the end of the command queue.
  • Hold SPACE while issuing a targeted command to add it to the start of the command queue, pushing the current command to the second spot in the queue.
  • Hold SHIFT+SPACE while issuing a targeted command to insert it at the point in the command queue that would result in the least extra travel time.

A targeted command that is issued without holding Shift or Space cancels the entire command queue, replacing it with the newly issued command. An instant command that is issued without holding Shift or Space immediately executes the command without affecting the rest of the queue. Nobody knows what happens if an instant command is issued with Space held.

Factory Production Commands[edit]

Factories can make use of unit commands to make produced units take specific actions when leaving the factory. For example, units can be set to move to a point or patrol as soon as they are produced.

Unit commands given to factories can also be queued and modified, as above.

Most Common Commands and Modifiers[edit]

Commands can have their behaviour modified using ALT and CTRL, and can be combined with SHIFT and SPACE to queue commands. Some commands also change their behaviour when targeted on a unit or the ground. See each command's page for details.

Command Click+drag behaviour Drag behaviour +CTRL +ALT +CTRL+ALT
Move (M)
Move.png
Move units to a point. Move units into a line. Move, maintaining current formation. When dragging, move along a line. When dragging, move along a line in formation.
Attack move (A)
Fight.png
Move to a point, using unit AI while moving. Same as move, using AI. Same as move, using AI. Same as move, using AI. Same as move, using AI.
Patrol (P)
Patrol.png
Move back and forth between current position and a point, using unit AI while moving. Same as move, using AI. Same as move, using AI. Same as move, using AI. Same as move, using AI.
Force Fire (F)
Attack.png
Fire at a point Fire at all targets in an area, in a queue. When dragging, fire at all targets in an area, splitting fire. When dragging, fire along a line.
Set Target (T)
Settarget.png
Target a unit or point, without moving. Fire at target if in range. Fire normally if out of range. Target the nearest enemy in the circle. Target all enemies in the circle, splitting targets. Target the ground along a line, firing if in range.
Guard (G)
Guard.png
Protect, repair, and assist a unit. On unit: guard in circle formation.

On ground: guard all units in the circle.

For circle formation: guard in a specific direction. For circle formation: guard in a direction relative to unit facing. For circle formation: do not match guarding unit speeds/positions.
Repair (R)
Repair.png
Repair a live unit; Assist construction. Area command. Applies the click command to valid targets in the area, as long as there are any. Only repair live units, do not assist construction. For area only. Persist the area even when no valid targets inside (continue if any new show up). For area only. Persist the area even when no valid targets inside while only repairing live units.
Area Mex (W)
Mex.png
Build a mex at given spot Queue mexes across the area. Surround each mex in the area with 2 solars. Works on already-built mexes. If a mex is underwater, 2 Tidal Generators are built instead. If on land and flat space is limited, a Wind Generator will be substituted where a Solar does not fit. As with +CTRL, except with only one generator per mex, chosen as appropriate. As with +CTRL, except with four generators per mex, chosen as appropriate, one on each side.
Reclaim (E)
Reclaim.png
Reclaim target (unit or feature). Reclaim features across the area. Area only. If centered on a live unit, reclaim all units of this type in the area. Else, ignore metal-less features, such as trees. There is a menu option to do this by default, in which case trees can be reclaimed either with CTRL or by centering the area on a tree. Area only. Persist the command even when no features are in the area. Area only. Persist the command even when no features are in the area while ignoring(or not, depending on setting) metal-less features
Resurrect (T)
Resurrect.png
Resurrect target wreck Area version. Resurrect wrecks in given area as long as there are any; ignore ones that are partially reclaimed. Area only. Resurrect even partially reclaimed wrecks (but still not those actively being reclaimed - this requires single target command). Area only. Persist the command even when no resurrectables are in the area. Ignores partially reclaimed wrecks. Area only. Persist the command even when no resurrectables are in the area. Resurrects partially reclaimed wrecks.

Full List of Commands[edit]

Common targeted commands[edit]

Common economic commands[edit]

Instant commands[edit]

Transport commands[edit]

Unusual commands[edit]

Global commands[edit]

State commands[edit]