Difference between revisions of "Init (Kosher Arsenal)"

From cluster wiki
Jump to navigation Jump to search
 
(9 intermediate revisions by the same user not shown)
Line 1: Line 1:
<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block; border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Description</div>
<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block; border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Description</div>
<dl style="width:100%;">
<dl style="width:100%;">
<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">Description:</dt>
 
<!-- DESCRIPTION -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">Description:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
This function initializes kosherArsenal itself, it must be run locally (eg. from initPlayerLocal.sqf), it is blocking meaning it won't execute any code placed after the function call until the initial spawn arsenal has been exited.
This function initializes kosherArsenal itself, it must be run locally (eg. from initPlayerLocal.sqf), it is blocking meaning it won't execute any code placed after the function call until the initial spawn arsenal has been exited.
</div></dd>
</div></dd>


<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">Execution:</dt>
<!-- EXECUTION -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">Execution:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
call
call
</div></dd>
</div></dd>


<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">GroupsGroups:</dt>
<!-- GROUPS -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">Groups:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
Utility Functions: Eric's Mission Framework
Kosher Arsenal: Eric's Mission Framework
</div></dd>
</div></dd>
</dl>  
</dl>  


<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block;border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Syntax</div>
<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block;border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Syntax</div>
<dl style="width:100%;">
<dl style="width:100%;">
<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">Syntax:</dt>
 
<!-- SYNTAX -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">Syntax:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
[Light, ForcePrimary] call '''EMF_fnc_kosherArsenal'''
[loadouts, light, forcePrimary, randomPos] call '''emf_kosherArsenal_fnc_init'''
</div></dd>
 
<!-- PARAMETERS -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">Parameters:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
loadouts: Array of Strings - Array of loadout files from rsc\loadouts (with .sqf omitted)
</div></dd>
</div></dd>


<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">Parameters:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
Light: Boolean - (Optional) When true creates a light source at the arsenal to help with visibility. [Default: false]
Light: Boolean - (Optional) When true creates a light source at the arsenal to help with visibility. [Default: false]
</div></dd>
</div></dd>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
ForcePrimary: Boolean - (Optional) When true will not allow player to exit arsenal unless a primary firearm has been equipped. [Default: true]
ForcePrimary: Boolean - (Optional) When true will not allow player to exit arsenal unless a primary firearm has been equiped. [Default: true]
</div></dd>
</div></dd>


<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">Return Value:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
Boolean - Returns true on success.
RandomPos: Boolean - (Optional) When true randomizes players spawn position in a 5 meter radius. [Default: true]
</div></dd>
 
<!-- RETURN VALUE -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">Return Value:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><div style="display:block;">
None
</div></dd>
</div></dd>
</dl>  
</dl>  
Line 40: Line 58:
<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block; border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Examples</div>
<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block; border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Examples</div>
<dl style="width:100%;">
<dl style="width:100%;">
<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">Example 1:</dt>
 
<!-- EXAMPLE -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">Example 1:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><code style="border:#25A1A1 dashed 1px;display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><code style="border:#25A1A1 dashed 1px;display:block;">
// Initializes Kosher Arsenal with light off and forced primary<br>
[["myLoadout"], false, true] call '''emf_kosherArsenal_fnc_init''';
[false, true] call EMF_fnc_kosherArsenal;
</code></dd>
</code></dd>


<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">Example 2:</dt>
<!-- EXAMPLE -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">Example 2:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><code style="border:#25A1A1 dashed 1px;display:block;">
<dd style="width:90%;padding:.3em .3em .3em 7em;"><code style="border:#25A1A1 dashed 1px;display:block;">
// Initializes Kosher Arsenal with light on<br>
[["myLoadout1", "myLoadout2"], true] call '''emf_kosherArsenal_fnc_init''';
[true] call '''EMF_fnc_kosherArsenal''';
</code></dd>
</code></dd>


<dt style="min-width:100%;clear:both;font-weight:bold;position:absolute;padding:.3em;">Example 3:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;"><code style="border:#25A1A1 dashed 1px;display:block;">
// Loads a loadout and initializes with light off<br>
<nowiki>[["GERMANY_MID90_ARMY_WDL"]]</nowiki> call '''EMF_fnc_kosherArsenalLoad''';<br>
[false] call '''EMF_fnc_kosherArsenal''';
</code></dd>
</dl>  
</dl>  
<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block;border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Additional Information</div>
<!-- ADDITIONAL INFORMATION -->
<dl style="width:100%;">
<!-- SEE ALSO -->
<dt style="clear:both;font-weight:bold;position:absolute;padding:.3em;">See also:</dt>
<dd style="width:90%;padding:.3em .3em .3em 7em;column-count:4;">
<div style="display: block;">[[AiArsenal]]</div>
<div style="display: block;">[[AiInit]]</div>
<div style="display: block;">[[AmmoBox]]</div>
<div style="display: block;">[[ForceArsenal]]</div>
<div style="display: block;">[[ForceClose]]</div>
</dd>
</dl>


<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block;border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Notes</div>
<div style="padding:0.33em 2em;font-size:1.2em;font-weight:bold;display:block;border-bottom: #25A1A1 solid 1px; background-color:#E0FFFF;color:#25A1A1">Notes</div>
<!-- NOTES -->
<dl style="width:100%;"></dl>
<!-- CATEGORIES -->
[[Category:Kosher Arsenal: Eric's Mission Framework]]
[[Category:Kosher Arsenal: Eric's Mission Framework]]
[[Category:Functions: Eric's Mission Framework]]

Latest revision as of 14:08, 26 March 2022

Description
Description:

This function initializes kosherArsenal itself, it must be run locally (eg. from initPlayerLocal.sqf), it is blocking meaning it won't execute any code placed after the function call until the initial spawn arsenal has been exited.

Execution:

call

Groups:

Kosher Arsenal: Eric's Mission Framework

Syntax
Syntax:

[loadouts, light, forcePrimary, randomPos] call emf_kosherArsenal_fnc_init

Parameters:

loadouts: Array of Strings - Array of loadout files from rsc\loadouts (with .sqf omitted)

Light: Boolean - (Optional) When true creates a light source at the arsenal to help with visibility. [Default: false]

ForcePrimary: Boolean - (Optional) When true will not allow player to exit arsenal unless a primary firearm has been equiped. [Default: true]

RandomPos: Boolean - (Optional) When true randomizes players spawn position in a 5 meter radius. [Default: true]

Return Value:

None

Examples
Example 1:
[["myLoadout"], false, true] call emf_kosherArsenal_fnc_init;
Example 2:
[["myLoadout1", "myLoadout2"], true] call emf_kosherArsenal_fnc_init;
Additional Information
See also:


Notes