Installation

Add dependencies:

Add the script:

  1. Download ak47_inventory from your keymaster.

  2. Add the script into your resources folder.

  3. Add the script in server.cfg after es_extended and make sure all other script is starting after the inventory script.

  4. Set discord webhook in webhooks.lua

  5. Set Config.OxInventory = false in es_extended/config.lua

  6. Set Config.EnableDefaultInventory = false in es_extended/config.lua

  7. Restart your server.

  8. You will see a message of installation complete. Then restart the server again.

Manual Installation: (optional)

By default, it will install the script automatically. If you see any error in server console you can try this manual installation.

  1. Install database.sql into your server database.

CREATE TABLE IF NOT EXISTS `ak47_inventory` (
  `identifier` varchar(46) NOT NULL,
  `data` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL CHECK (json_valid(`data`)),
  PRIMARY KEY (`identifier`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  1. Add necessary code below inside es_extended/server/classes/player.lua

  • Add this code inside CreateExtendedPlayer function.

function self.AddMethod(methodName, handler)
    self[methodName] = handler
end
  • Add this code after CreateExtendedPlayer function.

function ESX.AddPlayerMethod(id, methodName, handler)
    if not ESX.Players[id] then return end
    ESX.Players[id].AddMethod(methodName, handler)
end

function ESX.SetMethod(key, value)
    ESX[key] = value
end
  • After adding code, it will look like this

Notes:

  • Don't upload the script with FileZilla, Use Winscp if you are using FTP for file uploading.

  • Renaming of the script is not allowed.

  • We do not support custom frameworks, highly modified versions of ESX, or deprecated/outdated versions of anything.

Last updated