π οΈConfiguration
This document describes all configuration options for the DevHub Air Drops resource.
π οΈ Configuration
Shared Configuration (configs/shared.lua)
configs/shared.lua)Debug Configuration
Controls debug output for the air drops system.
Shared.Debug = {
Enabled = true, -- Set to false to disable all debug prints
Levels = {
Info = true, -- General information
Success = true, -- Success operations
Warning = true -- Warning and potential issues
}
}Enabled: Enables/disables all debug prints.
Levels: Controls specific debug message types (Info, Success, Warning).
Drop Presets Configuration
Defines different categories of items that can be dropped in airdrops. Each preset contains a list of items with their spawn properties.
Structure Explanation:
name: The item identifier/name (must match your inventory system).
amount: Min and max quantity range for the item.
min: Minimum amount to spawn.
max: Maximum amount to spawn.
chance: Percentage chance (0-100) for the item to spawn.
Note: Each preset's chances should ideally sum to 100% for proper distribution.
Mission Drop Configuration
Defines special mission-based airdrops with specific loot tables and requirements.
Structure Explanation:
name: The drop preset category (references
Shared.DropPresets).chance: Percentage chance for this mission drop type to occur.
amount: Number of items from the preset to drop.
min: Minimum number of items.
max: Maximum number of items.
requiredItem: Items required to open the crate (false = no requirements).
Key: Item name.
Value: Required quantity.
Client Configuration (configs/client.lua)
configs/client.lua)Guards Settings
Configures NPC guards that protect the air drop zones.
Configuration Details:
amount: Random number of guards spawned per air drop.
min: Minimum guards (5).
max: Maximum guards (15).
modelsPresets: Arrays of ped models for guard variety.
Each array represents a thematic group (military, blackops, security, gang, marines).
System randomly selects one preset per air drop for visual consistency.
weapons: List of weapons guards can be equipped with.
Guards are randomly assigned weapons from this list.
Server Configuration (configs/server.lua)
configs/server.lua)Air Drop Zones
Defines all possible locations where air drops can occur.
coords: vec3 coordinates (x, y, z) - the center point of the air drop zone.
radius: The spawn radius around the coordinates (in meters). The air drop will spawn at a random location within this radius from the center point.
To add more zones:
Air Drop Stats
Controls the behavior of falling air drops.
fallTime: How long the air drop takes to fall from the sky.
min: Minimum fall duration (2 seconds).
max: Maximum fall duration (5 seconds).
Note: Actual fall time is randomized between min and max for each drop.
Translation Configuration (configs/translation.lua)
configs/translation.lua)Customize all user-facing text in the resource.
Modify these strings to change the language or customize messages.
Add your own language translations by following the same format.
Customization
Adding New Drop Presets
Create custom loot categories for different scenarios:
Adjusting Guard Difficulty
Easier (Fewer Guards):
Harder (More Guards & Better Weapons):
Modifying Drop Chances
Adjust the probability of different loot types:
High-Value Drops (More Weapons/Medical):
Balanced Drops:
Creating Locked vs Unlocked Crates
Control which crates require items to open:
All Crates Open (No Requirements):
All Crates Locked:
Advanced Configuration
Creating Themed Guard Presets
Customize guard appearance for different scenarios:
Dynamic Fall Time Based on Height
Adjust fall times for different scenarios:
Quick Drops (Low Altitude):
Realistic Drops (High Altitude):
Cinematic Drops (Very Slow):
Troubleshooting
Air drops not spawning:
β Verify
Config.AirDropZonescontains valid coordinates.Check server console for errors during resource start.
Ensure the triggering event/command is correctly configured.
Guards not spawning:
Check
Config.GuardsSettings.amountvalues are greater than 0.Verify ped model names in
modelsPresetsare valid GTA V models.Enable debug mode to see spawn messages.
Players can't open crates:
Verify players have the required items defined in
Shared.MissionDrop.requiredItem.Check item names match your inventory system exactly (case-sensitive).
Ensure inventory has space for the dropped items.
Items not being received:
β Confirm items in
Shared.DropPresetsexist in your database/item configuration.Check item names match exactly (case-sensitive).
Verify player inventory has sufficient weight capacity.
Enable debug mode to see item distribution logs.
Guards not attacking:
Check weapon names in
Config.GuardsSettings.weaponsare valid.Verify no conflicting resources affecting NPC behavior.
Last updated