feat: Refactor and document client-side functions
All checks were successful
Build / Build (push) Successful in 27s
All checks were successful
Build / Build (push) Successful in 27s
This commit refactors and adds documentation to several client-side functions across various addons, including: - **Task Addon:** Added function headers and descriptions to task-related functions (fnc_destroy, fnc_attack, fnc_defuse, fnc_hostage, fnc_makeIED, fnc_hvt, fnc_heartBeat, fnc_makeTarget, fnc_makeHVT, fnc_makeHostage, fnc_makeObject, fnc_makeShooter, fnc_attackModule, fnc_destroyModule, fnc_hvtModule, fnc_hostageModule, fnc_defuseModule, fnc_protectedModule, fnc_hostagesModule, fnc_explosivesModule, fnc_shootersModule). - **Org Addon:** Updated author and added function headers/descriptions to organization-related functions (fnc_initOrgStore, fnc_requestServerDB, fnc_addAsset, fnc_addReputation, fnc_create, fnc_removeAsset, fnc_addFunds, fnc_leave, fnc_addMember, fnc_disband, fnc_verifyOrgStore, fnc_handleOrgLoad). - **Garage Addon:** Added function headers and descriptions to garage-related functions (fnc_openGarage, fnc_fetchNearby, fnc_initGarage, fnc_fetchGarage, fnc_storeVehicle). - **Locker Addon:** Added function headers and descriptions to locker-related functions (fnc_openLocker, fnc_fetchPlayer, fnc_initLocker, fnc_fetchLocker). - **Phone Addon:** Added function headers, descriptions, and examples to phone-related functions (fnc_initAction, fnc_showEmail, fnc_showMessage, fnc_delEmail, fnc_delMsg, fnc_showMessageInput, fnc_addContact, fnc_initPhone, fnc_addMsg, fnc_addEmail, fnc_newEmail, fnc_initVar, fnc_addOfflineEmail, fnc_addOfflineMsg, fnc_sendMsg, fnc_sendEmail, fnc_showContact, fnc_newMsg, fnc_dateToHhMm, fnc_initAddAction, fnc_openPhone, fnc_viewSettings, fnc_viewMessages, fnc_viewContacts, fnc_viewEmail, fnc_showDialpad, fnc_showSafari). - **Admin Addon:** Added function headers and descriptions to admin-related functions (fnc_adminMessage, fnc_printAddonName, fnc_initAdmin, fnc_openAdmin, fnc_adminPromote). - **Store Addon:** Added function headers and descriptions to store-related functions (fnc_openStore, fnc_initStore, fnc_selectProduct, fnc_changeFilter, fnc_changePayment, fnc_handlePurchase). - **Medical Addon:** Added function headers, descriptions, and examples to medical-related functions (fnc_saveDroppedWeapons, fnc_moveInventory, fnc_onRespawn, fnc_onKilled, fnc_initMedical, fnc_deductMedicalCost, fnc_heartBeat). - **Misc Addon:** Added function headers, descriptions, and examples to misc-related functions (fnc_formatNumber, fnc_isAssignableBinocular, fnc_isWeaponType, fnc_cargoToPairs, fnc_serializeString, fnc_deserializeString, fnc_getSystemTime). - **Init Addon:** Updated author and removed unnecessary copyright information from init-related functions (fnc_initPlayer, fnc_playerDBSave, fnc_playerSaveLoop, fnc_playerDBLoad, fnc_handlePlayerLoad). - **Money Addon:** Removed unnecessary copyright information from money-related functions (fnc_takeCash, fnc_giveCash, fnc_giveCashSubmit). - **Interaction Addon:** Removed unnecessary copyright information from interaction-related functions (fnc_initInteraction, fnc_openInteraction, fnc_interactionAction). - **Ambient Addon:** Removed unnecessary copyright information from ambient-related functions (fnc_ambientSound). - **Arsenal Addon:** Added function headers, descriptions, and examples to arsenal-related functions (fnc_openArmory, fnc_saveUnlocks, fnc_updateUnlocks, fnc_openGarage, fnc_addGarageVehicle, fnc_addVirtualVehicles, fnc_addVirtualVehicles). - **Dialogue Addon:** Added function headers and descriptions to dialogue-related functions (fnc_selectAI, fnc_selectDialogue). - **Service Addon:** Added function headers and descriptions to service-related functions (fnc_initService). - **Bank Addon:** Added function headers and descriptions to bank-related functions (fnc_initBank, fnc_refresh, fnc_openBank). These changes improve code readability, maintainability, and provide better context for developers working with these functions. The author field was updated to `IDSolutions` where appropriate.
This commit is contained in:
parent
2c79c3d442
commit
44625a8677
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_admin_fnc_adminMessage
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Admin Message Menu
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private ["_data", "_dialog", "_list", "_target", "_targetValue", "_textBox", "_textMessage"];
|
||||
|
||||
_dialog = findDisplay 202303;
|
||||
|
@ -1,6 +1,26 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_admin_fnc_adminPromote
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Admin Promote Menu
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_condition", "", [""]]];
|
||||
|
||||
private ["_data", "_data2", "_dialog", "_list", "_list2", "_paygrade", "_rankValue", "_target", "_targetValue"];
|
||||
|
||||
_dialog = findDisplay 202303;
|
||||
@ -21,10 +41,10 @@ if ((isNil {_data})) exitWith { hintSilent "You did not select a player!" };
|
||||
|
||||
switch (_condition) do {
|
||||
case ("promote"): {
|
||||
SETPVAR(_target,PayGrade,_paygrade)
|
||||
SETPVAR(_target,FORGE_PayGrade,_paygrade)
|
||||
};
|
||||
case ("demote"): {
|
||||
SETPVAR(_target,PayGrade,_paygrade)
|
||||
SETPVAR(_target,FORGE_PayGrade,_paygrade)
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -1,18 +1,44 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_admin_fnc_adminRefresh
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Admin Refresh Menu
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_condition", "", [""]], ["_amount", 0, [0]]];
|
||||
|
||||
private _store = missionNamespace getVariable ["FORGE_ORG_STORE_REG", createHashMap];
|
||||
private _org = _store call ["getOrg", []];
|
||||
|
||||
if (isNil "_org") exitWith { ["You are not in an organization!", "warning", 3] call EFUNC(misc,notify) };
|
||||
|
||||
private _orgFunds = _org get "funds";
|
||||
|
||||
private _newFunds = 0;
|
||||
private _dialog = findDisplay 202303;
|
||||
private _list = _dialog displayCtrl 2023001;
|
||||
|
||||
switch (_condition) do {
|
||||
case ("deduct"): {
|
||||
_newFunds = companyFunds - _amount;
|
||||
_newFunds = _orgFunds - _amount;
|
||||
ctrlSetText [2023002, format ["$%1", (_newFunds call EFUNC(misc,formatNumber))]];
|
||||
};
|
||||
case ("advance"): {
|
||||
_newFunds = companyFunds + _amount;
|
||||
_newFunds = _orgFunds + _amount;
|
||||
ctrlSetText [2023002, format ["$%1", (_newFunds call EFUNC(misc,formatNumber))]];
|
||||
};
|
||||
default {
|
||||
@ -22,7 +48,7 @@ switch (_condition) do {
|
||||
if (str (side _x) == str (playerSide)) then {
|
||||
private _name = name (_x);
|
||||
private _defaultPaygrade = "E1";
|
||||
private _paygrade = GETVAR(_x,PayGrade,_defaultPaygrade);
|
||||
private _paygrade = GETVAR(_x,FORGE_PayGrade,_defaultPaygrade);
|
||||
private _index = _list lbAdd format["%1 - %2", _name, _paygrade];
|
||||
|
||||
_list lbSetData [_index, name (_x)];
|
||||
@ -41,7 +67,7 @@ lbClear _list;
|
||||
if (str (side _x) == str (playerSide)) then {
|
||||
private _name = name (_x);
|
||||
private _defaultPaygrade = "E1";
|
||||
private _paygrade = GETVAR(_x,PayGrade,_defaultPaygrade);
|
||||
private _paygrade = GETVAR(_x,FORGE_PayGrade,_defaultPaygrade);
|
||||
private _index = _list lbAdd format["%1 - %2", _name, _paygrade];
|
||||
|
||||
_list lbSetData [_index, name (_x)];
|
||||
|
@ -1,7 +1,33 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_admin_fnc_adminTransfer
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Admin Transfer Menu
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_condition", "", [""]]];
|
||||
|
||||
private _store = missionNamespace getVariable ["FORGE_ORG_STORE_REG", createHashMap];
|
||||
private _org = _store call ["getOrg", []];
|
||||
|
||||
if (isNil "_org") exitWith { ["You are not in an organization!", "warning", 3] call EFUNC(misc,notify) };
|
||||
|
||||
private _orgFunds = _org get "funds";
|
||||
|
||||
private _dialog = findDisplay 202303;
|
||||
private _list = _dialog displayCtrl 2023001;
|
||||
private _targetValue = lbCurSel _list;
|
||||
@ -21,27 +47,27 @@ switch (_condition) do {
|
||||
private _bank = GETVAR(_target,FORGE_Bank,0);
|
||||
private _newBalance = _bank + _amount;
|
||||
|
||||
if (_amount > companyFunds) exitWith { ["Not enough money in the company's account!", "warning", 3] call EFUNC(misc,notify) };
|
||||
if (_amount > _orgFunds) exitWith { ["Not enough money in the organization's account!", "warning", 3] call EFUNC(misc,notify) };
|
||||
|
||||
SETPVAR(_target,FORGE_Bank,_newBalance);
|
||||
|
||||
["deduct", _amount] call FUNC(adminRefresh);
|
||||
["deduct", _amount] remoteExecCall ["forge_server_money_fnc_handleFunds", 2];
|
||||
_store call ["updateFunds", -_amount];
|
||||
};
|
||||
case ("advanceAll"): {
|
||||
private _count = count playableUnits;
|
||||
|
||||
if ((10000 * _count) > companyFunds) exitWith { ["Not enough money in the company's account!", "warning", 3] call EFUNC(misc,notify) };
|
||||
if ((10000 * _count) > _orgFunds) exitWith { ["Not enough money in the organization's account!", "warning", 3] call EFUNC(misc,notify) };
|
||||
|
||||
{
|
||||
private _bank = GETVAR(_x,Cash_Bank,0);
|
||||
private _bank = GETVAR(_x,FORGE_Bank,0);
|
||||
private _newBalance = _bank + 10000;
|
||||
|
||||
SETPVAR(_x,Cash_Bank,_newBalance);
|
||||
SETPVAR(_x,FORGE_Bank,_newBalance);
|
||||
} count playableUnits;
|
||||
|
||||
["deduct", (10000 * _count)] call FUNC(adminRefresh);
|
||||
["deduct", (10000 * _count)] remoteExecCall ["forge_server_money_fnc_handleFunds", 2];
|
||||
_store call ["updateFunds", -(10000 * _count)];
|
||||
};
|
||||
case ("deduct"): {
|
||||
private _bank = GETVAR(_target,FORGE_Bank,0);
|
||||
@ -52,7 +78,7 @@ switch (_condition) do {
|
||||
SETPVAR(_target,FORGE_Bank,_newBalance);
|
||||
|
||||
["advance", _amount] call FUNC(adminRefresh);
|
||||
["advance", _amount] remoteExecCall ["forge_server_money_fnc_handleFunds", 2];
|
||||
_store call ["updateFunds", _amount];
|
||||
};
|
||||
case ("payday"): {
|
||||
private _totalPayment = 0;
|
||||
@ -61,7 +87,7 @@ switch (_condition) do {
|
||||
|
||||
{
|
||||
private _player = _x;
|
||||
private _payGrade = GETVAR(_player,PayGrade,nil);
|
||||
private _payGrade = GETVAR(_player,FORGE_PayGrade,nil);
|
||||
|
||||
{
|
||||
_x params ["_payGradeIndex", "_payGradeBonus"];
|
||||
@ -73,7 +99,7 @@ switch (_condition) do {
|
||||
} forEach _payGrades;
|
||||
} count playableUnits;
|
||||
|
||||
if (_totalPayment > companyFunds) exitWith { ["Not enough money in the company's account!", "warning", 3] call EFUNC(misc,notify) };
|
||||
if (_totalPayment > _orgFunds) exitWith { ["Not enough money in the organization's account!", "warning", 3] call EFUNC(misc,notify) };
|
||||
|
||||
{
|
||||
_x params ["_player", "_bonus"];
|
||||
@ -85,7 +111,7 @@ switch (_condition) do {
|
||||
} count _paymentToDo;
|
||||
|
||||
["deduct", _totalPayment] call FUNC(adminRefresh);
|
||||
["deduct", _totalPayment] remoteExecCall ["forge_server_money_fnc_handleFunds", 2];
|
||||
_store call ["updateFunds", -_totalPayment];
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_admin_fnc_initAdmin
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the admin menu.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
{
|
||||
private _configName = configName(_x);
|
||||
private _className = (missionConfigFile >> "CfgCpofs" >> "cpofs" >> _configName >> "className") call BFUNC(getCfgData);
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_admin_fnc_openAdmin
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Opens the admin menu.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
disableSerialization;
|
||||
createDialog "RscAdmin";
|
||||
|
||||
@ -10,7 +29,8 @@ private _list2 = _dialog displayCtrl 2023003;
|
||||
{
|
||||
if (str (side _x) == str (playerSide)) then {
|
||||
private _name = name (_x);
|
||||
private _payGrade = GETVAR(_x,paygrade,nil);
|
||||
private _defaultPaygrade = "E1";
|
||||
private _payGrade = GETVAR(_x,FORGE_PayGrade,_defaultPaygrade);
|
||||
private _index = _list lbAdd format["%1 - %2", _name, _payGrade];
|
||||
|
||||
_list lbSetData [_index, _name];
|
||||
|
@ -1,3 +1,22 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_admin_fnc_printAddonName
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Prints the name of the addon to the system chat.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
systemChat format ["Thank you for using the %1", 'ADDON'];
|
@ -3,14 +3,6 @@
|
||||
/*
|
||||
* Function: forge_client_ambient_fnc_ambientSound
|
||||
* Author: J.Schmidt
|
||||
* Edit: 07.15.2024
|
||||
* Copyright © 2024 J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
*
|
||||
* [Description]
|
||||
* Create a sound source and play an ambient sfx sound.
|
||||
|
@ -1,14 +1,28 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_arsenal_fnc_addArmoryItem
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds item to player's armory unlocks and updates virtual arsenal
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Classname of item to add <STRING>
|
||||
* 1: Type of item to add <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* ["B_AssaultPack_rgr", "backpack"] call forge_client_arsenal_fnc_addArmoryItem
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_class", "", [""]], ["_type", "", [""]]];
|
||||
|
||||
private _default = [[],[],[],[]];
|
||||
// private _armory_unlocks = player getVariable ["Armory_Unlocks", _default];
|
||||
private _armory_unlocks = GETVAR(player,Armory_Unlocks,_default);
|
||||
|
||||
private _typeToNumber = switch (_type) do {
|
||||
@ -27,7 +41,6 @@ private _typeToNumber = switch (_type) do {
|
||||
private _index = (_armory_unlocks select _typeToNumber) pushBackUnique _class;
|
||||
|
||||
if (_index > -1) then {
|
||||
// player setVariable ["Armory_Unlocks", _armory_unlocks, true];
|
||||
SETPVAR(player,Armory_Unlocks,_armory_unlocks);
|
||||
|
||||
if (GVAR(armory_type) == 0) then {
|
||||
|
@ -1,11 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_arsenal_fnc_addGarageVehicle
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds vehicle to player's garage unlocks and updates virtual garage
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Classname of vehicle to add <STRING>
|
||||
* 1: Type of vehicle to add <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* ["B_T_LSV_01_unarmed_F", "car"] call forge_client_arsenal_fnc_addGarageVehicle
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
|
||||
params [["_class", "", [""]], ["_type", "", [""]]];
|
||||
|
||||
private _default = [[],[],[],[],[],[]];
|
||||
|
@ -1,17 +1,27 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_arsenal_fnc_addVirtualVehicles
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds vehicles to virtual garage and categorizes them by type
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Vehicles <ARRAY> - Array of vehicle classnames
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* ["B_T_LSV_01_unarmed_F", "car"] call forge_client_arsenal_fnc_addVirtualVehicles
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_vehicles", [], [[]]]];
|
||||
|
||||
private _default = [[],[],[],[],[],[]];
|
||||
// private _garage_unlocks = player getVariable ["Garage_Unlocks", _default];
|
||||
private _garage_unlocks = GETVAR(player,Garage_Unlocks,_default);
|
||||
|
||||
private _cars = _garage_unlocks select 0;
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_arsenal_fnc_initArsenal
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the arsenal system
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Armory data <ARRAY>
|
||||
* 1: Garage data <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_armory_data", [], [[]]], ["_garage_data", [], [[]]]];
|
||||
|
||||
if (count _armory_data isEqualTo [""]) then { _armory_data = [[],[],[],[]] };
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_arsenal_fnc_openArmory
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Opens the arsenal system
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
if (GVAR(armory_type) == 0) then {
|
||||
["Open", [false, GVAR(gear_box), player]] call BFUNC(arsenal);
|
||||
} else {
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_arsenal_fnc_openGarage
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Opens the garage system
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
_locations = (missionConfigFile >> "CfgGarages" >> "locations") call BFUNC(getCfgData);
|
||||
{
|
||||
GVAR(vehSpawnPos) = (_x select 1) getPos [5, (_x select 2)];
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_arsenal_fnc_saveUnlocks
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Saves arsenal/garage unlocks to appropriate storage based on persistence mode
|
||||
*
|
||||
* Arguments:
|
||||
@ -10,8 +13,10 @@
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["armory"] call forge_client_arsenal_fnc_saveArsenalUnlocks
|
||||
* Examples:
|
||||
* ["armory"] call forge_client_arsenal_fnc_saveUnlocks
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_type", "", [""]]];
|
||||
|
@ -1,15 +1,23 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_arsenal_fnc_updateUnlocks
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Updates the arsenal system variables when unlocks change
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Type <STRING> ("armory" or "garage")
|
||||
* 1: Data <ARRAY> (Array of unlocks)
|
||||
*
|
||||
* Example:
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* ["armory", _armory_unlocks] call forge_client_arsenal_fnc_updateUnlocks
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_type", "", [""]], ["_data", [], [[]]]];
|
||||
|
@ -1,8 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_bank_fnc_deposit
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Deposits money into the bank
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _amount = parseNumber (ctrlText IDC_AMOUNTINPUT);
|
||||
// private _bank = player getVariable ["FORGE_Bank", 0];
|
||||
// private _cash = player getVariable ["FORGE_Cash", 0];
|
||||
private _bank = GETVAR(player,FORGE_Bank,0);
|
||||
private _cash = GETVAR(player,FORGE_Cash,0);
|
||||
|
||||
@ -10,12 +27,9 @@ if (_amount > 0 && _amount <= _cash) then {
|
||||
_cash = _cash - _amount;
|
||||
_bank = _bank + _amount;
|
||||
|
||||
// player setVariable ["FORGE_Bank", _bank, true];
|
||||
// player setVariable ["FORGE_Cash", _cash, true];
|
||||
SETPVAR(player,FORGE_Bank,_bank);
|
||||
SETPVAR(player,FORGE_Cash,_cash);
|
||||
|
||||
// [] call forge_client_bank_fnc_refresh;
|
||||
[] call FUNC(refresh);
|
||||
hint "Money deposited successfully";
|
||||
} else {
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_bank_fnc_initBank
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the bank system
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
{
|
||||
private _configName = configName(_x);
|
||||
private _className = (missionConfigFile >> "CfgBanks" >> "banks" >> _configName >> "className") call BFUNC(getCfgData);
|
||||
|
@ -1,7 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
// private _bank = player getVariable ["FORGE_Bank", 0];
|
||||
// private _cash = player getVariable ["FORGE_Cash", 0];
|
||||
/*
|
||||
* Function: forge_client_bank_fnc_openBank
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Opens the bank dialog
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _bank = GETVAR(player,FORGE_Bank,0);
|
||||
private _cash = GETVAR(player,FORGE_Cash,0);
|
||||
private _payMultiplier = "MULTIPLYR" call BFUNC(getParamValue);
|
||||
|
@ -1,7 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
// private _bank = player getVariable ["FORGE_Bank", 0];
|
||||
// private _cash = player getVariable ["FORGE_Cash", 0];
|
||||
/*
|
||||
* Function: forge_client_bank_fnc_refresh
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Refreshes the bank dialog
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _bank = GETVAR(player,FORGE_Bank,0);
|
||||
private _cash = GETVAR(player,FORGE_Cash,0);
|
||||
private _payMultiplier = "MULTIPLYR" call BFUNC(getParamValue);
|
||||
|
@ -1,6 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
// private _bank = player getVariable ["FORGE_Bank", 0];
|
||||
/*
|
||||
* Function: forge_client_bank_fnc_submit
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Submits the timesheet
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _bank = GETVAR(player,FORGE_Bank,0);
|
||||
private _payMultiplyer = "MULTIPLYR" call BFUNC(getParamValue);
|
||||
private _plyscore = rating player;
|
||||
@ -9,15 +27,11 @@ private _multiplyer = _plyscore * _payMultiplyer;
|
||||
_bank = _bank + _multiplyer;
|
||||
|
||||
player addRating - _plyscore;
|
||||
// player setVariable ["FORGE_Bank", _bank];
|
||||
// player setVariable ["FORGE_Rating", 0];
|
||||
SETPVAR(player,FORGE_Bank,_bank);
|
||||
SETPVAR(player,FORGE_Rating,0);
|
||||
|
||||
// [] call forge_client_bank_fnc_refresh;
|
||||
[] call FUNC(refresh);
|
||||
|
||||
private _formattedRating = _bank call EFUNC(misc,formatNumber);
|
||||
|
||||
// hint format ["Timesheet submitted! Received $%1 bonus based on rating of %2", _formattedRating, _plyscore];
|
||||
[format ["Timesheet submitted! Received $%1 based on rating of %2", _formattedRating, _plyscore], "info", 3, "right"] call EFUNC(misc,notify);
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_bank_fnc_transfer
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Transfers money to a player
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_BANKDIALOG;
|
||||
private _input = _display displayCtrl IDC_AMOUNTINPUT;
|
||||
private _dropdown = _display displayCtrl IDC_PLAYERINPUT;
|
||||
@ -8,25 +27,18 @@ private _selectedTarget = lbCurSel _dropdown;
|
||||
private _selectedTargetData = _dropdown lbData _selectedTarget;
|
||||
private _target = objectFromNetId _selectedTargetData;
|
||||
|
||||
// private _bank = player getVariable ["FORGE_Bank", 0];
|
||||
// private _targetBank = _target getVariable ["FORGE_Bank", 0];
|
||||
private _bank = GETVAR(player,FORGE_Bank,0);
|
||||
private _targetBank = GETVAR(_target,FORGE_Bank,0);
|
||||
|
||||
if (!isNull _target && _amount > 0 && _amount <= _bank) then {
|
||||
_targetBank = _targetBank + _amount;
|
||||
// _target setVariable ["FORGE_Bank", _targetBank, true];
|
||||
SETPVAR(_target,FORGE_Bank,_targetBank);
|
||||
|
||||
_bank = _bank - _amount;
|
||||
// player setVariable ["FORGE_Bank", _bank, true];
|
||||
SETPVAR(player,FORGE_Bank,_bank);
|
||||
|
||||
// [] call forge_client_bank_fnc_refresh;
|
||||
[] call FUNC(refresh);
|
||||
// hint format ["Transferred $%1", _amount];
|
||||
[format ["Transferred $%1", _amount], "info", 3, "right"] call EFUNC(misc,notify);
|
||||
} else {
|
||||
// hint "Invalid transfer details";
|
||||
[format ["Invalid transfer details"], "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
};
|
@ -1,11 +1,28 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_bank_fnc_withdraw
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Withdraws money from the bank
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Examples:
|
||||
* None
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_BANKDIALOG;
|
||||
private _input = _display displayCtrl IDC_AMOUNTINPUT;
|
||||
private _amount = parseNumber (ctrlText _input);
|
||||
|
||||
// private _bank = player getVariable ["FORGE_Bank", 0];
|
||||
// private _cash = player getVariable ["FORGE_Cash", 0];
|
||||
private _bank = GETVAR(player,FORGE_Bank,0);
|
||||
private _cash = GETVAR(player,FORGE_Cash,0);
|
||||
|
||||
@ -13,16 +30,11 @@ if (_amount > 0 && _amount <= _bank) then {
|
||||
_bank = _bank - _amount;
|
||||
_cash = _cash + _amount;
|
||||
|
||||
// player setVariable ["FORGE_Bank", _bank, true];
|
||||
// player setVariable ["FORGE_Cash", _cash, true];
|
||||
SETPVAR(player,FORGE_Bank,_bank);
|
||||
SETPVAR(player,FORGE_Cash,_cash);
|
||||
|
||||
// [] call forge_client_bank_fnc_refresh;
|
||||
[] call FUNC(refresh);
|
||||
// hint "Money withdrawn successfully";
|
||||
[format ["Money withdrawn successfully"], "info", 3, "right"] call EFUNC(misc,notify);
|
||||
} else {
|
||||
// hint "Invalid amount";
|
||||
[format ["Invalid amount"], "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
};
|
@ -2,8 +2,8 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_db_fnc_requestServerDB
|
||||
* Author: J. Schmidt
|
||||
*
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Sends database requests to the server using CBA events
|
||||
*
|
||||
|
@ -1,17 +1,18 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
Name: forge_client_dialogue_fnc_selectAI
|
||||
Date: 8/6/2022
|
||||
Version: 1.0
|
||||
Author: J. Schmidt
|
||||
|
||||
Description:
|
||||
Select AI for dialogue.
|
||||
|
||||
Arguments:
|
||||
0: OBJECT - The AI unit
|
||||
*/
|
||||
* Function: forge_client_dialogue_fnc_selectAI
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Selects AI for dialogue
|
||||
*
|
||||
* Arguments:
|
||||
* 0: _units - Array of AI units <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*/
|
||||
|
||||
params [["_units", [], [[]]]];
|
||||
|
||||
|
@ -1,18 +1,19 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
Name: forge_client_dialogue_fnc_selectDialogue
|
||||
Date: 8/6/2022
|
||||
Version: 1.0
|
||||
Author: J. Schmidt
|
||||
|
||||
Description:
|
||||
Create dialogue for AI unit.
|
||||
|
||||
Arguments:
|
||||
0: OBJECT - The AI unit
|
||||
1: STRING - The dialogue
|
||||
*/
|
||||
* Function: forge_client_dialogue_fnc_selectDialogue
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Selects dialogue for AI
|
||||
*
|
||||
* Arguments:
|
||||
* 0: _units - Array of AI units <ARRAY>
|
||||
* 1: _dialogue - Array of dialogue <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*/
|
||||
|
||||
params [["_units", [], [[]]], ["_dialogue", [], [[]]]];
|
||||
|
||||
|
@ -1,8 +1,21 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_garage_fnc_fetchGarage
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Fetches the vehicles in the garage
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_GARAGEDIALOG;
|
||||
private _garageList = _display displayCtrl IDC_GARAGEVEHICLELIST;
|
||||
// private _storedVehicles = player getVariable ["FORGE_Garage", []];
|
||||
private _storedVehicles = GETVAR(player,FORGE_Garage,[]);
|
||||
|
||||
lbClear _garageList;
|
||||
|
@ -1,5 +1,19 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_garage_fnc_fetchNearby
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Fetches the nearby vehicles
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_GARAGEDIALOG;
|
||||
private _vehicleList = _display displayCtrl IDC_VEHICLELIST;
|
||||
|
||||
|
@ -1,5 +1,19 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_garage_fnc_initGarage
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Initializes the garages
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*/
|
||||
|
||||
{
|
||||
private _configName = configName(_x);
|
||||
private _className = (missionConfigFile >> "CfgGarages" >> "garages" >> _configName >> "className") call BFUNC(getCfgData);
|
||||
|
@ -1,5 +1,19 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_garage_fnc_openGarage
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Opens the garage dialog
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*/
|
||||
|
||||
disableSerialization;
|
||||
createDialog "RscGarageDialog";
|
||||
|
||||
|
@ -1,5 +1,20 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_garage_fnc_spawnVehicle
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Spawns a vehicle from the garage
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*/
|
||||
|
||||
disableSerialization;
|
||||
private _display = findDisplay IDD_GARAGEDIALOG;
|
||||
private _garageList = _display displayCtrl IDC_GARAGEVEHICLELIST;
|
||||
private _vehicleList = _display displayCtrl IDC_VEHICLELIST;
|
||||
@ -57,13 +72,11 @@ lbClear _vehicleList;
|
||||
_garageList lbSetCurSel -1;
|
||||
_vehicleList lbSetCurSel -1;
|
||||
|
||||
// private _garage = player getVariable ["FORGE_Garage", []];
|
||||
private _garage = GETVAR(player,FORGE_Garage,[]);
|
||||
private _index = _garage findIf { _x isEqualTo _data };
|
||||
|
||||
if (_index != -1) then {
|
||||
_garage deleteAt _index;
|
||||
// player setVariable ["FORGE_Garage", _garage, true];
|
||||
SETPVAR(player,FORGE_Garage,_garage);
|
||||
};
|
||||
|
||||
|
@ -1,5 +1,19 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_garage_fnc_storeVehicle
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Stores a vehicle in the garage
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_GARAGEDIALOG;
|
||||
private _garageList = _display displayCtrl IDC_GARAGEVEHICLELIST;
|
||||
private _vehicleList = _display displayCtrl IDC_VEHICLELIST;
|
||||
@ -24,7 +38,6 @@ private _veh = objectFromNetId _netID;
|
||||
// str _hitPointsData
|
||||
// ];
|
||||
|
||||
// private _garage = player getVariable ["FORGE_Garage", []];
|
||||
private _garage = GETVAR(player,FORGE_Garage,[]);
|
||||
|
||||
// _garage pushBack [_vehType, _className, _vehData];
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_init_fnc_handlePlayerLoad
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.15.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Handle player load from DB.
|
||||
@ -84,7 +76,7 @@ if (_data isEqualTo [""]) then {
|
||||
SETPVAR(player,FORGE_Phone_Number,_value);
|
||||
};
|
||||
case "paygrade": {
|
||||
SETPVAR(player,Paygrade,_value);
|
||||
SETPVAR(player,FORGE_PayGrade,_value);
|
||||
};
|
||||
case "organization": {
|
||||
SETPVAR(player,FORGE_Organization,_value);
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_init_fnc_initPlayer
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.15.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initialize player.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_init_fnc_playerDBLoad
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.15.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Load player from DB.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_init_fnc_playerDBSave
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.15.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Save player to DB.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_init_fnc_playerSaveLoop
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.15.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initialize player save loop.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_interaction_fnc_initInteraction
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.23.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initialize player interaction.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_interaction_fnc_interactionAction
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.23.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initialize player interaction.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_interaction_fnc_openInteraction
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.23.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Open player interaction.
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_locker_fnc_equipGear
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Equips gear from the locker.
|
||||
*
|
||||
* Arguments:
|
||||
* N/A
|
||||
*
|
||||
* Return Value:
|
||||
* N/A
|
||||
*
|
||||
* Examples:
|
||||
* [] call forge_client_locker_fnc_equipGear;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_LOCKERDIALOG;
|
||||
private _playerItems = _display displayCtrl IDC_PLAYEREQUIPMENTLIST;
|
||||
private _lockerItems = _display displayCtrl IDC_LOCKEREQUIPMENTLIST;
|
||||
@ -7,7 +26,6 @@ private _selectedItem = lbCurSel _lockerItems;
|
||||
private _selectedItemData = _lockerItems lbData _selectedItem;
|
||||
|
||||
private _data = call compile _selectedItemData;
|
||||
// private _locker = player getVariable ["FORGE_Locker", []];
|
||||
private _locker = GETVAR(player,FORGE_Locker,[]);
|
||||
|
||||
if ((isNil { _data })) exitWith { ctrlEnable [IDC_EQUIPBUTTON, true]; };
|
||||
@ -23,7 +41,6 @@ switch (_itemType) do {
|
||||
playSound "FD_Finish_F";
|
||||
} else {
|
||||
_clear = false;
|
||||
// hintSilent "You already have a backpack equipped!";
|
||||
["You already have a backpack equiped!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
playSound "FD_CP_Not_Clear_F";
|
||||
};
|
||||
@ -34,7 +51,6 @@ switch (_itemType) do {
|
||||
playSound "FD_Finish_F";
|
||||
} else {
|
||||
_clear = false;
|
||||
// hintSilent "You already have facewear equipped!";
|
||||
["You already have facewear equiped!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
playSound "FD_CP_Not_Clear_F";
|
||||
};
|
||||
@ -45,7 +61,6 @@ switch (_itemType) do {
|
||||
playSound "FD_Finish_F";
|
||||
} else {
|
||||
_clear = false;
|
||||
// hintSilent "You already have headgear equipped!";
|
||||
["You already have headgear equiped!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
playSound "FD_CP_Not_Clear_F";
|
||||
};
|
||||
@ -56,7 +71,6 @@ switch (_itemType) do {
|
||||
playSound "FD_Finish_F";
|
||||
} else {
|
||||
_clear = false;
|
||||
// hintSilent "You already have a HMD equipped!";
|
||||
["You already have a HMD equiped!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
playSound "FD_CP_Not_Clear_F";
|
||||
};
|
||||
@ -67,7 +81,6 @@ switch (_itemType) do {
|
||||
playSound "FD_Finish_F";
|
||||
} else {
|
||||
_clear = false;
|
||||
// hintSilent "You don't have enough space left!";
|
||||
["You don't have enough space left!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
playSound "FD_CP_Not_Clear_F";
|
||||
};
|
||||
@ -78,7 +91,6 @@ switch (_itemType) do {
|
||||
playSound "FD_Finish_F";
|
||||
} else {
|
||||
_clear = false;
|
||||
// hintSilent "You don't have enough space left!";
|
||||
["You don't have enough space left!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
playSound "FD_CP_Not_Clear_F";
|
||||
};
|
||||
@ -89,7 +101,6 @@ switch (_itemType) do {
|
||||
playSound "FD_Finish_F";
|
||||
} else {
|
||||
_clear = false;
|
||||
// hintSilent "You already have a uniform equipped!";
|
||||
["You already have a uniform equiped!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
playSound "FD_CP_Not_Clear_F";
|
||||
};
|
||||
@ -100,50 +111,10 @@ switch (_itemType) do {
|
||||
playSound "FD_Finish_F";
|
||||
} else {
|
||||
_clear = false;
|
||||
// hintSilent "You already have a vest equipped!";
|
||||
["You already have a vest equiped!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
playSound "FD_CP_Not_Clear_F";
|
||||
};
|
||||
};
|
||||
// case "weapon": {
|
||||
// if (!(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 131072) &&
|
||||
// {!(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 1) || primaryWeapon player == ""} &&
|
||||
// {!(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 2) || handgunWeapon player == ""} &&
|
||||
// {!(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 4) || secondaryWeapon player == ""}) then {
|
||||
|
||||
// private _compatibleMags = getArray (configFile >> "CfgWeapons" >> _item >> "magazines");
|
||||
// private _baseType = (_compatibleMags select 0) select [0, (_compatibleMags select 0) find "_Tracer"];
|
||||
|
||||
// if (_baseType == "") then { _baseType = _compatibleMags select 0 };
|
||||
|
||||
// private _magIndices = [];
|
||||
// {
|
||||
// if ((_x select 0) == "magazine") then {
|
||||
// private _magClass = (_x select 1) select 0;
|
||||
|
||||
// if ((_magClass in _compatibleMags ||
|
||||
// {("ACE_" in _magClass) && {_baseType in _magClass}}) &&
|
||||
// {player canAdd _magClass}) then {
|
||||
// player addMagazine [_magClass, (_x select 1) select 1];
|
||||
// _magIndices pushBack _forEachIndex;
|
||||
// };
|
||||
// };
|
||||
// } forEach _locker;
|
||||
|
||||
// reverse _magIndices;
|
||||
// {
|
||||
// _locker deleteAt _x;
|
||||
// } forEach _magIndices;
|
||||
|
||||
// player addWeapon _item;
|
||||
// playSound "FD_Finish_F";
|
||||
// } else {
|
||||
// _clear = false;
|
||||
// // hintSilent "You don't have enough space left!";
|
||||
// ["You don't have enough space left!", "warning", 3, "right"] call EFUNC(misc,notify);
|
||||
// playSound "FD_CP_Not_Clear_F";
|
||||
// };
|
||||
// };
|
||||
case "weapon": {
|
||||
private _weaponType = getNumber (configFile >> "CfgWeapons" >> _item >> "type");
|
||||
private _hasSpace = switch (_weaponType) do {
|
||||
@ -193,7 +164,6 @@ if (_clear) then {
|
||||
private _index = _locker findIf { _x isEqualTo _data };
|
||||
|
||||
_locker deleteAt _index;
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
[] call FUNC(fetchLocker);
|
||||
|
@ -1,8 +1,26 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_locker_fnc_fetchLocker
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Fetches the locker.
|
||||
*
|
||||
* Arguments:
|
||||
* N/A
|
||||
*
|
||||
* Return Value:
|
||||
* N/A
|
||||
*
|
||||
* Examples:
|
||||
* [] call forge_client_locker_fnc_fetchLocker;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_LOCKERDIALOG;
|
||||
private _itemList = _display displayCtrl IDC_LOCKEREQUIPMENTLIST;
|
||||
// private _locker = player getVariable ["FORGE_Locker", []];
|
||||
private _locker = GETVAR(player,FORGE_Locker,[]);
|
||||
|
||||
{
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_locker_fnc_fetchPlayer
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Fetches the player's gear.
|
||||
*
|
||||
* Arguments:
|
||||
* N/A
|
||||
*
|
||||
* Return Value:
|
||||
* N/A
|
||||
*
|
||||
* Examples:
|
||||
* [] call forge_client_locker_fnc_fetchPlayer;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_LOCKERDIALOG;
|
||||
private _itemList = _display displayCtrl IDC_PLAYEREQUIPMENTLIST;
|
||||
private _data = [];
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_locker_fnc_initLocker
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the lockers.
|
||||
*
|
||||
* Arguments:
|
||||
* N/A
|
||||
*
|
||||
* Return Value:
|
||||
* N/A
|
||||
*
|
||||
* Examples:
|
||||
* [] call forge_client_locker_fnc_initLocker;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
{
|
||||
private _configName = configName(_x);
|
||||
private _className = (missionConfigFile >> "CfgLockers" >> "lockers" >> _configName >> "className") call BFUNC(getCfgData);
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_locker_fnc_openLocker
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Opens the locker dialog.
|
||||
*
|
||||
* Arguments:
|
||||
* N/A
|
||||
*
|
||||
* Return Value:
|
||||
* N/A
|
||||
*
|
||||
* Examples:
|
||||
* [] call forge_client_locker_fnc_openLocker;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
disableSerialization;
|
||||
createDialog "RscLockerDialog";
|
||||
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_locker_fnc_storeGear
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Stores gear in the locker.
|
||||
*
|
||||
* Arguments:
|
||||
* N/A
|
||||
*
|
||||
* Return Value:
|
||||
* N/A
|
||||
*
|
||||
* Examples:
|
||||
* [] call forge_client_locker_fnc_storeGear;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _display = findDisplay IDD_LOCKERDIALOG;
|
||||
private _playerItems = _display displayCtrl IDC_PLAYEREQUIPMENTLIST;
|
||||
private _lockerItems = _display displayCtrl IDC_LOCKEREQUIPMENTLIST;
|
||||
@ -7,7 +26,6 @@ private _selectedItem = lbCurSel _playerItems;
|
||||
private _selectedItemData = _playerItems lbData _selectedItem;
|
||||
|
||||
private _data = call compile _selectedItemData;
|
||||
// private _locker = player getVariable ["FORGE_Locker", []];
|
||||
private _locker = GETVAR(player,FORGE_Locker,[]);
|
||||
|
||||
if ((isNil { _data })) exitWith { ctrlEnable [IDC_STOREBUTTON, true]; };
|
||||
@ -35,7 +53,6 @@ switch (_itemType) do {
|
||||
} count (magazinesAmmoCargo backpackContainer player);
|
||||
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
removeBackpack player;
|
||||
@ -43,7 +60,6 @@ switch (_itemType) do {
|
||||
};
|
||||
case "facewear": {
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
removeGoggles player;
|
||||
@ -51,7 +67,6 @@ switch (_itemType) do {
|
||||
};
|
||||
case "headgear": {
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
removeHeadgear player;
|
||||
@ -59,7 +74,6 @@ switch (_itemType) do {
|
||||
};
|
||||
case "hmd": {
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
player unassignItem _item;
|
||||
@ -68,7 +82,6 @@ switch (_itemType) do {
|
||||
};
|
||||
case "item": {
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
if (_item == (currentMuzzle player)) then {
|
||||
@ -83,7 +96,6 @@ switch (_itemType) do {
|
||||
};
|
||||
case "magazine": {
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
private _temp = magazinesAmmoFull player;
|
||||
@ -161,7 +173,6 @@ switch (_itemType) do {
|
||||
} count (magazinesAmmoCargo uniformContainer player);
|
||||
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
removeUniform player;
|
||||
@ -186,7 +197,6 @@ switch (_itemType) do {
|
||||
} count (magazinesAmmoCargo vestContainer player);
|
||||
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
removeVest player;
|
||||
@ -194,7 +204,6 @@ switch (_itemType) do {
|
||||
};
|
||||
case "weapon": {
|
||||
_locker pushBack [_itemType, _item];
|
||||
// player setVariable ["FORGE_Locker", _locker, true];
|
||||
SETPVAR(player,FORGE_Locker,_locker);
|
||||
|
||||
private _temp = weaponsItems player;
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_medical_fnc_deductMedicalCost
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Deducts the medical cost from the player's account.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Total Cost <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, 100] call forge_client_medical_fnc_deductMedicalCost;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_unit", "_totalCost"];
|
||||
|
||||
private _preferredAccount = GETVAR(_unit,FORGE_Bank,0);
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_medical_fnc_deductMedicalCost
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Deducts the medical cost from the player's account.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Total Cost <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, 100] call forge_client_medical_fnc_deductMedicalCost;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_unit", "_totalCost"];
|
||||
|
||||
while { (GETVAR(_unit,FORGE_Cash,0)) < _totalCost or (GETVAR(_unit,FORGE_Bank,0)) < _totalCost } do {
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_medical_fnc_initMedical
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the medical system.
|
||||
*
|
||||
* Arguments:
|
||||
* N/A
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_medical_fnc_initMedical;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _worldCenter = getArray (configFile >> "CfgWorlds" >> worldName >> "centerPosition");
|
||||
private _stretcherTypes = ["Land_Stretcher_01_F", "Land_Stretcher_01_olive_F", "Land_Stretcher_01_sand_F"];
|
||||
private _stretchers = nearestObjects [_worldCenter, _stretcherTypes, 500000];
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_medical_fnc_moveInventory
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Moves the unit's inventory to the body bag.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Body Bag <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, bodyBag] call forge_client_medical_fnc_moveInventory;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_unit", "_bodyBag"];
|
||||
|
||||
private _items = [];
|
||||
|
@ -1,5 +1,27 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_medical_fnc_onKilled
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Handles the unit's death.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Killer <OBJECT>
|
||||
* 2: Instigator <OBJECT>
|
||||
* 3: Use Effects <BOOLEAN>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, objNull, objNull, true] call forge_client_medical_fnc_onKilled;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_unit", "_killer", "_instigator", "_useEffects"];
|
||||
|
||||
if (!isPlayer _unit) exitWith {};
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_medical_fnc_onRespawn
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Handles the unit's respawn.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
* 1: Corpse <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player, bodyBag] call forge_client_medical_fnc_onRespawn;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_unit", "_corpse"];
|
||||
|
||||
private _newBank = 0;
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_medical_fnc_saveDroppedWeapons
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Saves the unit's dropped weapons and items.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [player] call forge_client_medical_fnc_saveDroppedWeapons;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_unit"];
|
||||
|
||||
private _droppedWeapons = [];
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_misc_fnc_cargoToPairs
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Converts a cargo array to an array of pairs.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Cargo Array <ARRAY>
|
||||
* 1: Optional: Second Array <ARRAY>
|
||||
*
|
||||
* Return Value:
|
||||
* Array of Pairs <ARRAY>
|
||||
*
|
||||
* Example:
|
||||
* [[1, 2, 3], [4, 5, 6]] call forge_client_misc_fnc_cargoToPairs;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _array = [];
|
||||
|
||||
if (count _this > 1) then {
|
||||
|
@ -1,15 +1,22 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: dragonfly_misc_fnc_deserializeString
|
||||
* Description:
|
||||
* Converts underscores in a string to spaces for display
|
||||
* Function: forge_client_misc_fnc_deserializeString
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Parameters:
|
||||
* 0: _string - String to convert <STRING>
|
||||
* [Description]
|
||||
* Converts underscores in a string to spaces for display.
|
||||
*
|
||||
* Returns:
|
||||
* Converted string <STRING>
|
||||
* Arguments:
|
||||
* 0: String <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* Deserialized String <STRING>
|
||||
*
|
||||
* Example:
|
||||
* ["Hello_World"] call forge_client_misc_fnc_deserializeString;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_string", "", [""]]];
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_misc_fnc_formatNumber
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Formats a number with thousands separators and decimal places.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Number <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* Formatted Number <STRING>
|
||||
*
|
||||
* Example:
|
||||
* [1234567.89] call forge_client_misc_fnc_formatNumber;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
#define PX_DC_SEP "."
|
||||
#define PX_TH_SEP ","
|
||||
#define PX_DC_PL 2
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_misc_fnc_getSystemTime
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Gets the current system time in a formatted string.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* Formatted System Time <STRING>
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_misc_fnc_getSystemTime;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _timestamp = systemTimeUTC apply { if (_x < 10) then { "0" + str _x } else { str _x }};
|
||||
private _dateTime = format ["%1-%2-%3_%4:%5:%6.%7", _timestamp#0, _timestamp#1, _timestamp#2, _timestamp#3, _timestamp#4, _timestamp#5, _timestamp#6];
|
||||
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_misc_fnc_isAssignableBinocular
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Checks if a binocular is assignable.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Binocular <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* Is Assignable <BOOLEAN>
|
||||
*
|
||||
* Example:
|
||||
* ["Binocular"] call forge_client_misc_fnc_isAssignableBinocular;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _player = _this select 0;
|
||||
private _item = _this select 1;
|
||||
private _isAssignable = true;
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_misc_fnc_isWeaponType
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Checks if a weapon is of a certain type.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Weapon <STRING>
|
||||
* 1: Type <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* Is Weapon Type <BOOLEAN>
|
||||
*
|
||||
* Example:
|
||||
* ["arifle_MX_F", 4096] call forge_client_misc_fnc_isWeaponType;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _weapon = _this select 0;
|
||||
private _type = _this select 1;
|
||||
private _typeBits = [];
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_misc_fnc_notify
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.15.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Creates a notification.
|
||||
|
@ -1,15 +1,22 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: dragonfly_misc_fnc_serializeString
|
||||
* Description:
|
||||
* Converts spaces in a string to underscores for database storage
|
||||
* Function: forge_client_misc_fnc_serializeString
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Parameters:
|
||||
* 0: _string - String to convert <STRING>
|
||||
* [Description]
|
||||
* Converts spaces in a string to underscores for database storage.
|
||||
*
|
||||
* Returns:
|
||||
* Converted string <STRING>
|
||||
* Arguments:
|
||||
* 0: String <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* Serialized String <STRING>
|
||||
*
|
||||
* Example:
|
||||
* ["Hello World"] call forge_client_misc_fnc_serializeString;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params [["_string", "", [""]]];
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_misc_fnc_test
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.15.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-sa/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Test function.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_money_fnc_giveCash
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.23.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Send money to player.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_money_fnc_giveCashSubmit
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.23.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Handle cash to be given.
|
||||
|
@ -2,15 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_money_fnc_takeCash
|
||||
* Author: Creedcoder, J.Schmidt
|
||||
* Edit: 07.23.2024
|
||||
* Copyright © 2024 Creedcoder, J.Schmidt, All rights reserved
|
||||
*
|
||||
* Do not edit without permission!
|
||||
*
|
||||
* This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivative 4.0 International License.
|
||||
* To view a copy of this license, vist https://creativecommons.org/licenses/by-nc-nd/4.0/ or send a letter to Creative Commons,
|
||||
* PO Box 1866, Mountain View, CA 94042
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Handle cash picked up.
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_addAsset
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds an asset to an organization's inventory.
|
||||
*
|
||||
* Arguments:
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_addFunds
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds or removes funds from an organization's account.
|
||||
* Positive values increase funds, negative values decrease funds.
|
||||
*
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_addMember
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds a new member to an organization. Only the organization owner can add members.
|
||||
* The new member will be assigned the default "member" role.
|
||||
*
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_addReputation
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds or removes reputation from an organization.
|
||||
* Positive values increase reputation, negative values decrease reputation.
|
||||
*
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_create
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Creates a new organization for a player.
|
||||
* Initializes the organization with the specified name, owner, and optional starting funds and reputation.
|
||||
*
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_disband
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Disbands an organization if requested by the owner.
|
||||
* This permanently deletes the organization from the database and cannot be undone.
|
||||
* Only the organization owner can perform this action.
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_handleOrgLoad
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Processes and transforms raw organization data from a database into a structured hashMap.
|
||||
* Handles data normalization, type conversion, and ensures all required organization fields are present.
|
||||
* This function is called as a callback when organization data is loaded from the database.
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/*
|
||||
* Function: forge_client_org_fnc_initOrgStore
|
||||
* Author: J. Schmidt
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* Description:
|
||||
* Initializes a client-side organization store interface for managing player organization data
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_leave
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Removes the current player from an organization.
|
||||
* This allows a member to leave their organization voluntarily.
|
||||
* Organization owners cannot use this function and must use disband instead.
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_removeAsset
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Removes an asset from an organization's inventory.
|
||||
* Deletes the specified asset based on its type and unique identifier.
|
||||
*
|
||||
|
@ -1,7 +1,10 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Author: J. Schmidt
|
||||
* Function: forge_client_org_fnc_verifyOrgStore
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Ensures the organization store is initialized and returns the store object.
|
||||
* Acts as a singleton accessor for the organization store interface.
|
||||
* If the store doesn't exist yet, it initializes it first.
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_addContact
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds a contact to the address book.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Contact <OBJECT> - The contact to add
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [cursorObject] call forge_client_phone_fnc_addContact;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_contact"];
|
||||
|
||||
private _defaultPhoneNumber = "unknown";
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_addEmail
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds an email to the address book.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Email <STRING> - The email to add
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["test@test.com"] call forge_client_phone_fnc_addEmail;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
if (_this isEqualTo [""]) exitWith {};
|
||||
|
||||
private _tmp = call compile format ["%1", _this];
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_addMsg
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds a message to the message log.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Message <STRING> - The message to add
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["Hello World"] call forge_client_phone_fnc_addMsg;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
if (_this isEqualTo [""]) exitWith {};
|
||||
|
||||
private _tmp = call compile format ["%1", _this];
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_addOfflineEmail
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds an email to the offline email list.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Email <STRING> - The email to add
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["test@test.com"] call forge_client_phone_fnc_addOfflineEmail;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
if (_this isEqualTo [""]) exitWith {};
|
||||
|
||||
private _tmp = call compile format ["%1", _this];
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_addOfflineMsg
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds a message to the offline message list.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Message <STRING> - The message to add
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["Hello World"] call forge_client_phone_fnc_addOfflineMsg;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
if (_this isEqualTo [""]) exitWith {};
|
||||
|
||||
private _tmp = call compile format ["%1", _this];
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_dateToHhMm
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Converts a date to a string in the format "HH:MM".
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Date <ARRAY> - The date to convert
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [date] call forge_client_phone_fnc_dateToHhMm;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private ["_h", "_m"];
|
||||
|
||||
_h = _this select 0;
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_delEmail
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Deletes an email from the address book.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_delEmail;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _myDialog = findDisplay 202300;
|
||||
private _ctrl01 = _myDialog displayCtrl 202302;
|
||||
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_delMsg
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Deletes a message from the message log.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_delMsg;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _myDialog = findDisplay 202300;
|
||||
private _ctrl01 = _myDialog displayCtrl 202302;
|
||||
|
||||
|
@ -1,3 +1,22 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_initAction
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the phone action.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_initAction;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
[] spawn FUNC(openPhone);
|
@ -1,4 +1,23 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_initAddAction
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the phone action.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_initAddAction;
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
waitUntil { "FORGE_Phone" in items player };
|
||||
FORGE_addAction = player addAction ["<t color='#0000CC'>Mobile Phone</t>", FUNC(initAction), [], -99, false, false, "", ""];
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_initPhone
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the phone.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_initPhone;
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
waitUntil { !isNull player && player == player };
|
||||
waitUntil { !isNil "BIS_fnc_init" };
|
||||
waitUntil { !(isNull (findDisplay 46)) };
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_initVar
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Initializes the phone variables.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_initVar;
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
FORGE_AddressBook = GETVAR(profileNamespace,FORGE_AddressBook,[]);
|
||||
FORGE_Phone_MSG = [];
|
||||
FORGE_Email = [];
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_newEmail
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds a new email to the address book.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Email <STRING> - The email to add
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["test@test.com"] call forge_client_phone_fnc_newEmail;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
_email = (_this select 0);
|
||||
{
|
||||
if (_email == (_x select 1)) then {
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_newMsg
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Adds a new message to the message log.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Number <STRING> - The number to add
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["1234567890"] call forge_client_phone_fnc_newMsg;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
_number = (_this select 0);
|
||||
{
|
||||
if (_number == (_x select 1)) then {
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_openPhone
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Opens the phone.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_openPhone;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _defaultTheme = ["bg_dark01", "\@forge\userconfig\backgrounds\bgdark_01.paa"];
|
||||
private _theme = GETVAR(profileNamespace,FORGE_PhoneTheme,_defaultTheme);
|
||||
private _themeBackground = _theme select 1;
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_sendEmail
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Sends an email.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Email <STRING> - The email to send to
|
||||
* 1: Message <STRING> - The message to send
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["test@test.com", "Hello World"] call forge_client_phone_fnc_sendEmail;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_email", "_msg"];
|
||||
|
||||
private _defaultEmail = "unknown@spearnet.mil";
|
||||
|
@ -1,5 +1,25 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_sendMsg
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Sends a message.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Number <STRING> - The number to send to
|
||||
* 1: Message <STRING> - The message to send
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["1234567890", "Hello World"] call forge_client_phone_fnc_sendMsg;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
params ["_number", "_msg"];
|
||||
|
||||
private _defaultPhoneNumber = "unknown";
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_showContact
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Shows the contact list.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_showContact;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _cntcBtns = [202223, 202224, 202414, 202415];
|
||||
private _metaCtrls = [2023001, 2023002, 2023003, 2023004, 2023005, 2023006];
|
||||
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_showDialpad
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Shows the dialpad.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_showDialpad;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _homeScreenBgBtns = [202202, 202203, 202204, 202205, 202206, 202207, 202208, 202209];
|
||||
private _homeScreenBtns = [202310, 202311, 202312, 202313, 202314, 202315, 202316, 202317, 202318];
|
||||
private _dialpadBgBtns = [202210, 202211, 202212, 202213, 202214, 202215, 202216, 202217, 202218, 202219, 202220, 202221, 202222];
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_showEmail
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Shows the email.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_showEmail;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _metaCtrls = [2023001, 2023002, 2023003];
|
||||
|
||||
{
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_showMessage
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Shows the message.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_showMessage;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _metaCtrls = [2023001, 2023002, 2023003];
|
||||
|
||||
{
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_showMessageInput
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Shows the message input.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_showMessageInput;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _metaCtrls = [2023001, 2023002, 2023003];
|
||||
|
||||
{
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_showSafari
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Shows the safari browser.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_showSafari;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _homeScreenBgBtns = [202202, 202203, 202204, 202205, 202206, 202207, 202208, 202209];
|
||||
private _homeScreenBtns = [202310, 202311, 202312, 202313, 202314, 202315, 202316, 202317, 202318];
|
||||
|
||||
|
@ -1,5 +1,24 @@
|
||||
#include "..\script_component.hpp"
|
||||
|
||||
/*
|
||||
* Function: forge_client_phone_fnc_viewContacts
|
||||
* Author: IDSolutions
|
||||
*
|
||||
* [Description]
|
||||
* Shows the contact list.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [] call forge_client_phone_fnc_viewContacts;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
|
||||
private _homeScreenBgBtns = [202202, 202203, 202204, 202205, 202206, 202207, 202208, 202209];
|
||||
private _homeScreenBtns = [202310, 202311, 202312, 202313, 202314, 202315, 202316, 202317, 202318];
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user