Script Commands: Difference between revisions
(Created page with "Commands are used within triggers to create gameplay effects, from revealing locations to spawning attack waves or even changing an AI's difficulty mid-game. ==List of Co...") |
JYWLuca8269 (talk | contribs) m (Updated look.) |
||
(10 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{DISPLAYTITLE:<span style="position: absolute; clip: rect(1px 1px 1px 1px); clip: rect(1px, 1px, 1px, 1px);">{{FULLPAGENAME}}</span>}} | |||
= | {{HeaderTemplate | ||
|welcome=Script Commands | |||
}} | |||
===[[ActivateTrigger|ActivateTrigger]] | '''Commands''' are used within [[Triggers|triggers]] to create gameplay effects, from revealing locations to spawning attack waves or even changing an AI's difficulty mid-game. | ||
{{SectionTemplate | |||
|h=h3 | |||
|title=List of Commands | |||
|content=}} | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=ActivateTrigger | |||
|content=}} | |||
[[ActivateTrigger|ActivateTrigger]] activates another trigger (also can be used to activate the trigger it is called from, making a repeating trigger). | |||
*'''Target''' - This is the name of another trigger that will be set from Inactive to Active. | *'''Target''' - This is the name of another trigger that will be set from Inactive to Active. | ||
===[[AreaIndicator|AreaIndicator]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=AreaIndicator | |||
|content=}} | |||
[[AreaIndicator|AreaIndicator]] places a visible indicator on the map to help the player know where they should go to. | |||
*'''Name''' - The name of the area. | *'''Name''' - The name of the area. | ||
Line 17: | Line 32: | ||
*'''Duration''' - How long the area indicator should last, -1 means that it lasts forever. | *'''Duration''' - How long the area indicator should last, -1 means that it lasts forever. | ||
===[[AttackAttackMove|AttackAttackMove]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=AttackAttackMove | |||
|content=}} | |||
[[AttackAttackMove|AttackAttackMove]] orders an army to move to a specific area, engaging enemies along the way. | |||
*'''Name''' - The name of the army that will be given the order. | *'''Name''' - The name of the army that will be given the order. | ||
Line 24: | Line 43: | ||
*'''Position''' - Where the army is ordered to move to. | *'''Position''' - Where the army is ordered to move to. | ||
===[[AttackUnit|AttackUnit]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=AttackUnit | |||
|content=}} | |||
[[AttackUnit|AttackUnit]] orders an army to attack a specific script-spawned unit. | |||
*'''Name''' - The name of the unit to do the attacking | *'''Name''' - The name of the unit to do the attacking | ||
*'''Target''' - The name of the unit to be attacked | *'''Target''' - The name of the unit to be attacked | ||
===[[Camera|Camera]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=Camera | |||
|content=}} | |||
[[Camera|Camera]] moves the player's view to a specific area. | |||
*'''Position''' - Where the camera will be looking. | *'''Position''' - Where the camera will be looking. | ||
Line 46: | Line 73: | ||
===[[ | {{SectionTemplate | ||
|h=h4 | |||
|title=CaptureNearest | |||
|content=}} | |||
[[CaptureNearest|CaptureNearest]] orders an army to clear its order queue and capture the nearest neutral or enemy-controlled region (note: ordered unit will stop moving if region is captured before it gets there). | |||
*'''Name''' - The name of the unit to do the capturing | *'''Name''' - The name of the unit to do the capturing | ||
*'''Repeat''' - Whether to repeat the order (indefinitely) | *'''Repeat''' - Whether to repeat the order (indefinitely) | ||
===[[ | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=CaptureNearestNext | |||
|content=}} | |||
[[CaptureNearestNext|CaptureNearestNext]] orders an army to capture the nearest neutral or enemy-controlled region. | |||
*'''Name''' - The name of the unit to do the capturing | *'''Name''' - The name of the unit to do the capturing | ||
*'''Repeat''' - Whether to repeat the order (indefinitely) | *'''Repeat''' - Whether to repeat the order (indefinitely) | ||
===[[ChangeAIDifficulty|ChangeAIDifficulty]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=ChangeAIDifficulty | |||
|content=}} | |||
[[ChangeAIDifficulty|ChangeAIDifficulty]] changes an AI player's difficulty setting. | |||
*'''Player''' - The index of the player to change | *'''Player''' - The index of the player to change | ||
*'''Difficulty''' - The name of the difficulty to set it to | *'''Difficulty''' - The name of the difficulty to set it to | ||
===[[ChangeAIPersonality|ChangeAIPersonality]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=ChangeAIPersonality | |||
|content=}} | |||
[[ChangeAIPersonality|ChangeAIPersonality]] changes an AI player's personality. | |||
*'''Player''' - The index of the player to change | *'''Player''' - The index of the player to change | ||
*'''Name''' - The name of the personality to set it to (defined in \Assets\GameCore\DefaultPlayerAI.xml) | *'''Name''' - The name of the personality to set it to (defined in \Assets\GameCore\DefaultPlayerAI.xml) | ||
===[[DestroyBuilding|DestroyBuilding]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=DestroyBuilding | |||
|content=}} | |||
[[DestroyBuilding|DestroyBuilding]] destroys a specific script-spawned building. | |||
*'''Name''' - The name of the building to be destroyed. | *'''Name''' - The name of the building to be destroyed. | ||
===[[DestroyUnit|DestroyUnit]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=DestroyUnit | |||
|content=}} | |||
[[DestroyUnit|DestroyUnit]] destroys a specific script-spawned unit. | |||
*'''Name''' - The name of the unit to be destroyed. | *'''Name''' - The name of the unit to be destroyed. | ||
===[[ | {{SectionTemplate | ||
|h=h4 | |||
|title=Dialog | |||
|content=}} | |||
[[Dialog|Dialog]] creates a popup that can convey information or story to the player. Use with <Entry> tags. | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=Entry | |||
|content=}} | |||
[[Entry|Entry]] is the actual text that will be displayed. Use only within <Dialog> tags. | |||
*'''Text''' - The actual text that is displayed. Corresponds to an entry in a .csv file in \Assets\UIText\ | |||
*'''Icon''' - The icon used with the text popup. Hard-coded to correspond to Ashes characters, and changes the text color to match. | *'''Icon''' - The icon used with the text popup. Hard-coded to correspond to Ashes characters, and changes the text color to match. | ||
**Mac | **Mac | ||
Line 94: | Line 153: | ||
**Ventrix | **Ventrix | ||
**Athena | **Athena | ||
** | **Narrator | ||
**Agememnon | **Agememnon | ||
**Agethon | **Agethon | ||
{{SectionTemplate | |||
|h=h4 | |||
== | |title=EndMission | ||
|content=}} | |||
[[EndMission|EndMission]] used to force a win or loss of the scenario. | |||
*'''Victory''' - Set to 0 to lose the scenario or 1 to win. | *'''Victory''' - Set to 0 to lose the scenario or 1 to win. | ||
*'''String''' - The text that is displayed. | *'''String''' - The text that is displayed. | ||
===[[GrantStuff|GrantStuff]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=GrantStuff | |||
|content=}} | |||
[[GrantStuff|GrantStuff]] gives a player free resources. | |||
*'''Player''' - The index of the player to be hooked up | *'''Player''' - The index of the player to be hooked up | ||
Line 116: | Line 180: | ||
*'''Turinium''' - The amount of victory points being granted. | *'''Turinium''' - The amount of victory points being granted. | ||
===[[GrantTech|GrantTech]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=GrantTech | |||
|content=}} | |||
[[GrantTech|GrantTech]] gives a player a free Quantum Upgrade | |||
*'''Player''' - The index of the player to be hooked up | *'''Player''' - The index of the player to be hooked up | ||
*'''Tech''' - The upgrade to grant [ HPs | Weapons | Radar | BuildingHPs | MetalStorage | RadsStorage ] | *'''Tech''' - The upgrade to grant [ HPs | Weapons | Radar | BuildingHPs | MetalStorage | RadsStorage | NexusHPs ] | ||
===[[HidePanel|HidePanel]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=HidePanel | |||
|content=}} | |||
[[HidePanel|HidePanel]] hides UI panels. | |||
*'''HidePlayer''' - Hide the Player panel | *'''HidePlayer''' - Hide the Player panel | ||
Line 129: | Line 201: | ||
*'''HideResource''' - Hide the Resource panel | *'''HideResource''' - Hide the Resource panel | ||
===[[LetterBox|LetterBox]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=LetterBox | |||
|content=}} | |||
[[LetterBox|LetterBox]] disables commands and go to a cinematic, letterbox view. | |||
*'''Enable''' - 1 to turn letterbox mode on, 0 to turn it off | *'''Enable''' - 1 to turn letterbox mode on, 0 to turn it off | ||
*'''Snap''' - 1 to immediately go to/from letterbox mode instead of fading in/out | *'''Snap''' - 1 to immediately go to/from letterbox mode instead of fading in/out | ||
===[[MoveUnit|MoveUnit]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=MoveUnit | |||
|content=}} | |||
[[MoveUnit|MoveUnit]] moves an army to a location without stopping to fight | |||
*'''Name''' - Name of the unit to be moved | *'''Name''' - Name of the unit to be moved | ||
Line 143: | Line 223: | ||
*'''Stop''' - 1 to stop the unit | *'''Stop''' - 1 to stop the unit | ||
===[[Objective|Objective]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=Objective | |||
|content=}} | |||
[[Objective|Objective]] is used to set objective notifications for the player (so they know what to do). | |||
*'''Name''' - The name of the objective, use this name when checking or hiding it. | *'''Name''' - The name of the objective, use this name when checking or hiding it. | ||
Line 151: | Line 235: | ||
*'''SetCheck''' - If the objective checkbox is checked or not. | *'''SetCheck''' - If the objective checkbox is checked or not. | ||
===[[Restrict|Restrict]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=Restrict | |||
|content=}} | |||
[[Restrict|Restrict]] blocks the player from being able to access objects in the game. | |||
*'''Type''' - Unit, Building, Research or Orbital. Whatever type of object that is being restricted. | *'''Type''' - Unit, Building, Research or Orbital. Whatever type of object that is being restricted. | ||
Line 158: | Line 246: | ||
*'''Enable''' - Set this to 1 to enable the object. You can use this to restrict something early in the scenario and then enable it later on (for example: when the player accomplishes an objective or after a set amount of time). | *'''Enable''' - Set this to 1 to enable the object. You can use this to restrict something early in the scenario and then enable it later on (for example: when the player accomplishes an objective or after a set amount of time). | ||
===[[Reveal|Reveal]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=Reveal | |||
|content=}} | |||
[[Reveal|Reveal]] reveals the fog of war over a location | |||
*'''Name''' - The name of this reveal (so you can modify it with a later command) | *'''Name''' - The name of this reveal (so you can modify it with a later command) | ||
Line 167: | Line 259: | ||
*'''RadarSize''' - Use to add a radar component to the reveal. Can be used with Size="0" to create a radar-only reveal | *'''RadarSize''' - Use to add a radar component to the reveal. Can be used with Size="0" to create a radar-only reveal | ||
===[[SpawnBuilding|SpawnBuilding]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=SpawnBuilding | |||
|content=}} | |||
[[SpawnBuilding|SpawnBuilding]] places a building on the map. | |||
*'''Name''' - The name you assign to the building. | *'''Name''' - The name you assign to the building. | ||
Line 176: | Line 272: | ||
*'''NoDeath''' - Set this to "1" to make the unit immortal (you can still kill it with a scripted DestroyBuilding command) | *'''NoDeath''' - Set this to "1" to make the unit immortal (you can still kill it with a scripted DestroyBuilding command) | ||
===[[SpawnUnit|SpawnUnit]] | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=SpawnUnit | |||
|content=}} | |||
[[SpawnUnit|SpawnUnit]] places a unit on the map. | |||
*'''Name''' - The name you assign to the unit. | *'''Name''' - The name you assign to the unit. | ||
Line 185: | Line 285: | ||
*'''Position''' - Where the unit will be created. | *'''Position''' - Where the unit will be created. | ||
===[[ | |||
{{SectionTemplate | |||
|h=h4 | |||
|title=Var | |||
|content=}} | |||
[[Var_Command|Var]] sets or modifies a variable. Tip: Set any variable you want to use to 0 in the initial setup trigger to avoid unpredictable results. ''All values must be integers.'' | |||
*'''Name''' - Name of the variable | *'''Name''' - Name of the variable | ||
*'''Value''' - The value to be used in the operation | |||
*'''Min''' - Minimum value for random functions | |||
*'''Max''' - Maximum value for random functions | |||
*'''Operation''' - Operation to be performed | *'''Operation''' - Operation to be performed | ||
**"=" or "Set" - set to the value | **"=" or "Set" - set to the value | ||
Line 197: | Line 304: | ||
**"SubRand" - subtract a random value between Min and Max | **"SubRand" - subtract a random value between Min and Max | ||
[[Category:Modding]] [[Category:Commands]] | |||
Latest revision as of 20:49, 6 December 2020
List of CommandsActivateTriggerActivateTrigger activates another trigger (also can be used to activate the trigger it is called from, making a repeating trigger).
AreaIndicatorAreaIndicator places a visible indicator on the map to help the player know where they should go to.
AttackAttackMoveAttackAttackMove orders an army to move to a specific area, engaging enemies along the way.
AttackUnitAttackUnit orders an army to attack a specific script-spawned unit.
CameraCamera moves the player's view to a specific area.
CaptureNearestCaptureNearest orders an army to clear its order queue and capture the nearest neutral or enemy-controlled region (note: ordered unit will stop moving if region is captured before it gets there).
CaptureNearestNextCaptureNearestNext orders an army to capture the nearest neutral or enemy-controlled region.
ChangeAIDifficultyChangeAIDifficulty changes an AI player's difficulty setting.
ChangeAIPersonalityChangeAIPersonality changes an AI player's personality.
DestroyBuildingDestroyBuilding destroys a specific script-spawned building.
DestroyUnitDestroyUnit destroys a specific script-spawned unit.
DialogDialog creates a popup that can convey information or story to the player. Use with <Entry> tags.
EntryEntry is the actual text that will be displayed. Use only within <Dialog> tags.
EndMissionEndMission used to force a win or loss of the scenario.
GrantStuffGrantStuff gives a player free resources.
GrantTechGrantTech gives a player a free Quantum Upgrade
HidePanelHidePanel hides UI panels.
LetterBoxLetterBox disables commands and go to a cinematic, letterbox view.
MoveUnitMoveUnit moves an army to a location without stopping to fight
ObjectiveObjective is used to set objective notifications for the player (so they know what to do).
RestrictRestrict blocks the player from being able to access objects in the game.
RevealReveal reveals the fog of war over a location
SpawnBuildingSpawnBuilding places a building on the map.
SpawnUnitSpawnUnit places a unit on the map.
VarVar sets or modifies a variable. Tip: Set any variable you want to use to 0 in the initial setup trigger to avoid unpredictable results. All values must be integers.
|