Hate Looting is an advanced looting system for FiveM servers that supports both QBCore and ESX frameworks. It provides a comprehensive solution for searching objects, looting NPCs, and managing inventory with advanced clothing metadata generation and Discord logging integration.
Key Highlights
Dual Framework Support: Works with both QBCore and ESX
Advanced Clothing System: Automatic metadata generation with blacklist support
Multiple UI Options: Built-in UI or core_inventory integration
Discord Integration: Rich logging with inventory images
Performance Optimized: Client-side detection and caching systems
Ensure framework resource is started before hate-looting
Check framework resource names match expected names
Verify framework is properly installed
4. Loot Not Refreshing
Problem: Loot locations don't refresh Solution:
Check Config.lootRefreshTime and Config.emptyLootRefreshTime
Verify server isn't restarting before refresh time
Check for errors in server console
5. Distance/Target Issues
Problem: Can't target objects or distance issues Solution:
Adjust Config.TargetDistance
Check target system integration (ox_target, qb-target)
Verify Config.DistanceCheckProtection isn't too restrictive
Debug Mode
Enable debug mode for troubleshooting:
This will provide console output for:
Loot generation processes
Clothing metadata generation
Framework detection
Target system interactions
Performance Optimization
Client-Side Caching
The script uses client-side caching for clothing max values to reduce server load:
Cache duration: 5 minutes
Automatic cache refresh
Fallback to config values if detection fails
Server-Side Optimization
Unified framework system reduces code duplication
Efficient loot generation algorithms
Optimized database queries (if applicable)
Error Logging
The script includes comprehensive error logging:
Server console errors
Client console errors (when debug enabled)
Discord webhook error notifications
Fallback systems for critical failures
Support
For additional support:
Check this documentation first
Enable debug mode to identify issues
Check server/client console for errors
Verify all dependencies are properly installed
Ensure proper configuration of all systems
This documentation covers the complete feature set of Hate Looting. For the most up-to-date information, always refer to the latest version of this documentation.
Config.PedDeleteTime = 10 -- Time in seconds after which looted ped will be deleted
Config.TargetDistance = 4.0 -- Distance to target peds/objects
Config.animalLoot = true -- Enable animal looting
Config.enableZombieLoot = true -- Enable zombie looting
Config.Debug = false -- Enable debug mode
Config.lootRefreshTime = 30 -- Default refresh time for prop loot (minutes)
Config.emptyLootRefreshTime = 5 -- Empty loot location refresh time (minutes)
Config.UseUIType = "ownui" -- "ownui" or "core_inventory"
Config.UseProgressBar = true -- Use progress bar
Config.UsePressE = false -- Use press E to loot instead of target system
Config.DistanceCheckProtection = 25.0 -- Security distance check
Config.InventoryImagePath = "nui://core_inventory/html/img/" -- Image path for inventory items
if GetResourceState('es_extended') ~= 'missing' then
Config.Framework = "ESX"
elseif GetResourceState('qb-core') ~= 'missing' then
Config.Framework = "QB"
end
-- Generate clothing metadata
generateClothingMetadata(itemName, src)
-- Check if item is clothing
isClothingItem(itemName)
-- Get torso mapping for model
GetTorsoForModel(mModel, gender)
-- Preload clothing max values
preloadClothingMaxValues(src)
-- Generate random number for loot ID
returnRandomNumber()
-- Round coordinates for consistency
roundCoords(coords)
-- Find entity in loot table
findEntityInTable(entity, coords, model)
-- Get loop increase from zones
GetLoopAdd(lootType, coords)
-- Get max clothing variations
GetClothingMaxValues(clothesConfig)
-- Check required weapons
HasRequiredWeapon(lootType)