diff --git a/Sources/epoch_code/compile/servicepoint/EPOCH_SP_Rearm.sqf b/Sources/epoch_code/compile/servicepoint/EPOCH_SP_Rearm.sqf index e3bd5e2c..91ccff47 100644 --- a/Sources/epoch_code/compile/servicepoint/EPOCH_SP_Rearm.sqf +++ b/Sources/epoch_code/compile/servicepoint/EPOCH_SP_Rearm.sqf @@ -1,20 +1,31 @@ -params ['_vehicle','_ammotype','_turret','_reloagmags','_ammocount','_costs']; -private ['_magname']; -_vehtype = typeof _vehicle; -_VehName = getText(configFile >> 'cfgVehicles' >> _vehtype >> 'displayName'); -if (!local _vehicle) exitWith { - _line = 'Rearm denied - Vehicle is not local to you!'; - [_line,5] call Epoch_message; -}; -if(count (crew _vehicle) > 1) exitWith { - _line = 'Rearm denied - All Passengers must exit the Vehicle!'; - [_line,5] call Epoch_message; -}; -if (EPOCH_playerCrypto < _costs) exitWith { - _line = format ['You need %1 Crypto to re-arm %2', _costs,_VehName]; - [_line,5] call Epoch_message; -}; +/* + Author: [Ignatz] He-Man + Contributors: Aaron Clark - EpochMod.com + + Description: + Rearm Vehicles for A3 Epoch + + Licence: + Arma Public License Share Alike (APL-SA) - https://www.bistudio.com/community/licenses/arma-public-license-share-alike + + Github: + https://github.com/EpochModTeam/Epoch/tree/release/Sources/epoch_code/servicepoint/EPOCH_SP_Rearm.sqf +*/ + +private ['_magname','_vehtype','_vehName']; +params ['_vehicle','_ammotype','_turret','_reloagmags','_ammocount','_costs']; + +if (!local _vehicle) exitWith { + _line = 'Rearm denied - Go in as driver first!'; + [_line,5] call Epoch_message; +}; +_vehtype = typeof _vehicle; +_vehName = getText(configFile >> 'cfgVehicles' >> _vehtype >> 'displayName'); +if (EPOCH_playerCrypto < _costs) exitWith { + _line = format ['You need %1 Crypto to Rearm %2', _costs,_vehName]; + [_line,5] call Epoch_message; +}; if(_costs > 0)then{ [player,(_costs*-1),Epoch_personalToken] remoteexec ['epoch_server_paycrypto',2]; }; @@ -26,5 +37,5 @@ _magname = getText (configFile >> 'CfgMagazines' >> _ammotype >> 'displayName'); if (_magname isequalto '') then { _magname = _ammotype; }; -_line = format ['%1 rearmed with %2', _VehName, _magname]; +_line = format ['%1 rearmed with %2', _vehName, _magname]; [_line,5] call Epoch_message;