SC2Mapster.com
Maps
Assets
Teams
Authors
Forums
Wiki
Paste
Sign in
Register new account
SC2Mapster.com Wiki
SC2 API
/
Functions
/
TriggerAddEventMapInit
r2
Source
Markup:
<<apifunction>> <<name>>TriggerAddEventMapInit<</name>> <<description>> <<code>>void TriggerAddEventMapInit (trigger t);<</code>> Register a trigger that will be executed on map initialization. <</description>> <<param trigger t>>The trigger that will be executed. Must have the following prototype: <<code>>bool name(bool checkConds, bool doActions);<</code>> * **checkConds** : always true? * **doActions** : always true? * The return value is used to increment either FailedConditions (when false) or Run in the debug trigger window<</param>> <<example Run script every X seconds>> // Define the trigger function bool TriggerTiming (bool checkConds, bool doActions) { while (1) { // Do something every 5 seconds Wait(5, 0); } } void InitMap () { // Create a new trigger based off the function trigger t = TriggerCreate("TriggerTiming"); // Run it at map initialization TriggerAddEventMapInit (t); } <</example>> <<seealso>>Wait<</seealso>> <<seealso>>TriggerCreate<</seealso>> <</apifunction>>
Markup Type:
The type of markup for this entry.
Click here for details
.
BBCode
Markdown
Plain Text
WikiCreole