missionStart: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "_{10,} " to "") |
Lou Montana (talk | contribs) m (Text replacement - " *\| *([Cc]omments|COMMENTS|Game|[Gg]ame [Nn]ame|Game [Vv]ersion|Game Version \(number surrounded by NO SPACES\)|Multiplayer Arguments( \("local" or "global"\))?|Effects|Multiplayer Effects( \("local" or "global"\))?|Multiplayer Exe...) |
||
Line 1: | Line 1: | ||
{{Command | {{Command | ||
| ofpr | | ofpr | ||
|1.80 | |1.80 | ||
|gr1= Mission Information | |gr1= Mission Information | ||
| Returns date and time when mission started in format <tt>[year, month, day, hour, minute, second]</tt> in MP, which differs from [[date]] format only by seconds. In SP returns <tt>[0,0,0,0,0,0]</tt>. | | Returns date and time when mission started in format <tt>[year, month, day, hour, minute, second]</tt> in MP, which differs from [[date]] format only by seconds. In SP returns <tt>[0,0,0,0,0,0]</tt>. | ||
<br><br> | <br><br> | ||
{{Informative | Because this command returns the time of the actual start of the mission, it might not be available in ''pre-init'' or ''init'', but is guaranteed to be available in ''post-init'' when [[time]] > 0}} | {{Informative | Because this command returns the time of the actual start of the mission, it might not be available in ''pre-init'' or ''init'', but is guaranteed to be available in ''post-init'' when [[time]] > 0}} | ||
| [[missionStart]] | | [[missionStart]] | ||
|x1= <code>[[setDate]] ([[missionStart]] [[select]] [0,5]);</code> | |x1= <code>[[setDate]] ([[missionStart]] [[select]] [0,5]);</code> | ||
|x2= Set real date: <code>//postInit = 1; | |x2= Set real date: <code>//postInit = 1; | ||
Line 19: | Line 19: | ||
[[waitUntil]] {[[time]] > 0}; | [[waitUntil]] {[[time]] > 0}; | ||
[[setDate]] ([[missionStart]] [[select]] [0,5]); | [[setDate]] ([[missionStart]] [[select]] [0,5]); | ||
};</code> | };</code> | ||
| [[Array]] - real local date and time (similar to [[date]] format but with seconds) | | [[Array]] - real local date and time (similar to [[date]] format but with seconds) | ||
| [[date]], [[time]], [[daytime]], [[serverTime]], [[setDate]], [[systemTime]], [[systemTimeUTC]] | | [[date]], [[time]], [[daytime]], [[serverTime]], [[setDate]], [[systemTime]], [[systemTimeUTC]] | ||
}} | }} | ||
Revision as of 01:04, 18 January 2021
Description
- Description:
- Returns date and time when mission started in format [year, month, day, hour, minute, second] in MP, which differs from date format only by seconds. In SP returns [0,0,0,0,0,0].
- Groups:
- Mission Information
Syntax
- Syntax:
- missionStart
- Return Value:
- Array - real local date and time (similar to date format but with seconds)
Examples
- Example 1:
setDate (missionStart select [0,5]);
- Example 2:
- Set real date:
//postInit = 1; if (isServer) then { waitUntil {time > 0}; setDate (missionStart select [0,5]); };
Additional Information
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note
Notes
Bottom Section
Categories:
- Scripting Commands
- Introduced with Operation Flashpoint: Resistance version 1.80
- Operation Flashpoint: Resistance: New Scripting Commands
- Operation Flashpoint: Resistance: Scripting Commands
- Command Group: Mission Information
- Scripting Commands OFP 1.96
- Scripting Commands OFP 1.99
- ArmA: Armed Assault: Scripting Commands
- Arma 2: Scripting Commands
- Take On Helicopters: Scripting Commands
- Arma 3: Scripting Commands