
This commit introduces significant changes to the admin panel, store, and arsenal systems, focusing on improved functionality, UI enhancements, and code optimization. **Admin Panel:** - Migrated to a web-based UI for improved user experience and maintainability. - Implemented dynamic player listing with filtering and search capabilities. - Added functionality for managing player paygrades, sending messages, and transferring funds. - Integrated server-side events for handling admin actions. **Store:** - Added `handleDelivery` event handler. - Streamlined product selection and purchase processes. - Improved handling of organization funds and player balances. - Refactored code for better readability and maintainability. **Arsenal:** - Enhanced initialization process with improved data validation. - Optimized item unlocking logic. These changes aim to provide a more robust, user-friendly, and efficient experience for both administrators and players.
44 lines
1.1 KiB
Plaintext
44 lines
1.1 KiB
Plaintext
#include "..\script_component.hpp"
|
|
|
|
/*
|
|
* Function: forge_client_admin_fnc_adminRefresh
|
|
* Author: IDSolutions
|
|
*
|
|
* [Description]
|
|
* Refreshes the admin interface player list and resets input fields.
|
|
* This function populates the player list with names and paygrades,
|
|
* storing player UIDs as data for each entry. Only shows players
|
|
* on the same side as the admin.
|
|
*
|
|
* Arguments:
|
|
* 0: Dummy <ANY> - Optional parameter, not used (for compatibility with event handlers)
|
|
*
|
|
* Return Value:
|
|
* None
|
|
*
|
|
* Examples:
|
|
* [] call forge_client_admin_fnc_adminRefresh;
|
|
* ["dummy"] call forge_client_admin_fnc_adminRefresh;
|
|
*
|
|
* Public: No - Called from admin dialog controls
|
|
*/
|
|
|
|
|
|
private _dialog = findDisplay 202303;
|
|
private _list = _dialog displayCtrl 2023001;
|
|
|
|
lbClear _list;
|
|
|
|
{
|
|
if (str (side _x) == str (playerSide)) then {
|
|
private _name = name (_x);
|
|
private _paygrade = GETVAR(_x,FORGE_PayGrade,QUOTE(E1));
|
|
private _index = _list lbAdd format["%1 - %2", _name, _paygrade];
|
|
|
|
_list lbSetData [_index, getPlayerUID _x];
|
|
};
|
|
} forEach allPlayers;
|
|
|
|
lbSetCurSel [2023001, 0];
|
|
ctrlSetText [2023005, ""];
|
|
ctrlSetText [2023006, ""]; |