Troubleshooting
Common issues and fixes for ktx_cases.
Troubleshooting
Case not opening
- The
itemfield in the case config must exactly match the inventory item name - Check that
registerUsableItemincustom/server.luaworks with your framework - Verify the case is not set to
"disabled": true - Try the
/casescommand as a fallback to test the UI
No reward given
- Check
giveRewardincustom/server.luafor errors - Look at the server console for error messages after opening a case
- Verify the player has inventory space for item rewards
Vehicle reward not working
- The
giveVehiclefunction incustom/server.luainserts into theowned_vehiclestable (ESX default) - For QBx/QB-Core, update the function to use
player_vehiclesor your framework's vehicle storage - Ensure the vehicle model is a valid GTA spawn name
Coins not working
coinsEnabledmust betruein theRewardTypesconfig- The
sky_coinsystemresource must be running - Check that the
AddCoinsexport exists and works
Animation issues
- Check the NUI frame is loading - look for browser errors in F8 console
- Try the
/casescommand to verify the UI works independently - Restart the resource and try again
Database logging not working
- Ensure
install.sqlwas imported into your database Database.logOpeningsmust betruein config- Verify oxmysql is running and connected