Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private ["_action","_id","_player","_sl","_m","_g","_r","_ar","_p","_at","_c"];
- if (!local player) exitwith {};
- _player = _this select 1;
- _id = _this select 2;
- _action = _this select 3;
- _sl =["O_Soldier_SL_F","O_Soldier_F","O_officer_F"];
- _tl =["O_Soldier_SL_F","O_Soldier_TL_F","O_Soldier_F","O_officer_F"];
- _m =["O_Soldier_SL_F","O_medic_F"];
- _g =["O_Soldier_SL_F","O_Soldier_GL_F","O_Soldier_F","O_officer_F"];
- _r =["O_Soldier_SL_F","O_Soldier_F","O_engineer_F","O_officer_F"];
- _ar =["O_Soldier_SL_F","O_Soldier_AR_F","O_Soldier_F","O_officer_F"];
- _p =["O_Soldier_SL_F","O_Helipilot_F","O_Pilot_F"];
- _at =["O_Soldier_SL_F","O_Soldier_AT_F","O_Soldier_F","O_officer_F"];
- _c =["O_Soldier_SL_F","O_crew_F"];
- switch (_action) do
- {
- // ====================================================================================
- // SL
- case 1:
- {
- if ((typeof _player) in _sl)
- then {_id = ["SL", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- // Medic
- case 2:
- {
- if ((typeof _player) in _m)
- then {_id = ["M", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- // Grenadier
- case 3:
- {
- if ((typeof _player) in _g)
- then {_id = ["G", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- // R
- case 4:
- {
- if ((typeof _player) in _r)
- then {_id = ["R", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- // AR
- case 5:
- {
- if ((typeof _player) in _ar)
- then {_id = ["AR", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- // P
- case 6:
- {
- if ((typeof _player) in _p)
- then {_id = ["P", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- // AT
- case 7:
- {
- if ((typeof _player) in _at)
- then {_id = ["AT", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- // C
- case 8:
- {
- if ((typeof _player) in _c)
- then {_id = ["C", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- // FTL
- case 9:
- {
- if ((typeof _player) in _tl)
- then {_id = ["FTL", _player] call compile preprocessFileLineNumbers "cScripts\Loadouts\cStartRED.sqf"; }
- else {hint "You are not authorized for this load out!";}
- };
- // ====================================================================================
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement