client/addons/locker/README.md
Jacob Schmidt 9936d6ddc3
All checks were successful
Build / Build (push) Successful in 28s
feat: Enhance module documentation and features
This commit updates the documentation for several Forge modules, adding comprehensive details about their functionalities, user interfaces, and integration with other systems. Key enhancements include:

- Expanded descriptions for the Admin, Arsenal, Bank, Garage, Interaction, Locker, Medical, Organization, Service, Store, and other modules.
- Added new features such as financial operations, user interface improvements, and integration with organization systems.
- Improved clarity on usage instructions and configuration options across modules.

These changes aim to provide better guidance for users and developers interacting with the Forge client system.
2025-05-25 16:03:03 -05:00

149 lines
3.8 KiB
Markdown

# Forge Locker Module
## Overview
The Locker module provides a comprehensive equipment management system for the Forge client. It includes features for storing, equipping, and managing player gear in a secure locker system with a modern web-based interface.
## Dependencies
- forge_client_main
## Authors
- J. Schmidt
- Creedcoder
- IDSolutions
## Features
### Locker System
1. **Locker Initialization** (`fnc_initLocker.sqf`)
- Initializes the locker system
- Sets up storage structures
- Configures player variables
- Manages equipment tracking
2. **Equipment Management**
- **Store Gear** (`fnc_storeGear.sqf`)
- Stores equipment in locker
- Handles different item types:
- Backpacks (with contents)
- Facewear (goggles)
- Headgear
- HMD (Head Mounted Display)
- Uniforms
- Vests
- Weapons (with attachments)
- Items
- Magazines (with ammo count)
- Manages storage space
- Preserves item condition
- **Equip Gear** (`fnc_equipGear.sqf`)
- Equips items from locker
- Handles equipment compatibility
- Manages inventory space
- Preserves attachments and magazines
- Provides feedback on actions
3. **Data Management**
- **Fetch Locker** (`fnc_fetchLocker.sqf`)
- Retrieves locker contents
- Updates UI display
- Manages item categorization
- Handles item metadata
- **Fetch Player** (`fnc_fetchPlayer.sqf`)
- Retrieves player equipment
- Updates UI display
- Manages equipment lists
- Handles item metadata
### User Interface
1. **Modern Web Interface**
- Responsive design
- Category filtering
- Item categorization
- Storage statistics
- Equipment details view
2. **Interface Features**
- Storage space tracking
- Item count display
- Category filters:
- All Items
- Weapons
- Clothing
- Equipment
- Magazines
- Item details:
- Name
- Category
- Condition
- Quantity
- Attachments
3. **Control Elements**
- Store button
- Equip button
- Category filters
- Item lists
- Status indicators
## Event Handlers
The module uses several event handlers for initialization and execution:
- `XEH_preInit.sqf`: Pre-initialization setup
- `XEH_postInit.sqf`: Post-initialization tasks
- `XEH_preStart.sqf`: Pre-start configuration
- `XEH_postInit_client.sqf`: Client-specific post-initialization
- `XEH_preInit_server.sqf`: Server-specific pre-initialization
## Usage
To use the locker module:
1. Ensure the module is properly loaded in your mission
2. Access the locker through the interaction menu
3. Manage equipment using the interface:
```sqf
// Open locker interface
[] call forge_client_locker_fnc_openLocker;
// Store equipment
[] call forge_client_locker_fnc_storeGear;
// Equip items
[] call forge_client_locker_fnc_equipGear;
```
4. Monitor storage space and item status
## Configuration
The module can be configured through the main Forge client configuration:
```cpp
// Locker storage space (default: 100)
FORGE_Locker_Space = 100;
// Enable/disable features
FORGE_Locker_EnableAttachments = 1;
FORGE_Locker_EnableMagazines = 1;
```
## Debugging
Debug mode can be enabled by uncommenting the following in `script_component.hpp`:
```cpp
#define DEBUG_MODE_FULL
```
## Version Information
Version information is managed through the main Forge client system configuration.
## Technical Details
- Modern web-based interface
- Real-time storage tracking
- Equipment condition preservation
- Attachment management
- Magazine ammo tracking
- Category-based filtering
- Responsive UI design
- Error handling
- User feedback
- State management
- Event system integration
- Database persistence
- Inventory validation
- Space management