SC2Mapster Wiki
Register
Advertisement

General[ | ]

Any local actions or functions created by the map maker, but have not given a category, will appear in this section of the editor.

Hint[ | ]

  • If you are working with mods and get a lot of custom actions and functions, consider making some of the custom work "Internal". This will hide these functions when you are working on maps.

Breaks[ | ]

Return[ | ]

  • Action. Returns the specified value. Note: Custom functions require you to set a return value using this action. If a custom function does not return a value 100% of the time, it will not compile. If this action is run in a trigger, it is equivalent to using "Skip Remaining Actions".

Skip Remaining Actions[ | ]

  • Action. Skips the remaining actions in the trigger.

Break[ | ]

  • Action. Terminate a loop or scope early.

Custom Script[ | ]

  • Action. Runs a custom galaxy script. Note: For advanced users who have familiarity with the galaxy scripting language.

Conditional Statements[ | ]

If Then[ | ]

  • Action. Executes an If Then statement. If the specified conditions are met the specified action set will run. If the conditions are not met, nothing will happen.

If Then Else[ | ]

  • Action. Executes an If Then Else statement. If the specified conditions are met, the action set set under Then will run. If the conditions are not met, the action set placed under Else will run.

If Then Else-If[ | ]

  • Action. Excutes an If Then Else statement with multiple cases.

Switch[ | ]

  • Action. Switch statements check a specified condition, and perform a single action set based on the result. For example: If you wanted to apply a behavior to any unit that enters a certain region, but you want to apply a different behavior depending on the type of unit that enters the region, you could set up a Switch statement in your trigger based on the "Unit Type "of the "Triggering Unit". Individual cases could then be added to the switch statement for different Unit Types, each case with its own unique action set. The Default action set would fire if the result from the Switch statement did not match any of the cases.

Switch Case[ | ]

  • Action. Switch Cases are only found inside of a Switch statement. If the Value parameter matches the value returned by the parent Switch statement the action set will be run, otherwise nothing will happen.

Loops[ | ]

For Each Integer[ | ]

  • Action. Executes a For Loop using an integer value. This will run the action set included in the For Loop a number of times determined by the Start, End, and Increment parameters, increasing the integer variable by the Increment parameter each time. For example: If you set up a For Loop to start at 1, end at 10, increment by 1, and made a single "Chat Message" action inside of the For Loop that converted the <Variable> integer parameter into text, it would count from 1 to 10 in the chat message area.

For Each Real[ | ]

  • Action. Executes a for loop using a real value. This will run the action set included in the For Loop a number of times determined by the Start, End, and Increment parameters, increasing the integer variable by the Increment parameter each time. For example: If you set up a For Loop to start at 1, end at 10, increment by 1, and made a single "Chat Message" action inside of the For Loop that converted the <Variable> integer parameter into text, it would count from 1 to 10 in the chat message area.

Picked Integer[ | ]

  • Function. Returns the picked integer. This function is only for use with the "Pick Each Integer" action. It will do nothing when used outside of a pick each integer loop.

Pick Each Integer[ | ]

  • Action. Picks each integer between the Start and End parameters, and performs the specified actions. Uses the "Picked Integer" function to refer to the iterator in the action set.

Repeat[ | ]

  • Action. Repeats an action set a specified number of times.

Repeat Forever[ | ]

  • Action. Repeats an action set forever (or until the loop is broken with a "Break" or "Skip Remaining Actions" action.

While[ | ]

  • Action. Executes a While Loop. If the specified conditions are met, the action set will be run, and the conditions will be checked again. This will continue until the conditions are not met. If the conditions are not met the first time they are checked, nothing will happen and they will not be checked again.

Variables[ | ]

Modify Variable (Integer)[ | ]

  • Action. Directly modify an integer variable through arithmetic.

Modify Variable (Real)[ | ]

  • Action. Directly modify a real variable through arithmetic.

Set Variable[ | ]

  • Action. Sets a variable to the specified value.

Waits[ | ]

Critical Section[ | ]

  • Action. Only one "Critical Section" action set associated with the chosen Lock parameter will ever execute at the same time. Note: The Lock parameter requires a boolean variable. Simply specifying true or false will not work. This is useful for avoiding race conditions when you have parallel processes that can modify the same variables.

Wait[ | ]

  • Action. Pauses a trigger for a specified amount of time. Real time is normal time. Game time can pass faster or slower depending on the game speed. AI time passes at the same rate as game time, but can be paused or unpaused while real time and game time are still running. It is useful to pause the AI time while a player is watching a cinematic, so timed attack waves will wait until the player is finished with the cinematic before resuming their countdowns.

Wait For Condition[ | ]

  • Action. Pauses a trigger until the specified condition is met. Real time is normal time. Game time can pass faster or slower depending on the game speed. AI time passes at the same rate as game time, but can be paused or unpaused while real time and game time are still running. It is useful to pause the AI time while a player is watching a cinematic, so timed attack waves will wait until the player is finished with the cinematic before resuming their countdowns.

Wait For Timer[ | ]

  • Action. Pauses a trigger until the chosen Timer has reached a certain point. This point is set by using the Time parameter, and the WaitType parameter.
Advertisement