ktoxktox docs

Troubleshooting

Common issues and fixes for ktx_cases.

Troubleshooting

Case not opening

  • The item field in the case config must exactly match the inventory item name
  • Check that registerUsableItem in custom/server.lua works with your framework
  • Verify the case is not set to "disabled": true
  • Try the /cases command as a fallback to test the UI

No reward given

  • Check giveReward in custom/server.lua for 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 giveVehicle function in custom/server.lua inserts into the owned_vehicles table (ESX default)
  • For QBx/QB-Core, update the function to use player_vehicles or your framework's vehicle storage
  • Ensure the vehicle model is a valid GTA spawn name

Coins not working

  • coinsEnabled must be true in the RewardTypes config
  • The sky_coinsystem resource must be running
  • Check that the AddCoins export exists and works

Animation issues

  • Check the NUI frame is loading - look for browser errors in F8 console
  • Try the /cases command to verify the UI works independently
  • Restart the resource and try again

Database logging not working

  • Ensure install.sql was imported into your database
  • Database.logOpenings must be true in config
  • Verify oxmysql is running and connected