From 9df31039f31fe38678613145fe76459071fa1078 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 7 Feb 2024 03:15:46 +0000 Subject: [PATCH] deploy: c7e04bc4e8691a4861946f3d532774bad0da3fae --- 404.html | 2 +- .../_buildManifest.js | 2 +- .../_ssgManifest.js | 0 _next/static/chunks/nextra-data-en-US.json | 2 +- ...de507ff56a.js => _app-4dcd8df83df5d35d.js} | 2 +- .../chunks/pages/index-21258a1126bfd915.js | 1 - .../chunks/pages/index-4039efa6125bbe0e.js | 1 + .../Functions/Server-819101f5cf3f2301.js | 1 - .../Functions/Server-836e4f28c5115b3a.js | 1 + .../Client/radial-3799eaaf2507a3e8.js | 1 + .../Client/radial-52da50c399d3beff.js | 1 - .../Modules/Marker/Client-92ef0b2960245e93.js | 1 + .../Require/Shared-0151ce18c505673e.js | 1 + .../Require/Shared-6fd9540795b07659.js | 1 - guides/git.html | 4 +- guides/nodejs.html | 4 +- guides/pnpm.html | 4 +- guides/types.html | 4 +- guides/vscode.html | 4 +- index.html | 7 +- ox_core.html | 4 +- ox_core/Client/Player.html | 4 +- ox_core/Client/Player/callbacks.html | 4 +- ox_core/Client/Player/events.html | 4 +- ox_core/Client/functions.html | 4 +- ox_core/Server/Player.html | 4 +- ox_core/Server/Player/events.html | 4 +- ox_core/Server/Player/methods.html | 4 +- ox_core/Server/Vehicle.html | 4 +- ox_core/Server/Vehicle/callbacks.html | 4 +- ox_core/Server/Vehicle/methods.html | 4 +- ox_core/Server/functions.html | 4 +- ox_core/concepts.html | 4 +- ox_doorlock.html | 4 +- ox_doorlock/Client/functions.html | 4 +- ox_doorlock/Server/events.html | 4 +- ox_doorlock/Server/functions.html | 4 +- ox_doorlock/settings.html | 4 +- ox_fuel.html | 4 +- ox_fuel/Client/functions.html | 4 +- ox_fuel/Server/functions.html | 4 +- ox_fuel/Shared.html | 4 +- ox_inventory.html | 4 +- ox_inventory/Events/Client.html | 4 +- ox_inventory/Events/Server.html | 4 +- ox_inventory/Frameworks/esx.html | 4 +- ox_inventory/Frameworks/qb.html | 4 +- ox_inventory/Functions/Client.html | 4 +- ox_inventory/Functions/Server.html | 21 +- ox_inventory/Functions/Server/Hooks.html | 4 +- ox_inventory/Guides/crafting.html | 4 +- ox_inventory/Guides/creatingItems.html | 4 +- ox_inventory/Guides/metadata.html | 4 +- ox_inventory/Guides/shops.html | 4 +- ox_inventory/Guides/stashes.html | 4 +- ox_inventory/issues.html | 4 +- ox_lib.html | 4 +- ox_lib/Modules/ACL/Server.html | 4 +- ox_lib/Modules/AddCommand/Server.html | 4 +- ox_lib/Modules/AddKeybind/Client.html | 4 +- ox_lib/Modules/Cache/Client.html | 4 +- ox_lib/Modules/Cache/Shared.html | 4 +- .../Modules/Callback/JavaScript/Client.html | 4 +- .../Modules/Callback/JavaScript/Server.html | 4 +- ox_lib/Modules/Callback/Lua/Client.html | 4 +- ox_lib/Modules/Callback/Lua/Server.html | 4 +- ox_lib/Modules/Class/Shared.html | 4 +- ox_lib/Modules/Cron/Server.html | 4 +- ox_lib/Modules/DisableControls/Client.html | 4 +- ox_lib/Modules/GetClosestObject/Shared.html | 4 +- ox_lib/Modules/GetClosestPed/Shared.html | 4 +- ox_lib/Modules/GetClosestPlayer/Shared.html | 4 +- ox_lib/Modules/GetClosestVehicle/Shared.html | 4 +- ox_lib/Modules/GetNearbyObjects/Shared.html | 4 +- ox_lib/Modules/GetNearbyPeds/Shared.html | 4 +- ox_lib/Modules/GetNearbyPlayers/Shared.html | 4 +- ox_lib/Modules/GetNearbyVehicles/Shared.html | 4 +- ox_lib/Modules/Interface.html | 4 +- ox_lib/Modules/Interface/Client/alert.html | 4 +- .../Modules/Interface/Client/clipboard.html | 4 +- ox_lib/Modules/Interface/Client/context.html | 4 +- ox_lib/Modules/Interface/Client/input.html | 4 +- ox_lib/Modules/Interface/Client/menu.html | 4 +- ox_lib/Modules/Interface/Client/notify.html | 4 +- ox_lib/Modules/Interface/Client/progress.html | 4 +- ox_lib/Modules/Interface/Client/radial.html | 16 +- .../Modules/Interface/Client/skillcheck.html | 4 +- ox_lib/Modules/Interface/Client/textui.html | 4 +- ox_lib/Modules/Locale/Shared.html | 4 +- ox_lib/Modules/Logger/Server.html | 4 +- ox_lib/Modules/Marker/Client.html | 80 +++++++ ox_lib/Modules/Math/Shared.html | 4 +- ox_lib/Modules/Points/JavaScript/Client.html | 4 +- ox_lib/Modules/Points/Lua/Client.html | 4 +- ox_lib/Modules/Print/Shared.html | 4 +- ox_lib/Modules/Raycast/Client.html | 4 +- ox_lib/Modules/Require/Shared.html | 11 +- ox_lib/Modules/Streaming/Client.html | 4 +- ox_lib/Modules/String/Shared.html | 4 +- ox_lib/Modules/Table/Shared.html | 4 +- ox_lib/Modules/VehicleProperties/Client.html | 4 +- ox_lib/Modules/Version/Server.html | 4 +- ox_lib/Modules/Version/Shared.html | 4 +- ox_lib/Modules/WaitFor/Shared.html | 4 +- ox_lib/Modules/Zones/Shared.html | 4 +- ox_target.html | 4 +- ox_target/Functions/Client.html | 4 +- ox_target/Options.html | 4 +- oxmysql.html | 4 +- oxmysql/Functions/insert.html | 4 +- oxmysql/Functions/prepare.html | 4 +- oxmysql/Functions/query.html | 4 +- oxmysql/Functions/rawExecute.html | 4 +- oxmysql/Functions/scalar.html | 4 +- oxmysql/Functions/single.html | 4 +- oxmysql/Functions/transaction.html | 4 +- oxmysql/Functions/update.html | 4 +- oxmysql/benchmark.html | 4 +- oxmysql/issues.html | 4 +- oxmysql/placeholders.html | 4 +- oxmysql/ui.html | 4 +- sitemap.xml | 213 +++++++++--------- 122 files changed, 433 insertions(+), 340 deletions(-) rename _next/static/{TSLysL5tuuYDS43lr00Ap => aUInr-KvE0IfkGlGJtYb5}/_buildManifest.js (54%) rename _next/static/{TSLysL5tuuYDS43lr00Ap => aUInr-KvE0IfkGlGJtYb5}/_ssgManifest.js (100%) rename _next/static/chunks/pages/{_app-14425ade507ff56a.js => _app-4dcd8df83df5d35d.js} (76%) delete mode 100644 _next/static/chunks/pages/index-21258a1126bfd915.js create mode 100644 _next/static/chunks/pages/index-4039efa6125bbe0e.js delete mode 100644 _next/static/chunks/pages/ox_inventory/Functions/Server-819101f5cf3f2301.js create mode 100644 _next/static/chunks/pages/ox_inventory/Functions/Server-836e4f28c5115b3a.js create mode 100644 _next/static/chunks/pages/ox_lib/Modules/Interface/Client/radial-3799eaaf2507a3e8.js delete mode 100644 _next/static/chunks/pages/ox_lib/Modules/Interface/Client/radial-52da50c399d3beff.js create mode 100644 _next/static/chunks/pages/ox_lib/Modules/Marker/Client-92ef0b2960245e93.js create mode 100644 _next/static/chunks/pages/ox_lib/Modules/Require/Shared-0151ce18c505673e.js delete mode 100644 _next/static/chunks/pages/ox_lib/Modules/Require/Shared-6fd9540795b07659.js create mode 100644 ox_lib/Modules/Marker/Client.html diff --git a/404.html b/404.html index 89dc0b76be..5ab741f648 100644 --- a/404.html +++ b/404.html @@ -1 +1 @@ -

404

Redirecting...

\ No newline at end of file +

404

Redirecting...

\ No newline at end of file diff --git a/_next/static/TSLysL5tuuYDS43lr00Ap/_buildManifest.js b/_next/static/aUInr-KvE0IfkGlGJtYb5/_buildManifest.js similarity index 54% rename from _next/static/TSLysL5tuuYDS43lr00Ap/_buildManifest.js rename to _next/static/aUInr-KvE0IfkGlGJtYb5/_buildManifest.js index 1038221a70..5f504aca19 100644 --- a/_next/static/TSLysL5tuuYDS43lr00Ap/_buildManifest.js +++ b/_next/static/aUInr-KvE0IfkGlGJtYb5/_buildManifest.js @@ -1 +1 @@ -self.__BUILD_MANIFEST=function(e){return{__rewrites:{afterFiles:[],beforeFiles:[],fallback:[]},"/":[e,"static/chunks/pages/index-21258a1126bfd915.js"],"/404":["static/chunks/pages/404-d31671b33f52e827.js"],"/_error":["static/chunks/pages/_error-2279e6cb9ef84b6a.js"],"/guides/git":[e,"static/chunks/pages/guides/git-1736491deaebc3a0.js"],"/guides/nodejs":[e,"static/chunks/pages/guides/nodejs-0e3d40d03b458c96.js"],"/guides/pnpm":[e,"static/chunks/pages/guides/pnpm-56fbaca819a4ce52.js"],"/guides/types":[e,"static/chunks/pages/guides/types-f8827f56cbbd888d.js"],"/guides/vscode":[e,"static/chunks/pages/guides/vscode-974adf8b1a5d0f3c.js"],"/ox_core":[e,"static/chunks/pages/ox_core-8df6f3346002542d.js"],"/ox_core/Client/Player":[e,"static/chunks/pages/ox_core/Client/Player-b3006715713158ea.js"],"/ox_core/Client/Player/callbacks":[e,"static/chunks/pages/ox_core/Client/Player/callbacks-ff4918762336b7e5.js"],"/ox_core/Client/Player/events":[e,"static/chunks/pages/ox_core/Client/Player/events-20c2084060045285.js"],"/ox_core/Client/functions":[e,"static/chunks/pages/ox_core/Client/functions-dd77fe2d95dea0c0.js"],"/ox_core/Server/Player":[e,"static/chunks/pages/ox_core/Server/Player-8a9c8a47d55c3bda.js"],"/ox_core/Server/Player/events":[e,"static/chunks/pages/ox_core/Server/Player/events-0bfe9eea0576a3e8.js"],"/ox_core/Server/Player/methods":[e,"static/chunks/pages/ox_core/Server/Player/methods-5959115939eb96ca.js"],"/ox_core/Server/Vehicle":[e,"static/chunks/pages/ox_core/Server/Vehicle-9cad5ee5f9ed757f.js"],"/ox_core/Server/Vehicle/callbacks":[e,"static/chunks/pages/ox_core/Server/Vehicle/callbacks-1da2bf06caa397ae.js"],"/ox_core/Server/Vehicle/methods":[e,"static/chunks/pages/ox_core/Server/Vehicle/methods-fe72b7d714bb15c4.js"],"/ox_core/Server/functions":[e,"static/chunks/pages/ox_core/Server/functions-32dbeb72594eeee1.js"],"/ox_core/concepts":[e,"static/chunks/pages/ox_core/concepts-f5dbaa1d8dcb5fe9.js"],"/ox_doorlock":[e,"static/chunks/pages/ox_doorlock-cccb2f247358df26.js"],"/ox_doorlock/Client/functions":[e,"static/chunks/pages/ox_doorlock/Client/functions-3a7f03e7fc3f349c.js"],"/ox_doorlock/Server/events":[e,"static/chunks/pages/ox_doorlock/Server/events-8bfaf4fa839157fd.js"],"/ox_doorlock/Server/functions":[e,"static/chunks/pages/ox_doorlock/Server/functions-e6ec8e74e8131b41.js"],"/ox_doorlock/settings":[e,"static/chunks/pages/ox_doorlock/settings-cb218c44b0b48fa2.js"],"/ox_fuel":[e,"static/chunks/pages/ox_fuel-b9d0c9af470eda98.js"],"/ox_fuel/Client/functions":[e,"static/chunks/pages/ox_fuel/Client/functions-80fcb783356e6ff6.js"],"/ox_fuel/Server/functions":[e,"static/chunks/pages/ox_fuel/Server/functions-bf30ef7a9f557a09.js"],"/ox_fuel/Shared":[e,"static/chunks/pages/ox_fuel/Shared-6dec5fb18f4cfb7d.js"],"/ox_inventory":[e,"static/chunks/pages/ox_inventory-8a7c2c0a6c5e3f61.js"],"/ox_inventory/Events/Client":[e,"static/chunks/pages/ox_inventory/Events/Client-441b1dba62b27f48.js"],"/ox_inventory/Events/Server":[e,"static/chunks/pages/ox_inventory/Events/Server-424e2ced90473dc1.js"],"/ox_inventory/Frameworks/esx":[e,"static/chunks/pages/ox_inventory/Frameworks/esx-2745742e7e54732b.js"],"/ox_inventory/Frameworks/qb":[e,"static/chunks/pages/ox_inventory/Frameworks/qb-540367fc4e2a158b.js"],"/ox_inventory/Functions/Client":[e,"static/chunks/pages/ox_inventory/Functions/Client-4304dedfff02dfc9.js"],"/ox_inventory/Functions/Server":[e,"static/chunks/pages/ox_inventory/Functions/Server-819101f5cf3f2301.js"],"/ox_inventory/Functions/Server/Hooks":[e,"static/chunks/pages/ox_inventory/Functions/Server/Hooks-9fc0d88facce7e46.js"],"/ox_inventory/Guides/crafting":[e,"static/chunks/pages/ox_inventory/Guides/crafting-c57e9e51b90edec3.js"],"/ox_inventory/Guides/creatingItems":[e,"static/chunks/pages/ox_inventory/Guides/creatingItems-62f38372ba682463.js"],"/ox_inventory/Guides/metadata":[e,"static/chunks/pages/ox_inventory/Guides/metadata-c520f846abe2b7ef.js"],"/ox_inventory/Guides/shops":[e,"static/chunks/pages/ox_inventory/Guides/shops-0e798e995ba21ae3.js"],"/ox_inventory/Guides/stashes":[e,"static/chunks/pages/ox_inventory/Guides/stashes-3211176f3973002d.js"],"/ox_inventory/issues":[e,"static/chunks/pages/ox_inventory/issues-7fada16f46dabdc4.js"],"/ox_lib":[e,"static/chunks/pages/ox_lib-fdfea56f8d4c7587.js"],"/ox_lib/Modules/ACL/Server":[e,"static/chunks/pages/ox_lib/Modules/ACL/Server-ee3aaa3e689040a0.js"],"/ox_lib/Modules/AddCommand/Server":[e,"static/chunks/pages/ox_lib/Modules/AddCommand/Server-102c11c52819c84d.js"],"/ox_lib/Modules/AddKeybind/Client":[e,"static/chunks/pages/ox_lib/Modules/AddKeybind/Client-95b02130c2570314.js"],"/ox_lib/Modules/Cache/Client":[e,"static/chunks/pages/ox_lib/Modules/Cache/Client-5d30c12c78c7d1fb.js"],"/ox_lib/Modules/Cache/Shared":[e,"static/chunks/pages/ox_lib/Modules/Cache/Shared-8e4f35acaaf1af24.js"],"/ox_lib/Modules/Callback/JavaScript/Client":[e,"static/chunks/pages/ox_lib/Modules/Callback/JavaScript/Client-13e93c6835fe9899.js"],"/ox_lib/Modules/Callback/JavaScript/Server":[e,"static/chunks/pages/ox_lib/Modules/Callback/JavaScript/Server-fe675fa8db0b6ed6.js"],"/ox_lib/Modules/Callback/Lua/Client":[e,"static/chunks/pages/ox_lib/Modules/Callback/Lua/Client-0e763159b9ac992e.js"],"/ox_lib/Modules/Callback/Lua/Server":[e,"static/chunks/pages/ox_lib/Modules/Callback/Lua/Server-b4f3fb556c951db5.js"],"/ox_lib/Modules/Class/Shared":[e,"static/chunks/pages/ox_lib/Modules/Class/Shared-9a72e6d6c0b6c6cc.js"],"/ox_lib/Modules/Cron/Server":[e,"static/chunks/pages/ox_lib/Modules/Cron/Server-36ba208057b937be.js"],"/ox_lib/Modules/DisableControls/Client":[e,"static/chunks/pages/ox_lib/Modules/DisableControls/Client-b9d4cb3b8cfbc479.js"],"/ox_lib/Modules/GetClosestObject/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetClosestObject/Shared-e6495c1370074318.js"],"/ox_lib/Modules/GetClosestPed/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetClosestPed/Shared-2ec0472e6cfe62c9.js"],"/ox_lib/Modules/GetClosestPlayer/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetClosestPlayer/Shared-d1581c69d677d4ed.js"],"/ox_lib/Modules/GetClosestVehicle/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetClosestVehicle/Shared-1a9d887d67a28b50.js"],"/ox_lib/Modules/GetNearbyObjects/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetNearbyObjects/Shared-88cfcf8df4661634.js"],"/ox_lib/Modules/GetNearbyPeds/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetNearbyPeds/Shared-555a6494ad85c931.js"],"/ox_lib/Modules/GetNearbyPlayers/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetNearbyPlayers/Shared-bb518d465352158d.js"],"/ox_lib/Modules/GetNearbyVehicles/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetNearbyVehicles/Shared-123eb1170b638be5.js"],"/ox_lib/Modules/Interface":[e,"static/chunks/pages/ox_lib/Modules/Interface-49ecd5e1720e5b9e.js"],"/ox_lib/Modules/Interface/Client/alert":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/alert-d26d4e5fadd7ff9a.js"],"/ox_lib/Modules/Interface/Client/clipboard":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/clipboard-f7bb4ac1ca2f607d.js"],"/ox_lib/Modules/Interface/Client/context":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/context-07e6254c6a94e876.js"],"/ox_lib/Modules/Interface/Client/input":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/input-24fc4dd05d45bd95.js"],"/ox_lib/Modules/Interface/Client/menu":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/menu-a96d02f040f758f2.js"],"/ox_lib/Modules/Interface/Client/notify":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/notify-9c214b90b7f7c5fa.js"],"/ox_lib/Modules/Interface/Client/progress":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/progress-8cf2229d8652dcdf.js"],"/ox_lib/Modules/Interface/Client/radial":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/radial-52da50c399d3beff.js"],"/ox_lib/Modules/Interface/Client/skillcheck":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/skillcheck-dbbccd202d35c621.js"],"/ox_lib/Modules/Interface/Client/textui":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/textui-db9ea38083e35cbf.js"],"/ox_lib/Modules/Locale/Shared":[e,"static/chunks/pages/ox_lib/Modules/Locale/Shared-06ecac76d932ef0c.js"],"/ox_lib/Modules/Logger/Server":[e,"static/chunks/pages/ox_lib/Modules/Logger/Server-0f9aa724a221dd8a.js"],"/ox_lib/Modules/Math/Shared":[e,"static/chunks/pages/ox_lib/Modules/Math/Shared-de154544900aa4e8.js"],"/ox_lib/Modules/Points/JavaScript/Client":[e,"static/chunks/pages/ox_lib/Modules/Points/JavaScript/Client-56f6c81965f48d6c.js"],"/ox_lib/Modules/Points/Lua/Client":[e,"static/chunks/pages/ox_lib/Modules/Points/Lua/Client-27b9931b7ef6e6d1.js"],"/ox_lib/Modules/Print/Shared":[e,"static/chunks/pages/ox_lib/Modules/Print/Shared-c48cd186c778682d.js"],"/ox_lib/Modules/Raycast/Client":[e,"static/chunks/pages/ox_lib/Modules/Raycast/Client-a1428293fc26bd8d.js"],"/ox_lib/Modules/Require/Shared":[e,"static/chunks/pages/ox_lib/Modules/Require/Shared-6fd9540795b07659.js"],"/ox_lib/Modules/Streaming/Client":[e,"static/chunks/pages/ox_lib/Modules/Streaming/Client-45e6dfbc6a5d0797.js"],"/ox_lib/Modules/String/Shared":[e,"static/chunks/pages/ox_lib/Modules/String/Shared-513338301ba9df67.js"],"/ox_lib/Modules/Table/Shared":[e,"static/chunks/pages/ox_lib/Modules/Table/Shared-9d3b26ffde2da9c8.js"],"/ox_lib/Modules/VehicleProperties/Client":[e,"static/chunks/pages/ox_lib/Modules/VehicleProperties/Client-23e18c1942998e2a.js"],"/ox_lib/Modules/Version/Server":[e,"static/chunks/pages/ox_lib/Modules/Version/Server-0a40f7184c9226f3.js"],"/ox_lib/Modules/Version/Shared":[e,"static/chunks/pages/ox_lib/Modules/Version/Shared-71540cd70cf87ee2.js"],"/ox_lib/Modules/WaitFor/Shared":[e,"static/chunks/pages/ox_lib/Modules/WaitFor/Shared-66b19e6fc930df43.js"],"/ox_lib/Modules/Zones/Shared":[e,"static/chunks/pages/ox_lib/Modules/Zones/Shared-8511bc5317576d47.js"],"/ox_target":[e,"static/chunks/pages/ox_target-466666fb6f4ac8cf.js"],"/ox_target/Functions/Client":[e,"static/chunks/pages/ox_target/Functions/Client-cb27c0b4551e51a6.js"],"/ox_target/Options":[e,"static/chunks/pages/ox_target/Options-385be0489e9fb27c.js"],"/oxmysql":[e,"static/chunks/pages/oxmysql-8b4466739ce863d4.js"],"/oxmysql/Functions/insert":[e,"static/chunks/pages/oxmysql/Functions/insert-24b2474d0cdad50e.js"],"/oxmysql/Functions/prepare":[e,"static/chunks/pages/oxmysql/Functions/prepare-0d3b6567649b576f.js"],"/oxmysql/Functions/query":[e,"static/chunks/pages/oxmysql/Functions/query-0b398e948e5dc310.js"],"/oxmysql/Functions/rawExecute":[e,"static/chunks/pages/oxmysql/Functions/rawExecute-1be90f88656f2c8a.js"],"/oxmysql/Functions/scalar":[e,"static/chunks/pages/oxmysql/Functions/scalar-c85b4821da62a974.js"],"/oxmysql/Functions/single":[e,"static/chunks/pages/oxmysql/Functions/single-9c2e1584741a1a2c.js"],"/oxmysql/Functions/transaction":[e,"static/chunks/pages/oxmysql/Functions/transaction-02875a32110e4e54.js"],"/oxmysql/Functions/update":[e,"static/chunks/pages/oxmysql/Functions/update-ccb153d09e2ed269.js"],"/oxmysql/benchmark":[e,"static/chunks/pages/oxmysql/benchmark-d00c2db0c32d6fa5.js"],"/oxmysql/issues":[e,"static/chunks/pages/oxmysql/issues-155bdb285d1219b1.js"],"/oxmysql/placeholders":[e,"static/chunks/pages/oxmysql/placeholders-e9dd98b0e42e906e.js"],"/oxmysql/ui":[e,"static/chunks/pages/oxmysql/ui-26e43c146f6278ab.js"],sortedPages:["/","/404","/_app","/_error","/guides/git","/guides/nodejs","/guides/pnpm","/guides/types","/guides/vscode","/ox_core","/ox_core/Client/Player","/ox_core/Client/Player/callbacks","/ox_core/Client/Player/events","/ox_core/Client/functions","/ox_core/Server/Player","/ox_core/Server/Player/events","/ox_core/Server/Player/methods","/ox_core/Server/Vehicle","/ox_core/Server/Vehicle/callbacks","/ox_core/Server/Vehicle/methods","/ox_core/Server/functions","/ox_core/concepts","/ox_doorlock","/ox_doorlock/Client/functions","/ox_doorlock/Server/events","/ox_doorlock/Server/functions","/ox_doorlock/settings","/ox_fuel","/ox_fuel/Client/functions","/ox_fuel/Server/functions","/ox_fuel/Shared","/ox_inventory","/ox_inventory/Events/Client","/ox_inventory/Events/Server","/ox_inventory/Frameworks/esx","/ox_inventory/Frameworks/qb","/ox_inventory/Functions/Client","/ox_inventory/Functions/Server","/ox_inventory/Functions/Server/Hooks","/ox_inventory/Guides/crafting","/ox_inventory/Guides/creatingItems","/ox_inventory/Guides/metadata","/ox_inventory/Guides/shops","/ox_inventory/Guides/stashes","/ox_inventory/issues","/ox_lib","/ox_lib/Modules/ACL/Server","/ox_lib/Modules/AddCommand/Server","/ox_lib/Modules/AddKeybind/Client","/ox_lib/Modules/Cache/Client","/ox_lib/Modules/Cache/Shared","/ox_lib/Modules/Callback/JavaScript/Client","/ox_lib/Modules/Callback/JavaScript/Server","/ox_lib/Modules/Callback/Lua/Client","/ox_lib/Modules/Callback/Lua/Server","/ox_lib/Modules/Class/Shared","/ox_lib/Modules/Cron/Server","/ox_lib/Modules/DisableControls/Client","/ox_lib/Modules/GetClosestObject/Shared","/ox_lib/Modules/GetClosestPed/Shared","/ox_lib/Modules/GetClosestPlayer/Shared","/ox_lib/Modules/GetClosestVehicle/Shared","/ox_lib/Modules/GetNearbyObjects/Shared","/ox_lib/Modules/GetNearbyPeds/Shared","/ox_lib/Modules/GetNearbyPlayers/Shared","/ox_lib/Modules/GetNearbyVehicles/Shared","/ox_lib/Modules/Interface","/ox_lib/Modules/Interface/Client/alert","/ox_lib/Modules/Interface/Client/clipboard","/ox_lib/Modules/Interface/Client/context","/ox_lib/Modules/Interface/Client/input","/ox_lib/Modules/Interface/Client/menu","/ox_lib/Modules/Interface/Client/notify","/ox_lib/Modules/Interface/Client/progress","/ox_lib/Modules/Interface/Client/radial","/ox_lib/Modules/Interface/Client/skillcheck","/ox_lib/Modules/Interface/Client/textui","/ox_lib/Modules/Locale/Shared","/ox_lib/Modules/Logger/Server","/ox_lib/Modules/Math/Shared","/ox_lib/Modules/Points/JavaScript/Client","/ox_lib/Modules/Points/Lua/Client","/ox_lib/Modules/Print/Shared","/ox_lib/Modules/Raycast/Client","/ox_lib/Modules/Require/Shared","/ox_lib/Modules/Streaming/Client","/ox_lib/Modules/String/Shared","/ox_lib/Modules/Table/Shared","/ox_lib/Modules/VehicleProperties/Client","/ox_lib/Modules/Version/Server","/ox_lib/Modules/Version/Shared","/ox_lib/Modules/WaitFor/Shared","/ox_lib/Modules/Zones/Shared","/ox_target","/ox_target/Functions/Client","/ox_target/Options","/oxmysql","/oxmysql/Functions/insert","/oxmysql/Functions/prepare","/oxmysql/Functions/query","/oxmysql/Functions/rawExecute","/oxmysql/Functions/scalar","/oxmysql/Functions/single","/oxmysql/Functions/transaction","/oxmysql/Functions/update","/oxmysql/benchmark","/oxmysql/issues","/oxmysql/placeholders","/oxmysql/ui"]}}("static/chunks/2059-ce0716acefc68b4d.js"),self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB(); \ No newline at end of file +self.__BUILD_MANIFEST=function(e){return{__rewrites:{afterFiles:[],beforeFiles:[],fallback:[]},"/":[e,"static/chunks/pages/index-4039efa6125bbe0e.js"],"/404":["static/chunks/pages/404-d31671b33f52e827.js"],"/_error":["static/chunks/pages/_error-2279e6cb9ef84b6a.js"],"/guides/git":[e,"static/chunks/pages/guides/git-1736491deaebc3a0.js"],"/guides/nodejs":[e,"static/chunks/pages/guides/nodejs-0e3d40d03b458c96.js"],"/guides/pnpm":[e,"static/chunks/pages/guides/pnpm-56fbaca819a4ce52.js"],"/guides/types":[e,"static/chunks/pages/guides/types-f8827f56cbbd888d.js"],"/guides/vscode":[e,"static/chunks/pages/guides/vscode-974adf8b1a5d0f3c.js"],"/ox_core":[e,"static/chunks/pages/ox_core-8df6f3346002542d.js"],"/ox_core/Client/Player":[e,"static/chunks/pages/ox_core/Client/Player-b3006715713158ea.js"],"/ox_core/Client/Player/callbacks":[e,"static/chunks/pages/ox_core/Client/Player/callbacks-ff4918762336b7e5.js"],"/ox_core/Client/Player/events":[e,"static/chunks/pages/ox_core/Client/Player/events-20c2084060045285.js"],"/ox_core/Client/functions":[e,"static/chunks/pages/ox_core/Client/functions-dd77fe2d95dea0c0.js"],"/ox_core/Server/Player":[e,"static/chunks/pages/ox_core/Server/Player-8a9c8a47d55c3bda.js"],"/ox_core/Server/Player/events":[e,"static/chunks/pages/ox_core/Server/Player/events-0bfe9eea0576a3e8.js"],"/ox_core/Server/Player/methods":[e,"static/chunks/pages/ox_core/Server/Player/methods-5959115939eb96ca.js"],"/ox_core/Server/Vehicle":[e,"static/chunks/pages/ox_core/Server/Vehicle-9cad5ee5f9ed757f.js"],"/ox_core/Server/Vehicle/callbacks":[e,"static/chunks/pages/ox_core/Server/Vehicle/callbacks-1da2bf06caa397ae.js"],"/ox_core/Server/Vehicle/methods":[e,"static/chunks/pages/ox_core/Server/Vehicle/methods-fe72b7d714bb15c4.js"],"/ox_core/Server/functions":[e,"static/chunks/pages/ox_core/Server/functions-32dbeb72594eeee1.js"],"/ox_core/concepts":[e,"static/chunks/pages/ox_core/concepts-f5dbaa1d8dcb5fe9.js"],"/ox_doorlock":[e,"static/chunks/pages/ox_doorlock-cccb2f247358df26.js"],"/ox_doorlock/Client/functions":[e,"static/chunks/pages/ox_doorlock/Client/functions-3a7f03e7fc3f349c.js"],"/ox_doorlock/Server/events":[e,"static/chunks/pages/ox_doorlock/Server/events-8bfaf4fa839157fd.js"],"/ox_doorlock/Server/functions":[e,"static/chunks/pages/ox_doorlock/Server/functions-e6ec8e74e8131b41.js"],"/ox_doorlock/settings":[e,"static/chunks/pages/ox_doorlock/settings-cb218c44b0b48fa2.js"],"/ox_fuel":[e,"static/chunks/pages/ox_fuel-b9d0c9af470eda98.js"],"/ox_fuel/Client/functions":[e,"static/chunks/pages/ox_fuel/Client/functions-80fcb783356e6ff6.js"],"/ox_fuel/Server/functions":[e,"static/chunks/pages/ox_fuel/Server/functions-bf30ef7a9f557a09.js"],"/ox_fuel/Shared":[e,"static/chunks/pages/ox_fuel/Shared-6dec5fb18f4cfb7d.js"],"/ox_inventory":[e,"static/chunks/pages/ox_inventory-8a7c2c0a6c5e3f61.js"],"/ox_inventory/Events/Client":[e,"static/chunks/pages/ox_inventory/Events/Client-441b1dba62b27f48.js"],"/ox_inventory/Events/Server":[e,"static/chunks/pages/ox_inventory/Events/Server-424e2ced90473dc1.js"],"/ox_inventory/Frameworks/esx":[e,"static/chunks/pages/ox_inventory/Frameworks/esx-2745742e7e54732b.js"],"/ox_inventory/Frameworks/qb":[e,"static/chunks/pages/ox_inventory/Frameworks/qb-540367fc4e2a158b.js"],"/ox_inventory/Functions/Client":[e,"static/chunks/pages/ox_inventory/Functions/Client-4304dedfff02dfc9.js"],"/ox_inventory/Functions/Server":[e,"static/chunks/pages/ox_inventory/Functions/Server-836e4f28c5115b3a.js"],"/ox_inventory/Functions/Server/Hooks":[e,"static/chunks/pages/ox_inventory/Functions/Server/Hooks-9fc0d88facce7e46.js"],"/ox_inventory/Guides/crafting":[e,"static/chunks/pages/ox_inventory/Guides/crafting-c57e9e51b90edec3.js"],"/ox_inventory/Guides/creatingItems":[e,"static/chunks/pages/ox_inventory/Guides/creatingItems-62f38372ba682463.js"],"/ox_inventory/Guides/metadata":[e,"static/chunks/pages/ox_inventory/Guides/metadata-c520f846abe2b7ef.js"],"/ox_inventory/Guides/shops":[e,"static/chunks/pages/ox_inventory/Guides/shops-0e798e995ba21ae3.js"],"/ox_inventory/Guides/stashes":[e,"static/chunks/pages/ox_inventory/Guides/stashes-3211176f3973002d.js"],"/ox_inventory/issues":[e,"static/chunks/pages/ox_inventory/issues-7fada16f46dabdc4.js"],"/ox_lib":[e,"static/chunks/pages/ox_lib-fdfea56f8d4c7587.js"],"/ox_lib/Modules/ACL/Server":[e,"static/chunks/pages/ox_lib/Modules/ACL/Server-ee3aaa3e689040a0.js"],"/ox_lib/Modules/AddCommand/Server":[e,"static/chunks/pages/ox_lib/Modules/AddCommand/Server-102c11c52819c84d.js"],"/ox_lib/Modules/AddKeybind/Client":[e,"static/chunks/pages/ox_lib/Modules/AddKeybind/Client-95b02130c2570314.js"],"/ox_lib/Modules/Cache/Client":[e,"static/chunks/pages/ox_lib/Modules/Cache/Client-5d30c12c78c7d1fb.js"],"/ox_lib/Modules/Cache/Shared":[e,"static/chunks/pages/ox_lib/Modules/Cache/Shared-8e4f35acaaf1af24.js"],"/ox_lib/Modules/Callback/JavaScript/Client":[e,"static/chunks/pages/ox_lib/Modules/Callback/JavaScript/Client-13e93c6835fe9899.js"],"/ox_lib/Modules/Callback/JavaScript/Server":[e,"static/chunks/pages/ox_lib/Modules/Callback/JavaScript/Server-fe675fa8db0b6ed6.js"],"/ox_lib/Modules/Callback/Lua/Client":[e,"static/chunks/pages/ox_lib/Modules/Callback/Lua/Client-0e763159b9ac992e.js"],"/ox_lib/Modules/Callback/Lua/Server":[e,"static/chunks/pages/ox_lib/Modules/Callback/Lua/Server-b4f3fb556c951db5.js"],"/ox_lib/Modules/Class/Shared":[e,"static/chunks/pages/ox_lib/Modules/Class/Shared-9a72e6d6c0b6c6cc.js"],"/ox_lib/Modules/Cron/Server":[e,"static/chunks/pages/ox_lib/Modules/Cron/Server-36ba208057b937be.js"],"/ox_lib/Modules/DisableControls/Client":[e,"static/chunks/pages/ox_lib/Modules/DisableControls/Client-b9d4cb3b8cfbc479.js"],"/ox_lib/Modules/GetClosestObject/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetClosestObject/Shared-e6495c1370074318.js"],"/ox_lib/Modules/GetClosestPed/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetClosestPed/Shared-2ec0472e6cfe62c9.js"],"/ox_lib/Modules/GetClosestPlayer/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetClosestPlayer/Shared-d1581c69d677d4ed.js"],"/ox_lib/Modules/GetClosestVehicle/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetClosestVehicle/Shared-1a9d887d67a28b50.js"],"/ox_lib/Modules/GetNearbyObjects/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetNearbyObjects/Shared-88cfcf8df4661634.js"],"/ox_lib/Modules/GetNearbyPeds/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetNearbyPeds/Shared-555a6494ad85c931.js"],"/ox_lib/Modules/GetNearbyPlayers/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetNearbyPlayers/Shared-bb518d465352158d.js"],"/ox_lib/Modules/GetNearbyVehicles/Shared":[e,"static/chunks/pages/ox_lib/Modules/GetNearbyVehicles/Shared-123eb1170b638be5.js"],"/ox_lib/Modules/Interface":[e,"static/chunks/pages/ox_lib/Modules/Interface-49ecd5e1720e5b9e.js"],"/ox_lib/Modules/Interface/Client/alert":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/alert-d26d4e5fadd7ff9a.js"],"/ox_lib/Modules/Interface/Client/clipboard":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/clipboard-f7bb4ac1ca2f607d.js"],"/ox_lib/Modules/Interface/Client/context":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/context-07e6254c6a94e876.js"],"/ox_lib/Modules/Interface/Client/input":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/input-24fc4dd05d45bd95.js"],"/ox_lib/Modules/Interface/Client/menu":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/menu-a96d02f040f758f2.js"],"/ox_lib/Modules/Interface/Client/notify":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/notify-9c214b90b7f7c5fa.js"],"/ox_lib/Modules/Interface/Client/progress":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/progress-8cf2229d8652dcdf.js"],"/ox_lib/Modules/Interface/Client/radial":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/radial-3799eaaf2507a3e8.js"],"/ox_lib/Modules/Interface/Client/skillcheck":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/skillcheck-dbbccd202d35c621.js"],"/ox_lib/Modules/Interface/Client/textui":[e,"static/chunks/pages/ox_lib/Modules/Interface/Client/textui-db9ea38083e35cbf.js"],"/ox_lib/Modules/Locale/Shared":[e,"static/chunks/pages/ox_lib/Modules/Locale/Shared-06ecac76d932ef0c.js"],"/ox_lib/Modules/Logger/Server":[e,"static/chunks/pages/ox_lib/Modules/Logger/Server-0f9aa724a221dd8a.js"],"/ox_lib/Modules/Marker/Client":[e,"static/chunks/pages/ox_lib/Modules/Marker/Client-92ef0b2960245e93.js"],"/ox_lib/Modules/Math/Shared":[e,"static/chunks/pages/ox_lib/Modules/Math/Shared-de154544900aa4e8.js"],"/ox_lib/Modules/Points/JavaScript/Client":[e,"static/chunks/pages/ox_lib/Modules/Points/JavaScript/Client-56f6c81965f48d6c.js"],"/ox_lib/Modules/Points/Lua/Client":[e,"static/chunks/pages/ox_lib/Modules/Points/Lua/Client-27b9931b7ef6e6d1.js"],"/ox_lib/Modules/Print/Shared":[e,"static/chunks/pages/ox_lib/Modules/Print/Shared-c48cd186c778682d.js"],"/ox_lib/Modules/Raycast/Client":[e,"static/chunks/pages/ox_lib/Modules/Raycast/Client-a1428293fc26bd8d.js"],"/ox_lib/Modules/Require/Shared":[e,"static/chunks/pages/ox_lib/Modules/Require/Shared-0151ce18c505673e.js"],"/ox_lib/Modules/Streaming/Client":[e,"static/chunks/pages/ox_lib/Modules/Streaming/Client-45e6dfbc6a5d0797.js"],"/ox_lib/Modules/String/Shared":[e,"static/chunks/pages/ox_lib/Modules/String/Shared-513338301ba9df67.js"],"/ox_lib/Modules/Table/Shared":[e,"static/chunks/pages/ox_lib/Modules/Table/Shared-9d3b26ffde2da9c8.js"],"/ox_lib/Modules/VehicleProperties/Client":[e,"static/chunks/pages/ox_lib/Modules/VehicleProperties/Client-23e18c1942998e2a.js"],"/ox_lib/Modules/Version/Server":[e,"static/chunks/pages/ox_lib/Modules/Version/Server-0a40f7184c9226f3.js"],"/ox_lib/Modules/Version/Shared":[e,"static/chunks/pages/ox_lib/Modules/Version/Shared-71540cd70cf87ee2.js"],"/ox_lib/Modules/WaitFor/Shared":[e,"static/chunks/pages/ox_lib/Modules/WaitFor/Shared-66b19e6fc930df43.js"],"/ox_lib/Modules/Zones/Shared":[e,"static/chunks/pages/ox_lib/Modules/Zones/Shared-8511bc5317576d47.js"],"/ox_target":[e,"static/chunks/pages/ox_target-466666fb6f4ac8cf.js"],"/ox_target/Functions/Client":[e,"static/chunks/pages/ox_target/Functions/Client-cb27c0b4551e51a6.js"],"/ox_target/Options":[e,"static/chunks/pages/ox_target/Options-385be0489e9fb27c.js"],"/oxmysql":[e,"static/chunks/pages/oxmysql-8b4466739ce863d4.js"],"/oxmysql/Functions/insert":[e,"static/chunks/pages/oxmysql/Functions/insert-24b2474d0cdad50e.js"],"/oxmysql/Functions/prepare":[e,"static/chunks/pages/oxmysql/Functions/prepare-0d3b6567649b576f.js"],"/oxmysql/Functions/query":[e,"static/chunks/pages/oxmysql/Functions/query-0b398e948e5dc310.js"],"/oxmysql/Functions/rawExecute":[e,"static/chunks/pages/oxmysql/Functions/rawExecute-1be90f88656f2c8a.js"],"/oxmysql/Functions/scalar":[e,"static/chunks/pages/oxmysql/Functions/scalar-c85b4821da62a974.js"],"/oxmysql/Functions/single":[e,"static/chunks/pages/oxmysql/Functions/single-9c2e1584741a1a2c.js"],"/oxmysql/Functions/transaction":[e,"static/chunks/pages/oxmysql/Functions/transaction-02875a32110e4e54.js"],"/oxmysql/Functions/update":[e,"static/chunks/pages/oxmysql/Functions/update-ccb153d09e2ed269.js"],"/oxmysql/benchmark":[e,"static/chunks/pages/oxmysql/benchmark-d00c2db0c32d6fa5.js"],"/oxmysql/issues":[e,"static/chunks/pages/oxmysql/issues-155bdb285d1219b1.js"],"/oxmysql/placeholders":[e,"static/chunks/pages/oxmysql/placeholders-e9dd98b0e42e906e.js"],"/oxmysql/ui":[e,"static/chunks/pages/oxmysql/ui-26e43c146f6278ab.js"],sortedPages:["/","/404","/_app","/_error","/guides/git","/guides/nodejs","/guides/pnpm","/guides/types","/guides/vscode","/ox_core","/ox_core/Client/Player","/ox_core/Client/Player/callbacks","/ox_core/Client/Player/events","/ox_core/Client/functions","/ox_core/Server/Player","/ox_core/Server/Player/events","/ox_core/Server/Player/methods","/ox_core/Server/Vehicle","/ox_core/Server/Vehicle/callbacks","/ox_core/Server/Vehicle/methods","/ox_core/Server/functions","/ox_core/concepts","/ox_doorlock","/ox_doorlock/Client/functions","/ox_doorlock/Server/events","/ox_doorlock/Server/functions","/ox_doorlock/settings","/ox_fuel","/ox_fuel/Client/functions","/ox_fuel/Server/functions","/ox_fuel/Shared","/ox_inventory","/ox_inventory/Events/Client","/ox_inventory/Events/Server","/ox_inventory/Frameworks/esx","/ox_inventory/Frameworks/qb","/ox_inventory/Functions/Client","/ox_inventory/Functions/Server","/ox_inventory/Functions/Server/Hooks","/ox_inventory/Guides/crafting","/ox_inventory/Guides/creatingItems","/ox_inventory/Guides/metadata","/ox_inventory/Guides/shops","/ox_inventory/Guides/stashes","/ox_inventory/issues","/ox_lib","/ox_lib/Modules/ACL/Server","/ox_lib/Modules/AddCommand/Server","/ox_lib/Modules/AddKeybind/Client","/ox_lib/Modules/Cache/Client","/ox_lib/Modules/Cache/Shared","/ox_lib/Modules/Callback/JavaScript/Client","/ox_lib/Modules/Callback/JavaScript/Server","/ox_lib/Modules/Callback/Lua/Client","/ox_lib/Modules/Callback/Lua/Server","/ox_lib/Modules/Class/Shared","/ox_lib/Modules/Cron/Server","/ox_lib/Modules/DisableControls/Client","/ox_lib/Modules/GetClosestObject/Shared","/ox_lib/Modules/GetClosestPed/Shared","/ox_lib/Modules/GetClosestPlayer/Shared","/ox_lib/Modules/GetClosestVehicle/Shared","/ox_lib/Modules/GetNearbyObjects/Shared","/ox_lib/Modules/GetNearbyPeds/Shared","/ox_lib/Modules/GetNearbyPlayers/Shared","/ox_lib/Modules/GetNearbyVehicles/Shared","/ox_lib/Modules/Interface","/ox_lib/Modules/Interface/Client/alert","/ox_lib/Modules/Interface/Client/clipboard","/ox_lib/Modules/Interface/Client/context","/ox_lib/Modules/Interface/Client/input","/ox_lib/Modules/Interface/Client/menu","/ox_lib/Modules/Interface/Client/notify","/ox_lib/Modules/Interface/Client/progress","/ox_lib/Modules/Interface/Client/radial","/ox_lib/Modules/Interface/Client/skillcheck","/ox_lib/Modules/Interface/Client/textui","/ox_lib/Modules/Locale/Shared","/ox_lib/Modules/Logger/Server","/ox_lib/Modules/Marker/Client","/ox_lib/Modules/Math/Shared","/ox_lib/Modules/Points/JavaScript/Client","/ox_lib/Modules/Points/Lua/Client","/ox_lib/Modules/Print/Shared","/ox_lib/Modules/Raycast/Client","/ox_lib/Modules/Require/Shared","/ox_lib/Modules/Streaming/Client","/ox_lib/Modules/String/Shared","/ox_lib/Modules/Table/Shared","/ox_lib/Modules/VehicleProperties/Client","/ox_lib/Modules/Version/Server","/ox_lib/Modules/Version/Shared","/ox_lib/Modules/WaitFor/Shared","/ox_lib/Modules/Zones/Shared","/ox_target","/ox_target/Functions/Client","/ox_target/Options","/oxmysql","/oxmysql/Functions/insert","/oxmysql/Functions/prepare","/oxmysql/Functions/query","/oxmysql/Functions/rawExecute","/oxmysql/Functions/scalar","/oxmysql/Functions/single","/oxmysql/Functions/transaction","/oxmysql/Functions/update","/oxmysql/benchmark","/oxmysql/issues","/oxmysql/placeholders","/oxmysql/ui"]}}("static/chunks/2059-ce0716acefc68b4d.js"),self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB(); \ No newline at end of file diff --git a/_next/static/TSLysL5tuuYDS43lr00Ap/_ssgManifest.js b/_next/static/aUInr-KvE0IfkGlGJtYb5/_ssgManifest.js similarity index 100% rename from _next/static/TSLysL5tuuYDS43lr00Ap/_ssgManifest.js rename to _next/static/aUInr-KvE0IfkGlGJtYb5/_ssgManifest.js diff --git a/_next/static/chunks/nextra-data-en-US.json b/_next/static/chunks/nextra-data-en-US.json index 2d849fe9bf..f37d50aa8a 100644 --- a/_next/static/chunks/nextra-data-en-US.json +++ b/_next/static/chunks/nextra-data-en-US.json @@ -1 +1 @@ -{"/guides/git":{"title":"Git","data":{"":"Git is a version control system, allowing changes to be effectively tracked, merged, and reverted.As our resources are hosted on GitHub, it can be incredibly useful to learn how to create your own repository to track changes and keep up-to-date. If you plan on making your own changes to our resources, this will allow you to keep your own changes and prevent loss of data.\nRefer to GitHub's guide to setting up Git.\nYou can use a Git GUI client like GitKraken to improve your workflow and more easily maintain changes."}},"/guides/pnpm":{"title":"pnpm","data":{"":"pnpm is a fast and disk space efficient package manager, serving as an alternative to npm and yarn.\nEnsure you have installed Node.js.\nOpen a command-line terminal (e.g. Terminal, Command Prompt).\nEnter npm install -g pnpm to globally install the package.\nYou can install dependencies with pnpm using pnpm i.\nYou can reference package.json files for available scripts, i.e.\n\"scripts\": {\n \"start\": \"vite\",\n \"watch\": \"vite build --watch\",\n \"build\": \"tsc && vite build\",\n \"preview\": \"vite preview\",\n \"format\": \"prettier --write \\\"./src/**/*.{ts,tsx,css}\\\"\"\n},\nUsing the example above pnpm build will run the build script for the given package."}},"/guides/types":{"title":"Types","data":{"setup-git-vscode-and-vscode-extensions#Setup git, vscode, and vscode extensions":"","download-our-lua-type-definitions#Download our Lua type definitions":"git clone https://github.com/overextended/ox_types.git`","update-your-settings#Update your settings":"You can modify the user, workspace, or folder settings for vscode.\nCreate an entry in Lua.workspace.library pointing to the cloned directory, or specific subdirectories.\n\"Lua.workspace.library\": [\n \"F:/GitHub/ox_types/types\",\n \"F:/GitHub/ox_lib\"\n],"}},"/":{"title":"Introduction","data":{"":"Here you can find all of the official documentation for resources developed by the Overextended team.If you feel like the documentation is lacking in some department then feel free to go onto that page and click the \"Edit this page\" at the bottom and submit a Pull Request.","support-our-team#Support our team":"Our projects will always remain free and open-source, with our core developers working voluntarily.\nIf you love what we do and want to help us continue, why not show your appreciation with a donation?","creator-codes#Creator codes":"Creator codes allow Tebex stores to share a percentage of a purchase with us, while giving a discount to the customer. We make these deals to advertise trusted creators who meet our criteria.\nResources are highly configurable or, preferably, source-available.\nWe trust that customers will be given assistance.\nThe creator is a known member of our community.\nStore\tCode\tDiscount\tLink\tAndyyy\tox20\t20%\thttps://andyyy.tebex.io/\tBerkie's Workshop\tox10\t10%\thttps://berkie.tebex.io/\tDolu Mods\toverextended\t15%\thttps://dolu.tebex.io/\tElectus Scripts\tox10\t10%\thttps://store.electus-scripts.com/\tLoaf Scripts\tox5\t5%\thttps://store.loaf-scripts.com/\tOT Studios\tox10\t10%\thttps://store.otstudios.net/ox\trcore\t0x10\t10%\thttps://store.rcore.cz/\tWasabi Scripts\tOX20\t20%\thttps://store.wasabiscripts.com/\t\nYou can apply a creator code at checkout under \"Support A Creator\"."}},"/ox_core":{"title":"Ox Core","data":{"":"An experimental framework for FiveM. Limited support and breaking changes guaranteed.\nThis resource does not have a stable (v1.0) release; breaking changes are likely.\nDocumentation may not be kept updated in some cases.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","install-all-resource-dependencies#Install all resource dependencies.":"oxmysql\nox_lib\nfivem-appearance\nox_appearance","download-a-release-or-build-the-source-code#Download a release or build the source code.":"git clone https://github.com/overextended/ox_core.git\ncd ox_core/web\npnpm i\npnpm build","install-optional-dependencies#Install optional dependencies.":"These resources aren't required but provide additional functionality.\nox_inventory\nnpwd\npefcl","optional-configure-pefcl#(Optional) Configure pefcl":"If using it with ox_inventory, open pefcl/config.json and enable framework integration.\n\"frameworkIntegration\": {\n \"enabled\": true,\n \"resource\": \"ox_inventory\",\n \"syncInitialBankBalance\": false\n},","importing-into-resources#Importing into resources":"","lua#Lua":"Lua imports can be defined as part of fxmanifest, or loaded with the load function.\nclient_scripts {\n '@ox_core/imports/client.lua',\n 'client/main.lua',\n}\nserver_scripts {\n '@oxmysql/lib/MySQL.lua',\n '@ox_core/imports/server.lua',\n 'server/main.lua',\n}\nlocal file = ('imports/%s.lua'):format(IsDuplicityVersion() and 'server' or 'client')\nlocal import = LoadResourceFile('ox_core', file)\nlocal chunk = assert(load(import, ('@@ox_core/%s'):format(file)))\nchunk()","javascript#JavaScript":"To use ox_core with your JS/TS resources you'll need to use our npm package, allowing you to import core functions with full type and intellisense support.","config#Config":"Resource configuration is handled using convars.\n# Players must have a valid identifier to join the server. Used to fetch userid from the database.\nset ox:primaryIdentifier \"fivem\"\n# Set the number of active characters a user can have registered.\nsetr ox:characterSlots 5\n# Enables debug and development features. Should only be used in a development environment.\nsetr ox:debug 0\n# Disable death system handle by core.\nsetr ox:deathSystem 0\n# Disable the spawn selection.\nsetr ox:spawnSelect 0"}},"/ox_core/Client/Player":{"title":"Client","data":{"":"When ox_core is imported into a resource it will create the player global.\nIf player is nil, then the client has not yet selected a character and spawned.Example:\nprint(json.encode(player, { indent = true }))\nplayer?: table\nuserId: number\ncharId: number\nstateId: string\nfirstName: string\nlastName: string\nname: string\ngroups: table"}},"/ox_core/Client/Player/events":{"title":"Events","data":{"client-events#Client events":"","oxplayerloaded#ox:playerLoaded":"Triggered once the player has selected a character and spawned.\nAddEventHandler('ox:playerLoaded', function(data) end)","oxplayerlogout#ox:playerLogout":"Triggered when the player enters character selection if they were previously playing a character.\nAddEventHandler('ox:playerLogout', function() end)","oxstatustick#ox:statusTick":"Triggered every 1000ms interval, when status values are updated internally.\nAddEventHandler('ox:statusTick', function(statuses) end)","oxplayerdeath#ox:playerDeath":"Triggered on player death and revival.\nAddEventHandler('ox:playerDeath', function(isDead) end)","networked-events#Networked events":"","oxsetgroup#ox:setGroup":"Triggered when the player's grade in a group is modified on the server with player.setGroup.\nRegisterNetEvent('ox:setGroup', function(group, grade) end)","oxlicenseadded#ox:licenseAdded":"Triggered when the player has been granted a license.\nRegisterNetEvent('ox:licenseAdded', function(name) end)","oxlicenseremoved#ox:licenseRemoved":"Triggered when the player's license is revoked.\nRegisterNetEvent('ox:licenseRemoved', function(name) end)"}},"/ox_core/Client/Player/callbacks":{"title":"Callbacks","data":{"oxgetstatus#ox:getStatus":"lib.callback.await('ox:getStatus', delay, targetId, statusName)\ndelay: number\ntargetId: number\nThe server id for the player to get statuses for.\nstatusName?: string\nThe name of the status (i.e. hunger). Can be omitted to return all statuses.","oxgetlicense#ox:getLicense":"lib.callback.await('ox:getLicense', delay, licenseName, targetId)\ndelay: number\nlicenseName: string\nThe name of the license to get data for. Can be omitted to return all licenses.\ntargetId?: number\nThe server id to get license data for, defaulting to the current player.","oxgetnearbyvehicles#ox:getNearbyVehicles":"lib.callback.register('ox:getNearbyVehicles', function(radius)\nReturns an array of vehicle netids within a given radius of the player's location.\nradius?: number\nThe radius from the player's location to return vehicles."}},"/ox_core/Client/functions":{"title":"Functions","data":{"":"todo"}},"/ox_core/Server/Player":{"title":"Server","data":{"oxgetplayer#Ox.GetPlayer":"Return an instance of OxPlayer for the given player source.\nlocal player = Ox.GetPlayer(source)\nprint(json.encode(player, { indent = true }))\nimport { GetPlayer } from '@overextended/ox_core/server';\nconst player = GetPlayer(source);\nconsole.log(JSON.stringify(player));\nplayer?: table\nsource: number\nuserId: number\ncharId: number\nstateId: string\nfirstName: string\nlastName: string\nname: string\nusername: string","oxgetplayerbyfilter#Ox.GetPlayerByFilter":"Return the first OxPlayer that matches the filter properties.\nlocal filter = { phoneNumber = '556-560-6609' }\nlocal player = Ox.GetPlayerByFilter(filter)\nprint(json.encode(player, { indent = true }))\nimport { GetPlayerByFilter } from '@overextended/ox_core/server';\nconst filter = { phoneNumber: '556-560-6609' };\nconst player = GetPlayerByFilter(filter);\nconsole.log(JSON.stringify(player));","oxgetplayers#Ox.GetPlayers":"Returns an array containing all players. Methods will not be applied if the first argument is false.\nPlayers can be filtered to only return players that match the given properties, or groups.\n-- Get an array containing all players in the police or sheriff groups, with grade 3 or higher.\nlocal filter = { groups = {['sheriff'] = 3, ['police'] = 3} })\nlocal players = Ox.GetPlayers(filter)\nfor i = 1, #players do\n local player = players[i]\n print(json.encode(player, { indent = true }))\nend\nimport { GetPlayers } from '@overextended/ox_core/server';\n// Get an array containing all players in the police or sheriff groups, with grade 3 or higher.\nconst filter = { groups: { sheriff: 3, police: 3 } })\nconst players = GetPlayers(filter);\nfor (let i = 0; i < players.length; i++) {\n const player = players[i];\n console.log(JSON.stringify(player));\n}"}},"/ox_core/Server/Player/events":{"title":"Events","data":{"server-events#Server events":"","oxplayerloaded#ox:playerLoaded":"Triggered after a player has selected a character.\nAddEventHandler('ox:playerLoaded', function(source, userid, charid) end)","oxsetgroup#ox:setGroup":"Triggered when a player's grade in a group is modified with player.setGroup.\nAddEventHandler('ox:setGroup', function(source, group, grade) end)","oxplayerlogout#ox:playerLogout":"Triggered when a player logs out from their current character or disconnects from the server.\nAddEventHandler('ox:playerLogout', function(source, userid, charid) end)","oxcharacterdeleted#ox:characterDeleted":"Triggered when a player has deleted a character.\nAddEventHandler('ox:characterDeleted', function(source, userid, charid) end)","oxlicenseadded#ox:licenseAdded":"Triggered when a player has been granted a license.\nAddEventHandler('ox:licenseAdded', function(source, name) end)","oxlicenseremoved#ox:licenseRemoved":"Triggered when a player's license is revoked.\nAddEventHandler('ox:licenseRemoved', function(source, name) end)","networked-events#Networked events":"","oxplayerdeath#ox:playerDeath":"Triggered on player death and revival.\nRegisterNetEvent('ox:playerDeath', function(isDead) end)","oxsetplayerinservice#ox:setPlayerInService":"Can be triggered to set a player as \"in service\" for a specific group they are a member of.\nRegisterNetEvent('ox:setPlayerInService', function(group) end)"}},"/ox_core/Server/Vehicle":{"title":"Server","data":{"oxgetvehicle#Ox.GetVehicle":"Return an instance of OxVehicle for the given entity.\nlocal vehicle = Ox.GetVehicle(entity)\nprint(json.encode(vehicle, { indent = true }))","oxgetvehicles#Ox.GetVehicles":"Returns an array containing all vehicles. Methods will not be applied if the first argument is false.\nlocal vehicles = Ox.GetVehicles(usemetatable)\nfor i = 1, #vehicles do\n local vehicle = vehicles[i]\n print(json.encode(vehicle, { indent = true }))\nend","oxcreatevehicle#Ox.CreateVehicle":"Spawns a vehicle and returns the instance of OxVehicle.\nIf the first argument is a number, it will attempt to spawn a vehicle from the database with a matching id.\nlocal vehicleId = MySQL.scalar.await('SELECT id FROM vehicles WHERE owner = ? LIMIT 1', { player.charid })\nif vehicleId then\n local coords = player.getCoords()\n local vehicle = Ox.CreateVehicle(vehicleId, vector3(coords.x, coords.y + 1.0, coords.z) , GetEntityHeading(player.ped))\n if vehicle then\n print(json.encode(vehicle, { indent = true }))\n end\nend\nIf the first argument is a table and the owner property is a number, or nil, the vehicle will be added to the database.\nSetting the owner as false creates a non-persistent vehicle.\nlocal vehicle = Ox.CreateVehicle({\n model = 'sultanrs',\n owner = player.charid,\n}, player.getCoords(), GetEntityHeading(player.ped))"}},"/ox_core/Server/Vehicle/callbacks":{"title":"Callbacks","data":{"oxgetnearbyvehicles#ox:getNearbyVehicles":"Get all vehicles within range of the target player.\nlib.callback.await('ox:getNearbyVehicles', playerId, radius)\nplayerId: number\nradius?: number"}},"/ox_core/Server/Player/methods":{"title":"Methods","data":{"":"These functions are inherited from the Player class.","playerset#player.set":"Update the player's metadata, optionally syncing it with the client.\nplayer.set(key, value, replicated)\nkey: string\nvalue: any\nreplicated?: boolean","playerget#player.get":"Get a value from the player's metadata, or omit the argument to get all metadata.\nplayer.get(key)\nkey?: string","playergetstate#player.getState":"Return the player's statebag.\nplayer.getState()","playergetcoords#player.getCoords":"Return the player's position.\nplayer.getCoords()","playersetgroup#player.setGroup":"Updates the player's grade for the given group. Any value below 1 will remove the group from the player.\nplayer.setGroup(group, grade)\ngroup: string\ngrade?: number","playergetgroup#player.getGroup":"Returns the player's current grade for a given group.\nplayer.getGroup()","playergetgroups#player.getGroups":"Returns an object of all groups the player is in, with the current grade as the value.\nplayer.getGroups()","playerhasgroup#player.hasGroup":"Check if the player is a member of a given group, and returns the matching group name and grade.\nThe filter can be a string, array, or object where key is the group, and value is the minimum grade.\nplayer.hasGroup(filter)\nfilter: string | string[] | { [string]: number }","playersetstatus#player.setStatus":"Set the current value for a status (i.e. hunger, thirst).\nplayer.setStatus(name, value)\nname: string\nvalue: number","playeraddstatus#player.addStatus":"Add the given amount to the total value for a status (i.e. hunger, thirst).\nplayer.addStatus(name, value)\nname: string\nvalue: number","playerremovestatus#player.removeStatus":"Remove the given amount from the total value for a status (i.e. hunger, thirst).\nplayer.removeStatus(name, value)\nname: string\nvalue: number","playergetlicenses#player.getLicenses":"Get all licenses for the player.\nplayer.getLicenses()","playergetlicense#player.getLicense":"Get the license of the given name for the player, as an object containing license information.\nplayer.getLicense(name)\nname: string","playeraddlicense#player.addLicense":"Grants a license to the player and triggers 'ox:licenseAdded' on the server and client.\nplayer.addLicense(name)\nname: string","playerremovelicense#player.removeLicense":"Revokes a license from the player and triggers 'ox:licenseRemoved' on the server and client.\nplayer.removeLicense(name)\nname: string","playergetplayersinscope#player.getPlayersInScope":"Return an array of all player id's inside the player's scope.\nplayer.getPlayersInScope()","playerisplayerinscope#player.isPlayerInScope":"Check if the given source is inside the player's scope.\nplayer.isPlayerInScope(target)\ntarget: number","playertriggerscopedevent#player.triggerScopedEvent":"player.triggerScopedEvent(eventName, ...)\neventName: string\n...?: any[]"}},"/ox_core/Server/Vehicle/methods":{"title":"Methods","data":{"":"These functions are inherited from the Vehicle class.","vehicleset#vehicle.set":"Sets the vehicle's metadata for key to the given value.\nvehicle.set(key, value)\nkey: string\nvalue: any","vehicleget#vehicle.get":"Get a value from the vehicles's metadata, or omit the argument to get all metadata.\nvehicle.get(key)\nkey?: string","vehiclegetstate#vehicle.getState":"Return the vehicle's statebag.\nvehicle.getState()","vehiclegetcoords#vehicle.getCoords":"Return the vehicle's position.\nvehicle.getCoords()","vehicledespawn#vehicle.despawn":"Despawns the vehicle but doesn't save it or update the stored value.","vehicledelete#vehicle.delete":"Remove the vehicle from the database and despawns the entity.\nvehicle.delete()","vehiclesetstored#vehicle.setStored":"Updates the vehicle's \"stored\" value and optionally despawns it.\nvehicle.setStored(value, despawn)\nvalue?: string\ndespawn?: boolean","vehiclesetowner#vehicle.setOwner":"Sets the vehicle's owner, matching a charid or nil to set it as unowned.\nvehicle.setOwner(owner)\nowner?: number","vehiclesetgroup#vehicle.setGroup":"Sets the vehicle's group, which can be used for garage restrictions, unowned group vehicles, etc.\nvehicle.setGroup(group)\ngroup?: string","vehiclesetplate#vehicle.setPlate":"Sets the vehicle's plate, used in the database to ensure uniqueness. Does not necessarily match the plate property (i.e. fake plates).\nPlate is always formatted to 8 characters.\nvehicle.setPlate(plate)\nplate: string"}},"/ox_core/Server/functions":{"title":"Functions","data":{"":"todo"}},"/ox_core/concepts":{"title":"Concepts","data":{"":"We'll try to explain some technical but core concepts used in ox_core here.","classes#Classes":"Lua doesn't have support for true classes, but rather prototype-based inheritance.\nA prototype can hold its own variables and methods, which another object (an instance) can reference or call.\n-- OxPlayer will hold all inherited variables and methods for instances of it.\nlocal OxPlayer = {}\n-- Sets the \"index metamethod\" of OxPlayer to reference itself.\n-- This is how instances will know to look up the table.\nOxPlayer.__index = OxPlayer\n-- Set a new metatable on the table passed to the function.\n-- The important code here is { __index = OxPlayer }.\nfunction OxPlayer.new(player)\n return setmetatable(player, OxPlayer)\nend\n-- Using the `:` syntax will pass the object as the first parameter.\nfunction OxPlayer:getUsername()\n return self.username\nend\n-- Create our instance of OxPlayer.\nlocal player = OxPlayer.new({\n username = 'Bob the Builder'\n})\n-- This is the same as OxPlayer.getUsername(player).\nlocal username = player:getUsername()\n-- 'Bob the Builder'\nprint(username)\nWhen using the imported classes in your resources you can treat the methods as if you are calling a regular function.\nlocal player = Ox.GetPlayer(playerId)\nprint(player.getUsername())"}},"/ox_doorlock":{"title":"Ox Doorlock","data":{"":"A door management resource that can be used standalone or alongside ox_core, qb-core, and es_extended.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","install-all-resource-dependencies#Install all resource dependencies.":"oxmysql\nox_lib","download-a-release-or-build-the-source-code#Download a release or build the source code.":"git clone https://github.com/overextended/ox_doorlock.git\ncd ox_doorlock/web\npnpm i\npnpm build","install-optional-dependencies#Install optional dependencies.":"These resources aren't required but provide additional functionality.\nox_target or qb-target","opening-the-ui#Opening the UI":"If you have installed and started the resource, you can use /doorlock to open the UI.\nIf the cursor is displayed but not the UI then you have not built it.\nYou may not be authorised to use the command.\nEnter test_ace player.1 command.doorlock in the server console (replace 1 with your server id).","convert-doors#Convert doors":"Door configuration files written for nui_doorlock (and its fork, qb-doorlock) can be automatically added to your MySQL database.\nAny files with the .lua extension placed in the ox_doorlock/convert directory will be read on resource start.\nIf the directory doesn't exist, you can create it.\nConversion cannot be guaranteed, especially if the config was not written for nui_doorlock.","adding-new-native-audio#Adding new native audio":"A guide can be found here for adding new native audio."}},"/ox_doorlock/Client/functions":{"title":"Functions","data":{"pickclosestdoor#pickClosestDoor":"Attempt to pick the lock of the closest door. Dependant on server-side checks and may fail.\nexports.ox_doorlock:pickClosestDoor()","useclosestdoor#useClosestDoor":"Interact with the closest door. Dependant on server-side checks and may fail.\nexports.ox_doorlock:useClosestDoor()"}},"/ox_doorlock/Server/events":{"title":"Events","data":{"handlers#Handlers":"These events should not be triggered by any other scripts.","ox_doorlockstatechanged#ox_doorlock:stateChanged":"Triggered when a doors state is updated.\nAddEventHandler('ox_doorlock:stateChanged', function(source, doorId, state, usedItem) end)\nsource: number or nil\ndoorId: number\nstate: boolean\nusedItem: string or false or nil"}},"/ox_doorlock/Server/functions":{"title":"Functions","data":{"":"Gets data for a door with the given id, matching the id for the database entry.","getdoor#getDoor":"exports.ox_doorlock:getDoor(doorId)\nGets data for a door with the given id, matching the id for the database entry.\nid: number\nReturn:\ndoor: table","getdoorfromname#getDoorFromName":"exports.ox_doorlock:getDoorFromName(name)\nGets data for a door with the given name, matching the name for the database entry.\nname: string\nReturn:\ndoor: table","editdoor#editDoor":"exports.ox_doorlock:editDoor(doorId, data)\nEdit configuration for the given doorId.\ndoorId: number\ndata: table","setdoorstate#setDoorState":"exports.ox_doorlock:setDoorState(doorId, state)\nSets a door with the given doorId as locked if state is true or 1.\ndoorId: number\nstate: 0 or 1 or boolean"}},"/ox_doorlock/settings":{"title":"Door Settings","data":{"general#General":"Door name\nUsed to easily identify the door.\nPasscode\nDoor can be unlocked by anybody by using the code or phrase.\nAutolock interval\nDoor will be locked after x seconds.\nInteract distance\nDoor can only be used when within x metres.\nDoor rate\nDoor movement speed for sliding/garage/automatic doors, or swinging doors when locked.\nLocked\nSets the door as locked by default.\nDouble\nDoor is a set of two doors, controlled together.\nAutomatic\nSliding/garage/automatic door.\nLockpick\nDoor can be lockpicked when interacting with a targeting resource.\nHide UI\nNo indicators (i.e. icon, text) will display on the door.\nHold Open\nHolds the door open while unlocked.","characters#Characters":"Character Id\nCharacter identifier used by a framework (i.e. player.charid, xPlayer.identifier, Player.CitizenId).","groups#Groups":"Group\nFramework dependent, referring to jobs, gangs, etc.\nGrade\nThe minimum grade to allow access for the group (0 to allow all).","items#Items":"Item\nName of the item.\nMetadata type\nRequires metadata support (i.e. ox_inventory) to check slot.metadata.type.\nRemove on use\nRemoves the item after interacting with the door.","lockpick#Lockpick":"Difficulty\nSets the skillcheck difficulty (see docs).\nArea size\nCustom difficulty area size in degrees.\nSpeed multiplier\nCustom difficulty idicator speed multipier.","sound#Sound":"Lock sound\nSound to play on door lock.\nUnlock sound\nSound to play on door unlock.\nNote: Sounds are stored in the ./web/public/sounds directory."}},"/ox_fuel":{"title":"Ox Fuel","data":{"":"A simple fuel resource meant to replace LegacyFuel or serve as a showcase for using petrol cans as an item.","installation#Installation":"","install-all-resource-dependencies#Install all resource dependencies.":"ox_lib\nox_inventory","download-a-release-or-clone-the-source-code#Download a release or clone the source code.":"git clone https://github.com/overextended/ox_fuel.git","install-optional-dependencies#Install optional dependencies.":"These resources aren't required but provide additional functionality.\nox_target"}},"/ox_fuel/Client/functions":{"title":"Functions","data":{"setmoneycheck#setMoneyCheck":"Override the built-in money check.\nexports.ox_fuel:setMoneyCheck(method)","parameters#Parameters":"method: function(): number","example#Example":"exports.ox_fuel:setMoneyCheck(function()\n local accounts = ESX.GetPlayerData().accounts\n for i = 1, #accounts do\n if accounts[i].name == 'bank' then\n return accounts[i].money\n end\n end\n return 0\nend)"}},"/ox_fuel/Server/functions":{"title":"Functions","data":{"setpaymentmethod#setPaymentMethod":"Override the built-in payment method.\nexports.ox_fuel:setPaymentMethod(method)","parameters#Parameters":"method: function(): boolean?","example#Example":"exports.ox_fuel:setPaymentMethod(function(playerId, amount)\n local xPlayer = ESX.GetPlayerFromId(playerId)\n local bankAmount = xPlayer.getAccount('bank').money\n if bankAmount >= amount then\n xPlayer.removeAccountMoney('bank', amount)\n return true\n end\n TriggerClientEvent('ox_lib:notify', source, {\n type = 'error',\n description = locale('not_enough_money', amount - bankAmount)\n })\nend)"}},"/ox_inventory":{"title":"Ox Inventory","data":{"":"A slot-based inventory with item metadata for \"item uniqueness\".\nIf you are replacing a built-in framework inventory there will be compatibility errors.\nIf you are unwilling or incapable of resolving incompatibilities, do not install this resource.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","install-all-resource-dependencies#Install all resource dependencies":"oxmysql\nox_lib","download-a-release-or-build-the-source-code#Download a release or build the source code.":"git clone https://github.com/overextended/ox_inventory.git\ncd ox_inventory/web\npnpm i\npnpm build","install-optional-dependencies#Install optional dependencies":"These resources aren't required but provide additional functionality.\nox_target","resource-start-order#Resource start order":"It's important for your resources to start in a logical order to prevent errors from missing dependencies.\nstart oxmysql # this should be one of the first resources\nstart ox_lib\nstart framework # the name of your framework (i.e. ox_core, es_extended, qb-core)\nstart ox_target\nstart ox_inventory","config#Config":"Resource configuration is handled using convars.\n### Shared\n# Activate specific event handlers and functions (supported: ox, esx, qb, nd)\nsetr inventory:framework \"esx\"\n# Number of slots for player inventories\nsetr inventory:slots 50\n# Maximum carry capacity for players, in grams (frameworks may override this)\nsetr inventory:weight 30000\n# Integrated support for qtarget/ox_target stashes, shops, etc\n# Note: qtarget is deprecated, a future update may drop support (ox_target only, or gated features)\nsetr inventory:target false\n# Jobs with access to police armoury, evidence lockers, etc\nsetr inventory:police [\"police\", \"sheriff\"]\n### Client\n# The URL to load item images from\nsetr inventory:imagepath \"nui://ox_inventory/web/images\"\n# Weapons will reload after reaching 0 ammo\nsetr inventory:autoreload false\n# Blur the screen while accessing the inventory\nsetr inventory:screenblur true\n# Default hotkeys to access primary and secondary inventories, and hotbar\nsetr inventory:keys [\"F2\", \"K\", \"TAB\"]\n# Enable control action when inventory is open\nsetr inventory:enablekeys [249]\n# Weapons must be aimed before shooting\nsetr inventory:aimedfiring false\n# Show a list of all nearby players when giving items\nsetr inventory:giveplayerlist false\n# Toggle weapon draw/holster animations\nsetr inventory:weaponanims true\n# Toggle item notifications (add/remove)\nsetr inventory:itemnotify true\n# Disable drop markers and spawn a prop instead\nsetr inventory:dropprops true\n# Set the default model used for drop props\nsetr inventory:dropmodel \"prop_med_bag_01b\"\n# Disarm the player if an unexpected weapon is in use (i.e. did not use the weapon item)\nsetr inventory:weaponmismatch true\n# Ignore weapon mismatch checks for the given weapon type (e.g. ['WEAPON_SHOVEL', 'WEAPON_HANDCUFFS'])\nsetr inventory:ignoreweapons []\n# Suppress weapon and ammo pickups\nsetr inventory:suppresspickups 1\n### Server\n# Compare current version to latest release on GitHub\nset inventory:versioncheck true\n# Stashes will be wiped after remaining unchanged for the given time\nset inventory:clearstashes \"6 MONTH\"\n# Discord webhook url, used for imageurl metadata content moderation (image embeds)\nset inventory:webhook \"\"\n# Logging via ox_lib (0: Disable, 1: Standard, 2: Include AddItem/RemoveItem, and all shop purchases)\nset inventory:loglevel 1\n# Item prices fluctuate in shops\nset inventory:randomprices true\n# Loot will randomly generate inside unowned vehicles and dumpsters\nset inventory:randomloot true\n# Minimum job grade to remove items from evidence lockers\nset inventory:evidencegrade 2\n# Trim whitespace from vehicle plates when checking owned vehicles\nsetr inventory:trimplate true\n# Set the contents of randomly generated inventories\n# [item name, minimum, maximum, loot chance]\nset inventory:vehicleloot [\n [\"cola\", 1, 1],\n [\"water\", 1, 1],\n [\"garbage\", 1, 2, 50],\n [\"panties\", 1, 1, 5],\n [\"money\", 1, 50],\n [\"money\", 200, 400, 5],\n [\"bandage\", 1, 1]\n]\nset inventory:dumpsterloot [\n [\"mustard\", 1, 1],\n [\"garbage\", 1, 3],\n [\"money\", 1, 10],\n [\"burger\", 1, 1]\n]\n# Set items to sync with framework accounts\nset inventory:accounts [\"money\"]","framework-incompatibilities#Framework incompatibilities":"Any frameworks with their own built-in inventory, item, or weapon systems are expected to have compatibility issues.\nMoney as an item may conflict with banking/account systems.\nYou can sync these values with server.syncInventory.\nRefer to issue #1297 for known compatibility issues.","using-an-unsupported-framework#Using an unsupported framework":"If your framework does not have official support you'll have to implement it yourself.\nIf you're replacing an existing/built-in inventory system this may be complicated, but is a fairly simple task otherwise.This setup is highly opinionated and rigid, so it's up to your own ability as a developer to make it work.","setup-a-bridge-submodule#Setup a bridge submodule":"You'll want to set the target framework first - this could be the name, an acronym, or just \"custom\".\nsetr inventory:framework \"custom\"\nCopy the ox directory from the bridge directory and give it the name you used above.The bare minimum functions and event handlers are added here, but you'll need to change them to match your framework; we can't provide any help here. You can refer to the other framework bridges if you need inspiration.","setup-database-references#Setup database references":"Take a look at the mysql module. You'll need to reference your player/vehicle tables and id columns.\nelseif shared.framework == 'custom' then\n playerTable = 'characters' -- table storing player / character data\n playerColumn = 'charid' -- primary key for identifying the character (i.e. identifier, citizenid, id)\n vehicleTable = 'vehicles' -- table storing owned vehicle data\n vehicleColumn = 'id' -- primary key for identifying the vehicle (i.e. plate, vin, id)\nend","esx#ESX":"You will need a compatible version of ESX Legacy (1.6.0 or higher).\nYou can convert player inventories with convertinventory esx.\nAll items in the database will be migrated to the internal item data.\nAlways restart the resource when items are migrated!","qbcore#QBCore":"Support for QBCore is extremely limited, highly incompatible, and unlikely to improve.\nYou can use any \"version\" of qb-core that supports QBCore.Functions.AddPlayerMethod.\nYou can convert player and vehicle inventories with convertinventory qb.\nAll QB.Shared.Items will be migrated to the internal item data.\nAlways restart the resource when items are migrated!","qbox-project#Qbox Project":"Qbox Project GitHub\nQbox txAdmin Recipe\nQbox is a fork of QBCore developed by former team members and contributors to QBCore.\nImproved security and performance of qb resources.\nIntegrated support for ox_inventory, with improved compatibility.\nSupport for ox_lib and ox_target."}},"/ox_fuel/Shared":{"title":"Shared","data":{"get-vehicle-fuel-amount#Get vehicle fuel amount":"local fuel = Entity(vehicleId).state.fuel","set-vehicle-fuel-amount#Set vehicle fuel amount":"Entity(vehicleId).state.fuel = fuelAmount"}},"/ox_inventory/Events/Client":{"title":"Client","data":{"":"This is not a comprehensive list of events and is missing events intended for internal use only.","event-triggers#Event Triggers":"These events are safe to trigger and handle in other scripts.","ox_inventorydisarm#ox_inventory:disarm":"Can be triggered to force the player to disarm.\nTriggerClientEvent('ox_inventory:disarm', playerId, noAnim)\nplayerId: number\nnoAnim: boolean\nIf true, disarm animation will be skipped","event-handlers#Event Handlers":"These events should not be triggered by any other scripts.","ox_inventoryupdateinventory#ox_inventory:updateInventory":"Triggered after inventory slots have been updated, included on load.\nChanges is a table containing all updated slot data indexed by slotId. Empty slots are false.\nAddEventHandler('ox_inventory:updateInventory', function(changes) end)\nchanges: table","ox_inventorycurrentweapon#ox_inventory:currentWeapon":"Triggered when a weapon is equipped or its metadata is altered.\nAddEventHandler('ox_inventory:currentWeapon', function(weapon) end)\nweapon?: table","ox_inventoryitemcount#ox_inventory:itemCount":"Triggered when the amount of an item in the player's inventory is changed.\nNote: Not available for ESX, use esx:addInventoryItem or esx:removeInventoryItem.\nAddEventHandler('ox_inventory:itemCount', function(itemName, totalCount) end)\nitemName: string\ntotalCount: number","ox_inventoryupdateweaponcomponent#ox_inventory:updateWeaponComponent":"AddEventHandler('ox_inventory:updateWeaponComponent', function(action, componentHash, componentItem) end)\naction: 'added' | 'removed'\ncomponentHash: number\ncomponentItem: string","ox_inventoryuseditem#ox_inventory:usedItem":"AddEventHandler('ox_inventory:usedItem', function(name, slotId, metadata) end)\nname: string\nslotId: number\nmetadata?: table"}},"/ox_inventory/Events/Server":{"title":"Server","data":{"":"This is not a comprehensive list of events and is missing events intended for internal use only.","handlers#Handlers":"These events should not be triggered by any other scripts.","ox_inventoryopenedinventory#ox_inventory:openedInventory":"Triggered after an inventory is opened by a player.\nAddEventHandler('ox_inventory:openedInventory', function(playerId, inventoryId) end)\nplayerId: number\ninventoryId: string","ox_inventoryclosedinventory#ox_inventory:closedInventory":"Triggered after an inventory is closed by a player.\nAddEventHandler('ox_inventory:closedInventory', function(playerId, inventoryId) end)","ox_inventoryuseditem#ox_inventory:usedItem":"AddEventHandler('ox_inventory:usedItem', function(playerId, name, slotId, metadata) end)\nplayerId: number\nname: string\nslotId: number\nmetadata?: table"}},"/ox_inventory/Frameworks/esx":{"title":"ESX","data":{"compatibility#Compatibility":"Ox Inventory is a complete replacement for existing item, inventory, and weapon systems; it is inherently incompatible with ESX and any resources that rely on default behaviour.\nLoadouts do not exist and weapons are treated as items.\nStandard shops and stashes (i.e. esx_shops, esx_weaponshop, and esx_policejob).\nResources that alter the default esx inventory or provide a ui (i.e. esx_trunkinventory, esx_inventoryhud).","installation#Installation":"Use a compatible version of ESX Legacy (1.6.0+).\nModify your server.cfg, starting ox_inventory immediately after es_extended.\nstart oxmysql\nstart ox_lib\nstart es_extended\nstart qtarget\nstart ox_inventory","convert-esx-inventory-data#Convert ESX inventory data":"Start the server and type convertinventory esx into the server console.\nOptionally, type convertinventory esxproperty into the server console.\nRestart the server once conversion is complete.","optional-optimisation#Optional Optimisation":"All item related functions from xPlayer, such as xPlayer.getInventoryItem, have been modified for compatibility purposes; however they are considered deprecated.The reasoning is fairly simple - there's now additional function references and overhead to consider. Fortunately, the new Inventory functions can be used directly and offer a great deal of improvements over the old ones.You should read through the functions section for further information, but the following should give you a decent idea.\nif xPlayer.getInventoryItem('acetone').count > 2 and xPlayer.getInventoryItem('antifreeze').count > 4 and xPlayer.getInventoryItem('sudo').count > 9 then\n xPlayer.removeInventoryItem(\"acetone\", 3)\n xPlayer.removeInventoryItem(\"antifreeze\", 5)\n xPlayer.removeInventoryItem(\"sudo\", 10)\nend\nAdd the following code somewhere in your resource to cache the exports metatable.\nlocal ox_inventory = exports.ox_inventory\nYou will be able to reference any functions exposed through the export.\nlocal items = ox_inventory:Search(source, 'count', {'acetone', 'antifreeze', 'sudo'})\nif items and items.acetone > 2 and items.antifreeze > 4 and items.sudo > 9 then\n ox_inventory:RemoveItem(source, 'acetone', 3)\n ox_inventory:RemoveItem(source, 'antifreeze', 5)\n ox_inventory:RemoveItem(source, 'sudo', 10)\nend"}},"/ox_inventory/Frameworks/qb":{"title":"QBCore","data":{"":"QBCore support is experimental and cannot work as a \"drag and drop\" solution due to many incompatibilities.","compatibility#Compatibility":"Ox Inventory provides a complete suite of tools to replace the built-in items and inventory system from QBCore, and is not intended to be used with resources designed around it.\nStashes used by qb-inventory and its forks do not work, but can possibly be converted.\nRemove qb-inventory (or similar), or qb-core will not function properly.\nRemove qb-shops and qb-weapons, as they depend on qb-inventory and conflict.\nWeapon holstering and draw animations (like in qb-smallresources) may break our own methods.","qbox-project#Qbox Project":"Qbox is a fork of QBCore being developed by a team of former contributors and developers on QBCore. The team is focused on improving performance and security, as well as converting resources to support our resources (mainly ox_lib and ox_inventory).We strongly advise using Qbox as an alternative to QBCore.\nQbox Project GitHub\nQbox Project Discord","installation#Installation":"Setup qb-core or qbox.\nEdit your server.cfg.\nAdd setr inventory:framework \"qb\" before starting your resources.\nStart ox_inventory immediately after qb-core.","convert-qbcore#Convert QBCore":"If you have existing player data, you will need to convert it to a compatible format.\nStart the server and type convertinventory qb into the server console.\nRestart the server once conversion is complete.","optional-optimisation#Optional Optimisation":"All item related functions from Player, such as Player.Functions.GetItemByName, have been modified for compatibility purposes; however they are considered deprecated.The reasoning is fairly simple - there's now additional function references and overhead to consider. Fortunately, the new Inventory functions can be used directly and offer a great deal of improvements over the old ones.You should read through the functions section for further information, but the following should give you a decent idea.\nlocal acetone = Player.Functions.GetItemByName('acetone')\nlocal antifreeze = Player.Functions.GetItemByName('antifreeze')\nlocal sudo = Player.Functions.GetItemByName('sudo')\nif acetone?.amount > 2 and antifreeze?.amount > 4 and sudo?.amount > 9 then\n Player.Functions.RemoveItem(\"acetone\", 3)\n Player.Functions.RemoveItem(\"antifreeze\", 5)\n Player.Functions.RemoveItem(\"sudo\", 10)\nend\nAdd the following code somewhere in your resource to cache the exports metatable.\nlocal ox_inventory = exports.ox_inventory\nYou will be able to reference any functions exposed through the export.\nlocal items = ox_inventory:Search(source, 'count', {'acetone', 'antifreeze', 'sudo'})\nif items and items.acetone > 2 and items.antifreeze > 4 and items.sudo > 9 then\n ox_inventory:RemoveItem(source, 'acetone', 3)\n ox_inventory:RemoveItem(source, 'antifreeze', 5)\n ox_inventory:RemoveItem(source, 'sudo', 10)\nend"}},"/ox_inventory/Functions/Client":{"title":"Client","data":{"openinventory#openInventory":"Opens an inventory using the passed data.\nexports.ox_inventory:openInventory(invType, data)\ninvType: string\n'player'\n'shop'\n'stash'\n'crafting'\n'container'\n'drop'\n'glovebox'\n'trunk'\n'dumpster'\ndata: number or string or table\nExamples\nOpen the target player's inventory.\nexports.ox_inventory:openInventory('player', 3)\nOpen the fourth \"General Store\" location.\nexports.ox_inventory:openInventory('shop', { type = 'General', id = 4 })\nOpen the first stash in data/stashes.\nexports.ox_inventory:openInventory('stash', 1)\nOpen a custom stash (created on the server with RegisterStash).\nexports.ox_inventory:openInventory('stash', 'society_police')\nOpen a stash with a specific owner.\nexports.ox_inventory:openInventory('stash', { id = 'police_locker', owner = 'license:xxxxxxxx' })","opennearbyinventory#openNearbyInventory":"If possible opens the nearby player's inventory.The player trying to open the inventory must be able to open their own and\nif the player does not have a police job, the target player must be fatally injured or\nplaying one of the death anims.\nexports.ox_inventory:openNearbyInventory()","closeinventory#closeInventory":"Closes the player's inventory.\nexports.ox_inventory:closeInventory()","items#Items":"Returns a table of all registered items. The format is as defined in data/items.lua.\nexports.ox_inventory:Items()\nThe following snippet can be used in crafting resources such as okokCrafting or core_crafting, rather than retrieving information from the server.\nlocal itemNames = {}\nfor item, data in pairs(exports.ox_inventory:Items()) do\n itemNames[item] = data.label\nend","useitem#useItem":"Uses the passed item, then triggers the callback function.\nShould be calling during item callbacks to utilise the builtin methods (server checks, progress bar, etc.).\nexports.ox_inventory:useItem(data, cb)\ndata: table\ncb?: function\nexports('bandage', function(data, slot)\n local playerPed = PlayerPedId()\n local maxHealth = GetEntityMaxHealth(playerPed)\n local health = GetEntityHealth(playerPed)\n -- Does the ped need to heal?\n if health < maxHealth then\n -- Use the bandage\n exports.ox_inventory:useItem(data, function(data)\n -- The item has been used, so trigger the effects\n if data then\n SetEntityHealth(playerPed, math.min(maxHealth, math.floor(health + maxHealth / 16)))\n lib.notify({description = 'You feel better already'})\n end\n end)\n else\n -- Don't use the item\n lib.notify({type = 'error', description = 'You don\\'t need a bandage right now'})\n end\nend)","useslot#useSlot":"Uses the item in the given inventory slot.\nexports.ox_inventory:useSlot(slot)\nslot: number","setstashtarget#setStashTarget":"Forces the secondary-inventory key to open the passed inventory. Can be useful to enable inventory access while standing inside a marker.\nexports.ox_inventory:setStashTarget(id, owner)\nid: string or number\nStash id.\nowner?: string or number\nExample\nexports.ox_inventory:setStashTarget('motel5', 'bobsmith')","getcurrentweapon#getCurrentWeapon":"Get data for the currently equipped weapon.\nexports.ox_inventory:getCurrentWeapon()\nYou can also listen for changes to the current weapon using an event handler.\nAddEventHandler('ox_inventory:currentWeapon', function(currentWeapon)\n\tCurrentWeapon = currentWeapon\nend)\ncurrentWeapon?: table\nammo?: string Name of the item used as ammo.\nhash: number\nlabel: string\nmelee: boolean\nmetadata: table\nammo?: number Amount of ammo loaded into the weapon.\ncomponents?: table Array of component item names, used to apply weapon components.\ndurability?: number\nregistered?: string Name of the player that bought the weapon at a shop.\nserial?: string\nname: string Name of the item.\nslot: number\nweight: number","displaymetadata#displayMetadata":"Sets a metadata property to display in the tooltip.\nexports.ox_inventory:displayMetadata(metadata, value)\nmetadata: string or table or { [string], [string] }\nIf metadata is a string then it's the metadata property you want to display, value is not optional then.\nCan be a table of key-value pairs, key being the metadata property and value being the label for that property.\nCan be an array of string arrays, i.e. { {'key', 'label' }, {'key2', 'label2' } to set the display order.\nvalue?: string\nLabel for the string metadata property to be displayed.\nExample\nexports.ox_inventory:displayMetadata('mustard', 'Mustard')\nexports.ox_inventory:displayMetadata({\n mustard = 'Mustard',\n ketchup = 'Ketchup'\n})","giveitemtotarget#giveItemToTarget":"Gives an item from the player's inventory to another player.\nexports.ox_inventory:giveItemToTarget(serverId, slotId, count)\nserverId: number\nThe serverId of the target player.\nslotId: number\nThe slotId of the item to give.\ncount?: number\nThe amount of the item to give, with nil, 0 or a value above the slot count giving the entire stack away.","weaponwheel#weaponWheel":"Enables the weapon wheel, but disables the use of inventory items.Mostly used for weaponised vehicles, though could be called for \"minigames\"\nlocal exports.ox_inventory:weaponWheel(state)\nstate: boolean","search#Search":"Searches the inventory for an item, or list of items, with the result varying based on the first argument.\nexports.ox_inventory:Search(search, item, metadata)\nsearch: 'slots' or 'count'\n'slots' returns a table of slots where the item was found at.\n'count' returns the count of the specified item in player's inventory. If searching for multiple items\nreturns key-value pairs of itemName = count.\nitem: table or string\nCan be a single item name or array of item names.\nmetadata?: table or string\nIf metadata is provided as a string it will search the item's metadata.type property.","count#Count":"local count = exports.ox_inventory:Search('count', 'water')\nprint('You have '..count.. ' water')\nlocal inventory = exports.ox_inventory:Search('count', {'meat', 'skin'}, {grade=\"1\"})\nif inventory then\n for name, count in pairs(inventory) do\n print('You have '..count..' '..name)\n end\nend","slots#Slots":"local water = exports.ox_inventory:Search('slots', 'water')\nlocal count = 0\nfor _, v in pairs(water) do\n print(v.slot..' contains '..v.count..' water '..json.encode(v.metadata))\n count = count + v.count\nend\nprint('You have '..count..' water')\nlocal items = exports.ox_inventory:Search('slots', {'meat', 'skin'}, 'deer')\nif items then\n for name, data in pairs(items) do\n local count = 0\n for _, v in pairs(data) do\n if v.slot then\n print(v.slot..' contains '..v.count..' '..name..' '..json.encode(v.metadata))\n count = count + v.count\n end\n end\n print('You have '..count..' '..name)\n end\nend","getitemcount#GetItemCount":"Get the total item count for all items in the player's inventory with the given name and metadata.\nexports.ox_inventory:GetItemCount(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\ncount: number","getplayeritems#GetPlayerItems":"Get all items in the player's inventory.\nexports.ox_inventory:GetPlayerItems()\nReturn:\nitems: table","getplayerweight#GetPlayerWeight":"Get the total weight of all items in the player's inventory.\nexports.ox_inventory:GetPlayerWeight()\nReturn:\ntotalWeight: number","getplayermaxweight#GetPlayerMaxWeight":"Get the maximum carry weight of the player's inventory.\nexports.ox_inventory:GetPlayerMaxWeight()\nReturn:\nmaxWeight: number","getslotidwithitem#GetSlotIdWithItem":"Get a slot id in the player's inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotIdWithItem(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotId: number?","getslotsidwithitem#GetSlotsIdWithItem":"Get all slot ids in the player's inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotIdsWithItem(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotIds: number[]?","getslotwithitem#GetSlotWithItem":"Get data for a slot in the player's inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotWithItem(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotData: table?","getslotswithitem#GetSlotsWithItem":"Get data all slots in the player's inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotsWithItem(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotsData: table[]?","statebags#Statebags":"","invbusy#invBusy":"Returns whether the player's inventory is currently running an action (i.e. using an item).\nCan be set to true to disable opening the inventory.\ninvBusy: boolean\nlocal invBusy = LocalPlayer.state.invBusy\nif invBusy then\n -- Do stuff when busy\nelse\n -- Do stuff when not busy\nend","disable-opening-inventory#Disable opening inventory":"LocalPlayer.state.invBusy = true","invhotkeys#invHotkeys":"Allows you to enable/disable a player's access to inventory hotkeys.\ninvHotkeys: boolean\nLocalPlayer.state.invHotkeys = false","invopen#invOpen":"Returns whether the player's inventory is currently open or not.\ninvOpen: boolean\nlocal invOpen = LocalPlayer.state.invOpen\nif invOpen then\n -- Do stuff when open\nelse\n -- Do stuff when closed\nend","canuseweapons#canUseWeapons":"Allows you to enable/disable the use of weapons for a player.\nLocalPlayer.state.canUseWeapons = false"}},"/ox_inventory/Functions/Server/Hooks":{"title":"Hooks","data":{"":"Event hooks allow 3rd party resources to define new behaviour without modifying the inventory code directly.","registerhook#registerHook":"exports.ox_inventory:registerHook(eventName, function(payload) end, options)\neventName: string\npayload: table\noptions?: table\nprint?: boolean\nPrint to the console when triggering the event.\nitemFilter?: { [string]: true }\nThe event will only trigger for items defined as keys in a set.\ninventoryFilter?: string[]\nThe event will only trigger for inventories that match one of the patterns in the array.\ntypeFilter?: { [string]: true }\nThe event will only trigger for inventories with one of the provided types (e.g. 'player', 'stash')\nReturn:\nhookId: number","swapitems#swapItems":"Triggered when moving any item from one slot to another, or when \"giving\" an item.\nBy returning false, you can cancel the action and revert the inventory state.\nPayload: table\nsource: number\naction: 'move' or 'stack' or 'swap' or 'give'\nfromInventory: table or string or number\ntoInventory: table or string or number\nfromType: string\ntoType: string\nfromSlot: table\ntoSlot?: table or number\ncount: number\nExampleBlacklists \"water\" from being moved into or from gloveboxes and trunks.\nlocal hookId = exports.ox_inventory:registerHook('swapItems', function(payload)\n print(json.encode(payload, { indent = true }))\n return false\nend, {\n print = true,\n itemFilter = {\n water = true,\n },\n inventoryFilter = {\n '^glove[%w]+',\n '^trunk[%w]+',\n }\n})","openinventory#openInventory":"Payload: table\nsource: number\ninventoryId: number or string\ninventoryType: string\nTriggered when a player tries to open a secondary inventory.\nBy returning false, you can cancel the action and keep the player's inventory closed.ExampleDisables gloveboxes and trunks.\nlocal hookId = exports.ox_inventory:registerHook('openInventory', function(payload)\n print(json.encode(payload, { indent = true }))\n return false\nend, {\n print = true,\n inventoryFilter = {\n '^glove[%w]+',\n '^trunk[%w]+',\n }\n})","createitem#createItem":"Payload: table\ninventoryId?: number or string\nmetadata: table\nitem: table\ncount: number\nTriggered when an item is created, either by buying it, using AddItem, or when converting inventory data.\nBy returning a table you can modify or replace the metadata given to an item.ExampleSets the label for \"water\" to \"Mineral Water\".\nlocal hookId = exports.ox_inventory:registerHook('createItem', function(payload)\n print(json.encode(payload, { indent = true }))\n local metadata = payload.metadata\n metadata.label = 'Mineral Water'\n return metadata\nend, {\n print = true,\n itemFilter = {\n water = true\n }\n})","buyitem#buyItem":"Payload: table\nsource: number\nshopType: string\nshopId: number\ntoInventory: number\ntoSlot: number\nitemName: string\nmetadata: table\ncount: number\nprice: number\ntotalPrice: number\ncurrency?: string\nTriggered when an item is about to be purchased and can return false to prevent the transaction.ExamplePrevents players from purchasing items at General stores.\nlocal hookId = exports.ox_inventory:registerHook('buyItem', function(payload)\n print(json.encode(payload, { indent = true, sort_keys = true }))\n return false\nend, {\n print = true,\n itemFilter = {\n water = true\n\t },\n})","craftitem#craftItem":"Payload: table\nsource: number\nbenchId: number\nbenchIndex: number\nrecipe: table\ncount: number\nduration: number\ningredients: table\nname: string\nslot: number\nweight: number\ntoInventory: number\ntoSlot: number\nExamplePrevent lockpicks from being crafted by players.\nlocal hookId = exports.ox_inventory:registerHook('craftItem', function(payload)\n print(json.encode(payload, { indent = true, sort_keys = true }))\n return false\nend, {\n print = true,\n\titemFilter = {\n\t\tlockpick = true\n\t},\n})","removehooks#removeHooks":"Removes a hook created by the invoking resource with the the specified id.\nIf no id is specified then all hooks registered by the resource are removed.\nexports.ox_inventory:removeHooks(id)\nid?: number"}},"/ox_inventory/Functions/Server":{"title":"Server","data":{"setplayerinventory#setPlayerInventory":"Creates and sets the player's inventory.\nexports.ox_inventory:setPlayerInventory(player, data)\nplayer: table\nsource: number\nidentifier: string\nname: string\ngroups?: table\nsex?: string\ndateofbirth?: string\ndata?: table\nIf not provided will load player's inventory data from the db.","forceopeninventory#forceOpenInventory":"Opens an inventory using the passed data.\nForces a player to open an inventory, without usual security checks (groups, coords).\nexports.ox_inventory:forceOpenInventory(playerId, invType, data)\nplayerId: number\ninvType: string\n'player'\n'stash'\n'container'\n'drop'\n'glovebox'\n'trunk'\n'dumpster'\ndata: number or string or table\nOpen the target player's inventory.\nexports.ox_inventory:forceOpenInventory(1, 'player', 3)\nAdmin command to open a player's inventory.\nRegisterCommand('openplayerinv', function(source, args)\n exports.ox_inventory:forceOpenInventory(source, 'player', tonumber(args[1]))\nend, true)\nOpen a custom stash (created on the server with RegisterStash).\nexports.ox_inventory:forceOpenInventory(1, 'stash', 'society_police')\nOpen a stash with a specific owner.\nexports.ox_inventory:forceOpenInventory(1, 'stash', { id = 'police_locker', owner = 'license:xxxxxxxx' })","updatevehicle#UpdateVehicle":"Update the internal reference to vehicle stashes, without triggering a save or updating the database.\nexports.ox_inventory:UpdateVehicle(oldPlate, newPlate)\noldPlate: string\nnewPlate: string","items#Items":"Returns a table of all registered items. The format is as defined in data/items.lua.\nexports.ox_inventory:Items()\nThe following snippet can be used in crafting resources such as okokCrafting or core_crafting, rather than querying the database.\nlocal itemNames\nESX.RegisterServerCallback('crafting:itemNames', function(source, cb)\n if not itemNames then\n itemNames = {}\n for item, data in pairs(exports.ox_inventory:Items()) do\n itemNames[item] = data.label\n end\n end\n cb(itemNames)\nend)","additem#AddItem":"Adds an item into the specified inventory.Should be used alongside CanCarryItem otherwise, the maximum weight may be exceeded.\nexports.ox_inventory:AddItem(inv, item, count, metadata, slot, cb)\ninv: table or string or number\nThe inventory's unique id, or a table with the id and owner.\nplayerId: 1\ninventoryId: gloveVGH283\n{ id = 'personallocker', owner = 'license:xxxxxx'}\nitem: string\nThe name of the item to add to the target.\ncount: number\nThe number of items to add.\nmetadata?: table or string\nA table of unique data to attach to the item object. A string will create a table with the \"type\" field.\nslot?: number\nA specific slot to add the item to. If the slot is invalid, the first available slot will be used instead.\ncb?: function(success: boolean, response?: string)\nIf used for glovebox, trunk or stash you must first check the inventory is loaded with GetInventoryReturns success, response if cb is undefined, otherwise they are used in the callback only.Possible value of the \"response\" argument, on failure:\n\"invalid_item\": the item doesn't exist\n\"invalid_inventory\": the inventory doesn't exist\n\"inventory_full\": no free slots\nExample\nlocal success, response = exports.ox_inventory:AddItem('gloveVGH283', 'bread', 4)\nif not success then\n -- if no slots are available, the value will be \"inventory_full\"\n return print(response)\nend\nprint(json.encode(response, {indent=true}))\n--[[\n {\n \"metadata\": [],\n \"label\": \"Bread\",\n \"slot\": 1,\n \"stack\": true,\n \"close\": true,\n \"name\": \"bread\",\n \"count\": 1,\n \"weight\": 150\n }\n]]","removeitem#RemoveItem":"Removes the specified item from the specified inventory.\nexports.ox_inventory:RemoveItem(inv, item, count, metadata, slot)\ninv: table or string or number\nThe inventory's unique id, or a table with the id and owner.\nplayerId: 1\ninventoryId: gloveVGH283\n{ id = 'personallocker', owner = 'license:xxxxxx'}\nitem: string\nThe name of the item to remove from the target.\ncount: number\nThe number of items to remove.\nmetadata?: table or string\nOnly remove items with matching metadata properties.\nslot?: number\nA specific slot to remove the item from. If the slot is invalid, the first available slot will be used instead.\ncb?: function(success: boolean, response?: string)\nReturns success: boolean, response: string?.Possible values of \"response\" on failure:\n\"invalid_item\": the item doesn't exist\n\"invalid_inventory\": the inventory doesn't exist\n\"not_enough_items\": inventory did not contain enough of the given item\nExample\n-- Removes 2 water from the glovebox for the given plate.\nlocal success = exports.ox_inventory:RemoveItem('gloveVGH283', 'water', 2)","getitem#GetItem":"Returns generic item data from the specified inventory, with the total count.\nexports.ox_inventory:GetItem(inv, item, metadata, returnsCount)\ninv: table or string or number\nitem: table or string\nCan be items array.\nmetadata?: any\nOnly returns the count of items that strictly match the given metadata.\nreturnsCount?: boolean\nIf returnsCount is set to true, the returned value will be the count based on\nhow many times the item was found.\nOtherwise returns the data related to the item and its total count found in the inventory.\nExample\nlocal item = ox_inventory:GetItem(source, 'water', nil, false)\nprint(json.encode(item, {indent=true}))\n--[[\n {\n \"consume\": 1,\n \"count\": 15,\n \"stack\": true,\n \"name\": \"water\",\n \"weight\": 500,\n \"label\": \"Water\",\n \"close\": true\n }\n]]","convertitems#ConvertItems":"Takes traditional item data and updates it to support ox_inventory.\nexports.ox_inventory:ConvertItems(playerId, items)\nplayerId: number\nitems: table\nData Conversion Example\nOld: [{\"cola\":1, \"bread\":3}]\nNew: [{\"slot\":1,\"name\":\"cola\",\"count\":1},\n{\"slot\":2,\"name\":\"bread\",\"count\":3}]","cancarryitem#CanCarryItem":"Returns true or false depending if the inventory can carry the specified item.The function checks for inventory weight and available slots.\nexports.ox_inventory:CanCarryItem(inv, item, count, metadata)\ninv: table or string or number\nitem table or string\nCan be array of items.\ncount: number\nmetadata?: table or string\nIf metadata is passed as string then metadata.type will be checked.\nExample\n-- Checks if the player calling the event can carry 3 water items\nif exports.ox_inventory:CanCarryItem(source, 'water', 3) then\n -- Do stuff if can carry\nelse\n -- Do stuff if can't carry\nend","cancarryamount#CanCarryAmount":"Returns the amount a player can hold based on available weight.\nexports.ox_inventory:CanCarryAmount(inv, item)\ninv: table or string or number\nitem: table or string\nCan be array to check multiple items.\nExample\n-- Checks how much you can carry\namountToAdd = exports.ox_inventory:CanCarryAmount(inv, 'stone')\n-- Adds the amount\nexports.ox_inventory:AddItem(inv, 'stone', amountToAdd)","cancarryweight#CanCarryWeight":"Returns if inventory can carry specified weight and free inventory weight.\nexports.ox_inventory:CanCarryWeight(inv, weight)\ninv: table or string or number\nweight: number\nExample\n-- Checks if player can carry 1000 grams.\nlocal fillAmount = 1000\nlocal canCarryWeight, freeWeight = ox_inventory:CanCarryWeight(playerId, fillAmount)\nif freeWeight == 0 then\n -- Player can't carry weight.\n return\nelseif not canCarryWeight then\n -- Modify fillAmount, because inventory can't carry specified weight\n fillAmount = freeWeight\nend\n-- Do something","setmaxweight#SetMaxWeight":"Sets the maximum weight available for an inventory.\nexports.ox_inventory:SetMaxWeight(inv, maxWeight)\ninv: table or string or number\nmaxWeight: number\nExample\nlocal ox_inventory = exports.ox_inventory\n-- Set the max weight for player 1's inventory to 20kg.\nox_inventory:SetMaxWeight(1, 20000)","canswapitem#CanSwapItem":"Returns true if the item swap is possible based on inventory weight.\nexports.ox_inventory:CanSwapItem(inv, firstItem, firstItemCount, testItem, testItemCount)\ninv: table or string or number\nfirstItem: string\nfirstItemCount: number\ntestItem: string\ntestItemCount: number","getitemcount#GetItemCount":"Get the total item count for all items in an inventory with the given name and metadata.\nexports.ox_inventory:GetItemCount(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nitemCount: number","getitemslots#GetItemSlots":"Returns the number of slots the specified item is in, the item's total count and the remaining empty slots.\nexports.ox_inventory:GetItemSlots(inv, item, metadata)\ninv: table or string or number\nitem: table or string\nmetadata?: table","getslot#GetSlot":"Returns the specified slot data as a table.\nexports.ox_inventory:GetSlot(inv, slot)\ninv: table or string or number\nslot: number\nExample\nlocal slot = exports.ox_inventory:GetSlot(source, 1)\nprint(json.encode(slot, {indent=true}))\n--[[\n {\n \"weight\": 2000,\n \"name\": \"water\",\n \"metadata\": [],\n \"slot\": 1,\n \"label\": \"Water\",\n \"close\": true,\n \"stack\": true,\n \"count: 4\n }\n]]","getslotforitem#GetSlotForItem":"Get the slot id of an existing item matching the given data, or an empty slot.\nexports.ox_inventory:GetSlotForItem(inv, itemName, metadata)\ninv: table or string or number\nitemName: string\nmetadata: table?\nReturn:\nslotId: number?","getslotidwithitem#GetSlotIdWithItem":"Get a slot id in an inventory matching the given item name and metadata.\nexports.ox_inventory:GetSlotIdWithItem(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotId: number?","getslotidswithitem#GetSlotIdsWithItem":"Get all slot ids in an inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotIdsWithItem(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotIds: number[]?","getslotwithitem#GetSlotWithItem":"Get data for a slot in an inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotWithItem(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotData: table?","getslotswithitem#GetSlotsWithItem":"Get data all slots in an inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotsWithItem(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotsData: table[]?","getemptyslot#GetEmptySlot":"Get the first available empty slot in an inventory.\nexports.ox_inventory:GetEmptySlot(inv)\ninv: table or string or number\nReturn:\nslotId: number?","getcontainerfromslot#GetContainerFromSlot":"Returns the inventory associated with the container linked in the slot of the given inventory.\nexports.ox_inventory:GetContainerFromSlot(inv, slotId)\ninv: table or string or number\nslotId: number\nReturn:\ncontainerData: table?","setslotcount#SetSlotCount":"Sets the number of slots available for an inventory.\nexports.ox_inventory:SetSlotCount(inv, slots)\ninv: table or string or number\nslots: number\nExample\nlocal ox_inventory = exports.ox_inventory\n-- Set the slot count for player 1's inventory to 10.\nox_inventory:SetSlotCount(1, 10)","getinventory#GetInventory":"Returns the inventory associated with the ID (and owner if defined). Otherwise returns null.\nexports.ox_inventory:GetInventory(inv, owner)\ninv: number or table\nowner?: string or boolean\nExample\nlocal inventory = exports.ox_inventory:GetInventory('example_stash', false)\nprint(json.encode(inventory, {indent = true}))\n--[[\n {\n \"id\": \"example_stash,\n \"label\": \"Police Stash\",\n \"type\": \"stash,\n \"slots\": 50,\n \"weight\": 0,\n \"maxWeight\": 100000,\n \"owner\": false,\n ...\n }\n]]","getinventoryitems#GetInventoryItems":"Returns all slots with items in a inventory.\nexports.ox_inventory:GetInventoryItems(inv, owner)\ninv: number or table\nowner?: string or boolean\nExample\nlocal playerItems = exports.ox_inventory:GetInventoryItems(source)","confiscateinventory#ConfiscateInventory":"Clears a player's inventory and saves it to a stash.Use ReturnInventory to return the confiscated inventory back to\nthe player.\nexports.ox_inventory:ConfiscateInventory(source)\nsource: number","returninventory#ReturnInventory":"Returns the confiscated inventory back to the player.Use it alongside ConfiscateInventory.\nexports.ox_inventory:ReturnInventory(source)\nsource: number","clearinventory#ClearInventory":"Clears the specified inventory. The keep argument is either a string or an array of strings containing the name(s) of the item(s) to keep in the inventory after clearing.\nexports.ox_inventory:ClearInventory(inv, keep)\ninv: table or string or number\nkeep?: string or string[]","search#Search":"Searches an inventory for a specified item.\nexports.ox_inventory:Search(inv, search, item, metadata)\ninv: table or string or number\nsearch: string\nitem: table or string\nmetadata?: table or string\nsearch can be either 'slots' or 'count', where slots will return a table of data\nand count will return the found amount of the specified item.","swapslots#SwapSlots":"Swaps slots in specified inventories.\nexports.ox_inventory:SwapSlots(fromInventory, toInventory, slot1, slot2)\nfromInventory: table or string or number\ntoInventory: table or string or number\nslot1: number\nslot2: number","registerstash#RegisterStash":"Creates a new custom stash.\nexports.ox_inventory:RegisterStash(id, label, slots, maxWeight, owner, groups, coords)\nid: string or number\nStash identifier when loading from the database.\nlabel: string\nDisplay name when inventory is open.\nslots: number\nmaxWeight: number\nowner: string or boolean or nil\nstring: Can only access the stash linked to the owner.\ntrue: Each player has a unique stash but can request other player's stashes.\nnil: Always shared.\ngroups: table\nTable of player groups (jobs) able to access the stash.\nTable of group names where the numeric value is the minimum grade required.\n{['police'] = 0, ['ambulance'] = 2}\ncoords?: vector3 or vector3[]\nThis function needs to be triggered before a player can open the stash.\nExample\nFor a use case example on this function check out the written Guide for it.","createtemporarystash#CreateTemporaryStash":"Creates a temporary stash which will be removed after some time.\nexports.ox_inventory:CreateTemporaryStash(properties)\nproperties: table\nlabel: string\nslots: number\nmaxWeight: number\nowner?: string number or boolean\nstring: Can only access the stash linked to the owner.\ntrue: Each player has a unique stash but can request other player's stashes.\nThe inventory is always shared if false or nil.\ngroups?: table\nTable of group names (e.g. jobs) where the numeric value is the minimum grade required.\n{['police'] = 0, ['ambulance'] = 2}\ncoords?: vector3\nStash can only be accessed while nearby.\nitems?: { [number]: string, [number]: number, [number]?: table }[]\nAn array of tables, containing a sequence of itemName, count, metadata.\nReturn:\ninventoryId: string\nExample\nlocal mystash = exports.ox_inventory:CreateTemporaryStash({\n label = 'mystash',\n slots = 5,\n maxWeight = 5000,\n items = {\n { 'WEAPON_MINISMG', 1 },\n { 'ammo-9', 69 },\n { 'water', 2, { label = 'Mineral water' } }\n }\n})\nTriggerClientEvent('ox_inventory:openInventory', 1, 'stash', mystash)","customdrop#CustomDrop":"Drops can be created from other resources, containing a variety of items and utilising a custom label (instead of 'Drop 32648').\nexports.ox_inventory:CustomDrop(prefix, items, coords, slots, maxWeight, instance, model)\nprefix: string\nitems: table\nname: string\ncount: number\nmetadata?: table\ncoords: vector3\nslots?: number\nmaxWeight?: number\ninstance?: string or number\nmodel?: number\n-- Create a generic drop with a marker\nexports.ox_inventory:CustomDrop('Carcass', {\n {'meat', 5, { grade = 2, type = 'deer' }},\n {'hide', 5, { grade = 2, type = 'deer' }}\n}, coords)\n-- Create a drop with an entity\nexports.ox_inventory:CustomDrop('SMG', {\n { 'WEAPON_MINISMG', 1 },\n { 'ammo-9', 69 },\n}, GetEntityCoords(GetPlayerPed(1)), 5, 10000, nil, `w_sb_minismg`)","createdropfromplayer#CreateDropFromPlayer":"Creates a new drop with the contents of a player's inventory.\nexports.ox_inventory:CreateDropFromPlayer(playerId)\nplayerId: number\nReturn:\ndropId: string\nExample\nlocal dropId = exports.ox_inventory:CreateDropFromPlayer(1)","getcurrentweapon#GetCurrentWeapon":"Returns the player's currently equipped weapon as a table.\n-- inv: string or number\nexports.ox_inventory:GetCurrentWeapon(inv)\ninv: table or string or number","setdurability#SetDurability":"Sets durability onto the specified slot.Can be used for repairing weapons.\nexports.ox_inventory:SetDurability(inv, slot, durability)\ninv: table or string or number\nslot: number\ndurability: number\nExample\nlocal ox_inventory = exports.ox_inventory\n-- Set the durability of the item in slot 3 of source player's inventory to 100\nox_inventory:SetDurability(source, 3, 100)\n-- Set the durability of the source player's current weapon to 100\nlocal weapon = ox_inventory:GetCurrentWeapon(source)\nif weapon then\n ox_inventory:SetDurability(source, weapon.slot, 100)\nend","setmetadata#SetMetadata":"Sets metadata on the specified slot.\nox_inventory:SetMetadata(inv, slot, metadata)\ninv: table or string or number\nslot: number\nmetadata: table\nExample\nlocal ox_inventory = exports.ox_inventory\nlocal water = ox_inventory:Search(source, 1, 'water')\nfor k, v in pairs(water) do\n print('\\n______________'..'\\n- index '..k)\n print(v.name, 'slot: '..v.slot, 'metadata: '..json.encode(v.metadata))\n water = v\n break\nend\nwater.metadata.type = 'clean'\nox_inventory:SetMetadata(source, water.slot, water.metadata)\nprint(('modified %sx water in slot %s with new metadata'):format(water.count, water.slot))"}},"/ox_inventory/Guides/crafting":{"title":"Crafting","data":{"":"Crafting locations, items and their ingredients are defined in data/crafting.lua.","crafting-definition#Crafting definition":"{\n items = {\n {\n name = 'lockpick',\n ingredients = {\n garbage = 3,\n WEAPON_HAMMER = 0.1\n },\n duration = 5000,\n count = 3,\n metadata = { durability = 20 }\n },\n {\n name = 'garbage',\n ingredients = {\n cola = 1\n },\n metadata = { description = 'An empty soda can.', weight = 20, image = 'trash_can' }\n },\n },\n points = {\n vec3(-1147.083008, -2002.662109, 13.180260),\n },\n zones = {\n {\n coords = vec3(-1146.2, -2002.05, 13.2),\n size = vec3(3.8, 1.05, 0.15),\n distance = 1.5,\n rotation = 315.0,\n },\n },\n blip = { id = 566, colour = 31, scale = 0.8 },\n},\nitems: table\nname: string\ningredients: table\nItem ingredients can be seen in the item tooltip.\nKey-value pairs of item name and consume count\nkey - Item name.\nvalue - If 1 or above it's the consume count, if below 1 and above 0 it's the durability consume amount, if\nset to 0 then the item is required but not consumed.\nduration: number\nCrafting duration in milliseconds.\ncount: number or table (min, max)\nItem amount received upon crafting.\nIf set it to table it requires two number first one is minimum number and second one is maximum, it will generate a random number between those two numbers to add the crafted item to player.\nmetadata: table\nMetadata applied to the item being crafted.\npoints: vector3[]\nInteraction locations that will open the crafting inventory.\ngroups: table\nKey-value pairs of job name and minimum grade to access the crafting location.\n{[\"police\"] = 0, [\"ambulance\"] = 2}\nzones: table\nox_lib targeting zones used for ox_target.\ncoords: vector3\nsize: vector3\ndistance: number\nrotation: number\nblip: table\nid: number\nBlip sprite number.\ncolour: number\nscale: number"}},"/ox_inventory/Guides/creatingItems":{"title":"Creating Items","data":{"defining-item-data#Defining item data":"Before being able to see or use an item in game it must first be defined.All of the items are defined in the /data/items.lua file with key, value pairs.\nKey is the name (not the label) of an item and the value is a table containing the\noptions for the item.\nItem options: table\nlabel: string\nweight?: number\nstack?: boolean\nIf set to false will not allow the item to be stacked.\ndegrade?: number\nAmount of time in minutes the item will degrade after.\ndecay?: boolean\nIf true the item will be deleted when durability reaches 0 (not instant for degraded items).\nclose?: boolean\nIf set to false does not close the inventory on item use.\ndescription?: string\nItem description that will be shown in the tooltip\nconsume?: number\nItem count needed and removed use.\nDefault: 1\nIf set to a decimal will consume durability instead (0.2 = 20%).\nallowArmed?: boolean\nIf set to true will allow use of item while armed with a weapon.\nserver?: table\nexport?: string\nclient?: table\nexport?: string\nExport to be triggered after item use.\nevent?: string\nEvent to be triggered after item use.\nstatus?: table\nAdjust esx_status values after use.\nanim?: table\nAnimation that will be played during the progress bar.\ndict: string\nclip: string\nprop?: table\nAttached prop that will be displayed during the progress bar.\nmodel: string or hash\npos: table (x, y, z)\nrot: table (x, y, z)\ndisable?: table\nActions to be disabled during the progress bar.\nmove?: boolean\ncar?: boolean\ncombat?: boolean\nmouse?: boolean\nsprint?: boolean\nusetime?: number\ncancel?: boolean\nIf set to true the player canc cancel item use.\nadd?: function(total: number)\nFunction that triggers when receiving an item\nReturns total item count as total\nremove?: function(total: number)\nFunction that triggers when removing an item\nReturns total item count as total\nbuttons?: table\nlabel: string\naction: function(slot: number)\nCallback function when button is clicked in context menu, returns item slot.","examples#Examples":"['burger'] = {\n label = 'Burger',\n weight = 220,\n stack = true,\n close = true,\n client = {\n status = { hunger = 200000 },\n anim = { dict = 'mp_player_inteat@burger', clip = 'mp_player_int_eat_burger_fp' },\n prop = {\n model = 'prop_cs_burger_01',\n pos = { x = 0.02, y = 0.02, y = -0.02},\n rot = { x = 0.0, y = 0.0, y = 0.0}\n },\n usetime = 2500,\n }\n}\nA modified burger item which includes a description.\n['burger'] = {\n label = 'Burger',\n description = 'Just what is the secret formula?'\n weight = 220,\n stack = true,\n close = true,\n client = {\n status = { hunger = 200000 },\n anim = { dict = 'mp_player_inteat@burger', clip = 'mp_player_int_eat_burger_fp' },\n prop = {\n model = 'prop_cs_burger_01',\n pos = { x = 0.02, y = 0.02, y = -0.02},\n rot = { x = 0.0, y = 0.0, y = 0.0}\n },\n usetime = 2500,\n }\n}\nA modified burger item, which gives you notifications on add and remove arguments.\n['burger'] = {\n label = 'Burger',\n weight = 220,\n stack = true,\n consume = 0,\n client = {\n add = function(total)\n if total > 0 then\n lib.notify({description = 'Nice burger you got there!'})\n end\n end,\n remove = function(total)\n if total < 1 then\n lib.notify({description = 'You lost all of your burgers!'})\n end\n end\n }\n}","making-the-item-usable#Making the item usable":"If you are using ESX, you can continue using ESX.RegisterUsableItem.\nIf you are using QBCore, you can continue using QBCore.Functions.CreateUseableItem.\nUsing the built-in system is more secure and provides much more functionality.","client-callbacks#Client callbacks":"Item callbacks can be added by defining an export (recommended), or by adding it to items/client.lua.When defining item data, adding client.export will trigger an event on item use.\nThe correct formatting is export = resourceName.exportName.\nexports('bandage', function(data, slot)\n local playerPed = PlayerPedId()\n local maxHealth = GetEntityMaxHealth(playerPed)\n local health = GetEntityHealth(playerPed)\n -- Does the ped need to heal? We can cancel the item from being used.\n if health < maxHealth then\n -- Triggers internal-code to correctly use items.\n -- This adds security, removes the item on use, adds progressbar support, and is necessary for server callbacks.\n exports.ox_inventory:useItem(data, function(data)\n -- The server has verified the item can be used.\n if data then\n SetEntityHealth(playerPed, math.min(maxHealth, math.floor(health + maxHealth / 16)))\n lib.notify({description = 'You feel better already'})\n end\n end)\n else\n -- Don't use the item\n lib.notify({type = 'error', description = 'You don\\'t need a bandage right now'})\n end\nend)","server-callbacks#Server callbacks":"A callback function can be defined on the server to handle several events (usingItem, usedItem, buyItem).\nThis can either be an export (recommended), or added to the bottom of items/server.lua.\nWhen defining item data, adding server.export will trigger an event for the actions above.\nThe correct formatting is export = resourceName.exportName.\nexports('bandage', function(event, item, inventory, slot, data)\n -- Player is attempting to use the item.\n if event == 'usingItem' then\n local playerPed = GetPlayerPed(inventory.id)\n local maxHealth = GetEntityMaxHealth(playerPed)\n local health = GetEntityHealth(playerPed)\n -- Check if the player needs to be healed.\n if health >= maxHealth then\n TriggerClientEvent('ox_lib:notify', inventory.id, {type = 'error', description = 'You don\\'t need a bandage right now'})\n -- Returning 'false' will prevent the item from being used\n return false\n end\n return\n end\n -- Player has finished using the item.\n if event == 'usedItem' then\n return TriggerClientEvent('ox_lib:notify', inventory.id, {description = 'You feel better already'})\n end\n -- Player is attempting to purchase the item.\n if event == 'buying' then\n return TriggerClientEvent('ox_lib:notify', inventory.id, {type = 'success', description = 'You bought a bandage'})\n end\nend)","creating-container-items#Creating container items":"Like with other items the item must first be registered.When registered you can define the item as a container in /modules/items/containers.lua\nThe key for the container is the name you gave it when registering the item.\nYou can also define the number of slots, the maximum weight, blacklist and whitelist items.\nitemName:\nslots: number\nThe number represents the amount of slots\nmaxWeight: number\nThe number represents the maximum weight within the container\nblacklist:\nSupports single and multiple items\n{ 'testburger', 'testburger2' }\nwhitelist:\nSupports single and multiple items\n{ 'testburger', 'testburger2' }","example#Example":"['paperbag'] = {\n label = 'Paper Bag',\n weight = 1,\n stack = false,\n close = false,\n consume = 0\n},\nsetContainerProperties('paperbag', {\n\tslots = 5,\n\tmaxWeight = 1000,\n\tblacklist = { 'testburger' }\n})"}},"/ox_inventory/Guides/metadata":{"title":"Metadata","data":{"":"Item metadata is a very powerful tool that can be used to create multiple different items out of a single item.In this guide we'll use pokemon cards as an example, but you can find an already integrated example in the inventory\nwith the garbage item.","creating-the-base-item#Creating the base item":"First of all we need to create a base item that we'll use to apply metadata to.\n['pokemon_card'] = {\n label = 'Pokemon card',\n weight = 10,\n consume = 0,\n server = {\n export = 'pokemon.pokemon_card'\n }\n}\nIn this case we define the label and the weight as well since we are going to have all the cards weigh the same, but if you\ndo not want them all to weigh the same you can leave it out and apply weight through metadata.We'll also make the item usable by calling the pokemon_card export in the pokemon resource.\nexports('pokemon_card', function(event, item, inventory, slot, data)\n if event == 'usingItem' then\n local itemSlot = exports.ox_inventory:GetSlot(inventory.id, slot)\n print(json.encode(itemSlot.metadata, {indent=true}))\n end\nend)","special-metadata-properties#Special metadata properties":"You can define any metadata property with any value you want it to have, but there are a couple metadata properties that\nhave special use cases.These properties are:\nlabel: string\nDisplay name of the item\nweight: number\nAmount the item will weigh\ndescription: string\nDescription of the item that will be displayed in the tooltip\nimage: string\nImage inside the image path that the item will use\nimageurl: string\nUrl to the image that the item will use\ntype: any\nItem type that is displayed in top right of the tooltip\nWe'll use these properties to create our pokemon cards out of the pokemon_card item that we created earlier.","creating-metadata-items#Creating metadata items":"We can easily create metadata items by defining a hook using createItem and adding it to a shop as well.\ninventory = {\n {name = 'pokemon_card', price = 300, metadata = {\n label = 'Charizard',\n description = 'It is said that Charizard’s fire burns hotter if it has experienced harsh battles.',\n image = 'panties',\n type = 'Fire',\n hp = 78,\n attack = 84,\n defense = 78\n }}\n}\nlocal pokemonMetadata = {\n charizard = {\n label = 'Charizard',\n description = 'It is said that Charizard’s fire burns hotter if it has experienced harsh battles.',\n image = 'panties',\n type = 'Fire',\n hp = 78,\n attack = 84,\n defense = 78\n }\n}\nlocal hookId = exports.ox_inventory:registerHook('createItem', function(payload)\n local pokemon = pokemonMetadata[payload.metadata.type]\n if not pokemon then return end\n return pokemon\nend, {\n itemFilter = {\n pokemon_card = true\n }\n})\nAs seen above when our item is usable, the metadata properties are all there and accessible through the slot.","displaying-custom-metadata-properties#Displaying custom metadata properties":"We can display our custom metadata we set on our charizard card by either using string concatenation and adding them to\nthe description or by using the displayMetadata client function.\nexports.ox_inventory:displayMetadata({\n hp = 'HP',\n attack = 'ATK',\n defense = 'DEF'\n})"}},"/ox_inventory/Guides/stashes":{"title":"Custom Stashes","data":{"":"We can set up custom stashes from outside the resource utilising the exported RegisterStash function.Firstly, we need to define the stashes properties.","stash-properties#Stash properties":"id: string\nUnique name to identify the stash in the database.\nlabel: string\nDisplay name when viewing the stash.\nslots: number\nNumber of slots the stash will have.\nweight: number\nMaximum weight of the stash inventory.\nowner?: string or boolean\ntrue: Each player has their own unique stash, but can request to open the stash of another player\nfalse: Only a single stash exists and is shared between all players\nstring: The stash explicitly belongs to the given owner, usually a player identifier\ngroups?: table\nKey-value pairs of job name and minimum grade to be able to access the stash. ({[\"police\"] = 0, [\"ambulance\"] = 2})\nname: string\ngrade: number\ncoords?: vector3 or table\nYou can set the stash coordinates to prevent the stash from being opened if the player isn't close enough.\nVector or table containing the coordinates of the stash.","example#Example":"Below the value is hardset, but it could be loaded from the database (especially if there are unknown fields, i.e. owner)\n-- Server\nlocal stash = {\n id = '42wallabyway',\n label = '42 Wallaby Way',\n slots = 50,\n weight = 100000,\n owner = 'char1:license'\n}\nAddEventHandler('onServerResourceStart', function(resourceName)\n if resourceName == 'ox_inventory' or resourceName == GetCurrentResourceName() then\n exports.ox_inventory:RegisterStash(stash.id, stash.label, stash.slots, stash.weight, stash.owner)\n end\nend)\n-- Client\nexports.ox_inventory:openInventory('stash', {id='42wallabyway', owner=property.owner})\nThe following sample is based on esx_property's db data.\n-- Server\nlocal properties\nMySQL.query('SELECT * FROM `properties`', {}, function(result)\n properties = result\nend\nRegisterNetEvent('ox:loadStashes', function(id)\nlocal stash = properties[id]\n if stash then\n -- id: 1, name: WhispymoundDrive, label: 2677 Whispymound Drive, coords: {\"x\":118.748,\"y\":566.573,\"z\":175.697}\n ox_inventory:RegisterStash(stash.name, stash.label, 50, 100000, true, false, json.encode(stash.room_menu))\n end\nend)\n-- Client\nlocal ox_inventory = exports.ox_inventory\nif ox_inventory:openInventory('stash', property.id) == false then\n TriggerServerEvent('ox:loadStashes')\n ox_inventory:openInventory('stash', property.id)\nend","example-resource#Example Resource":"We put together an example resource showcasing how to properly utilise the stash API:"}},"/ox_inventory/issues":{"title":"Common Issues","data":{"ui-has-not-been-built#UI has not been built":"Because the UI for inventory is written in React it can't run natively under FiveM so it must first be bundled into html/css/js.We provide an easy way for you to do this by downloading a pre-bundled release, which you can get from here.\nMake sure you download the ox_inventory.zip file as that one contains the bundled files and others are raw source code.If in case you wanted to edit the inventory UI you would have to build these files yourself.\nTo do so please read our Installation guide.","no-such-export--in-resource-ox_inventory#No such export * in resource ox_inventory":"There are several likely causes for this \"issue\".\nAn error occurred while starting ox_inventory or one of its dependencies (e.g. ox_lib).\nThe resource trying to use the export (e.g. esx_addoninventory) is being started before ox_inventory.\nYou're literally trying to call an export that does not exist, which is a you issue.","stashes--trunks-are-not-saved-at-server-restart#Stashes / trunks are not saved at server restart":"Stopping a server or \"restarting\" it does not trigger any events or allow for saving.\nInventories are saved at a 5 minute interval.\ntxAdmin scheduled restarts and shutdowns will trigger a save.\nThe saveinv command can be used manually or triggered in the console.\nAll inventories are saved when the number of online players hits 0."}},"/ox_lib":{"title":"Ox Lib","data":{"":"A standalone library for providing easily reusable code as importable modules and exports.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","download-a-release-or-build-the-source-code#Download a release or build the source code.":"git clone https://github.com/overextended/ox_lib.git\ncd ox_lib/web\npnpm i\npnpm build","config#Config":"Resource configuration is handled using convars.\n# https://v6.mantine.dev/theming/colors/#default-colors\nsetr ox:primaryColor blue\nsetr ox:primaryShade 8\nYou'll also need to grant ace permissions to the resource.\nadd_ace resource.ox_lib command.add_ace allow\nadd_ace resource.ox_lib command.remove_ace allow\nadd_ace resource.ox_lib command.add_principal allow\nadd_ace resource.ox_lib command.remove_principal allow","usage#Usage":"To enable the library inside of your resource just add @ox_lib/init.lua as a shared_script in your fxmanifest.lua file.\nshared_scripts {\n '@ox_lib/init.lua',\n}\nOr if the library is the only shared script you use you can do:\nshared_script '@ox_lib/init.lua'\nYou can specify modules to import from inside your fxmanifest.lua, or load them dynamically.\nox_libs {\n 'locale',\n 'math',\n 'table',\n}\nWhen ox_lib has been imported into your script, it will make several new globals available:\nlib for dynamically importing ox_lib modules into your script.\nrequire for importing modules from your own script.\ncache see here.\nNpm package for the lib does not support all the functions that are available for Lua.All supported functions are located inside the resource folder in the lib.\nYou can get the npm package here.Usage:\nYou can either import the whole library object which contains all the functions for that scope (client/server/shared) or you can deconstruct it and import the functions you find needed at the time.\nimport lib from '@overextended/ox_lib/server';\nimport { versionCheck } from '@overextended/ox_lib/server';\nYou can now use the library functions inside of your resource, check the rest of the documentation to see how to utilise them.","using-icons-for-interface-functions#Using icons for interface functions":"The icon library used is Font Awesome 6.0, if for the icon you define only a string the default icon type will be solid.\nIf you want to use a different icon type, i.e apple as a brand, you need to define icon as a table (array) with the first value being the icon type (fas, far, fab) as a string, and the second being the icon name.\nicon = {'fab', 'apple'}\nicon: ['fab', 'apple'];","building-the-ui#Building the UI":"If you wish to edit any of the UI elements you will need to download the source code, edit what you need and then compile it.\nDO NOT de-bundle and un-minify the release CSS and JS files to edit them.\nRequirements:\nNode.js (LTS)\npnpm\nInstalling Node.js:\nDownload the LTS version of Node.js.\nGo through the install and make sure you install all of the features.\nRun node --version in cmd and make sure that it gives you the version number. If it doesn't then you didn't install it correctly.\nInstalling pnpm:\nAfter installing NodeJS you can install pnpm by running npm install -g pnpm.\nBuilding the UI:\ncd into the web directory.\nrun pnpm i to install the dependencies.\nrun pnpm build to build the source files.\nWhen working in the browser you can run pnpm start, which supports hot reloads meaning that\nyou will see your changes after saving your file.If you want to work in game you can run pnpm start:game which writes changes to disk, so\nthe only thing you have to do is restart the resource for it take affect."}},"/ox_lib/Modules/ACL/Server":{"title":"Server","data":{"":"Wrapper around the built-in ACL system. Handles lib.addCommand and ox_groups permissions.\nRefer to Basic Aces & Principals overview/guide for more information.","libaddace#lib.addAce":"Assigns the ace permission to a principal. Third parameter defaults to 'allow', while passing false sets the permission to 'deny'.\nlib.addAce(principal, ace, allow)\nlib.addAce('group.admin', 'command.say')\nimport lib from '@overextended/ox_lib/server'\nlib.addAce(principal, ace, allow)\nlib.addAce('group.admin', 'command.say')\nprincipal: string\nace: string\nallow: boolean","libremoveace#lib.removeAce":"Removes the ace permission from a principal. Third parameter defaults to 'allow', while passing false sets the permission to 'deny'.\nlib.removeAce(principal, ace, allow)\nlib.removeAce('group.admin', 'command.say')\nimport lib from '@overextended/ox_lib/server'\nlib.removeAce(principal, ace, allow)\nlib.removeAce('group.admin', 'command.say')\nprincipal: string\nace: string\nallow: boolean","libaddprincipal#lib.addPrincipal":"Assigns a principal to a parent principal. Children inherit permissions from the parent.\nlib.addPrincipal(child, parent)\nlib.addPrincipal('player.1', 'group.moderator')\nimport lib from '@overextended/ox_lib/server'\nlib.addPrincipal(child, parent)\nlib.addPrincipal('player.1', 'group.moderator')\nchild: string\nparent: string","libremoveprincipal#lib.removePrincipal":"Removes a principal from a parent principal.\nlib.removePrincipal(child, parent)\nlib.removePrincipal('player.1', 'group.moderator')\nimport lib from '@overextended/ox_lib/server'\nlib.removePrincipal(child, parent)\nlib.removePrincipal('player.1', 'group.moderator')\nchild: string\nparent: string"}},"/ox_lib/Modules/AddCommand/Server":{"title":"Server","data":{"":"Registers commands and simplifies argument validation, permissions, and chat suggestions.\nlib.addCommand(commandName, properties, cb)\ncommandName: string or string[]\nproperties: table or false\nhelp?: string\nrestricted?: boolean or string or string[]\nparams?: table[]\nname: string\nhelp?: string\ntype?: 'number' or 'playerId' or 'string'\noptional?: boolean\nlib.addCommand('giveitem', {\n help = 'Gives an item to a player',\n params = {\n {\n name = 'target',\n type = 'playerId',\n help = 'Target player\\'s server id',\n },\n {\n name = 'item',\n type = 'string',\n help = 'Name of the item to give',\n },\n {\n name = 'count',\n type = 'number',\n help = 'Amount of the item to give, or blank to give 1',\n optional = true,\n },\n {\n name = 'metatype',\n help = 'Sets the item\\'s \"metadata.type\"',\n optional = true,\n },\n },\n restricted = 'group.admin'\n}, function(source, args, raw)\n local item = Items(args.item)\n if item then\n Inventory.AddItem(args.target, item.name, args.count or 1, args.metatype)\n end\nend)"}},"/ox_lib/Modules/AddKeybind/Client":{"title":"Client","data":{"":"Registers keybinds and simplifies interactions of the keybinds.","ckeybind-class#CKeybind Class":"A table representing a keybind with the following properties.\nname: string\ndescription: string\ncurrentKey: string\nKey that the current user has this keybind set to\ndisabled: boolean\nWhether or not the keybind is currently disabled\nhash: number\nInternal hash of the keybind that is used to reference it within the game itself\ndefaultKey?: string\nDefault key to set the keybind to for new players\nNOTE: Changing this will not change the key for existing players\ndefaultMapper?: string\nSee Input Mapper Ids for more information\nsecondaryKey?: string\nAn optional secondary keybind.\nsecondaryMapper?: string\nAn optional mapper for the secondary key, otherwise using the default mapper.\ndisable: function(self: CKeybind, disable: boolean)\nBuilt-in function to enable / disable a keybind\nonPressed?: function(self: CKeybind)\nUser-defined function triggered on keybind press\nonReleased?: function(self: CKeybind)\nUser-defined function triggered on keybind release","libaddkeybind#lib.addKeybind":"lib.addKeybind(data)\ndata: table\nname: string\ndescription: string\ndefaultKey?: string\nDefault: None\ndefaultMapper?: string\nDefault: keyboard\nsecondaryKey?: string\nsecondaryMapper?: string\ndisabled?: boolean\nWhether or not the keybind should be disabled by default\nonPressed?: function(self: CKeybind)\nFunction triggered on keybind press\nonReleased?: function(self: CKeybind)\nFunction triggered on keybind release\nlocal keybind = lib.addKeybind({\n name = 'respects',\n description = 'press F to pay respects',\n defaultKey = 'F',\n onPressed = function(self)\n print(('pressed %s (%s)'):format(self.currentKey, self.name))\n end,\n onReleased = function(self)\n print(('released %s (%s)'):format(self.currentKey, self.name))\n end\n})","enable--disable-keybinds#Enable / Disable Keybinds":"Keybinds can be enabled / disabled by using the disable method.\nkeybind:disable(true) -- disables the keybind\nkeybind:disable(false) -- enables the keybind"}},"/ox_lib/Modules/Cache/Shared":{"title":"Shared","data":{"":"A table containing cached function results, which may be constants or infrequently changed.","default-values#Default values":"resource: string\nthe value returned by GetCurrentResourceName.\ngame: 'fxserver' | 'fivem' | 'redm'\nthe value returned by GetGameName.","adding-new-cached-values#Adding new cached values":"Values can be cached permanently, or added with a timeout.\ncache(key, func, timeout)\nkey: string\na unique name to store and access the cached state.\nfunc: function\na function to call when the cache is invalidated/empty.\ntimeout?: number\na timer in milliseconds to clear the cached state.\nlocal i = 0\nwhile true do\n Wait(1000)\n i += 1\n print(cache('test', function() return i end, 5000))\nend\n-- output:\n> 1\n> 1\n> 1\n> 1\n> 1\n> 6\n> 6\n> 6"}},"/ox_lib/Modules/Callback/JavaScript/Client":{"title":"Client","data":{"trigger-server-callback#Trigger Server Callback":"","triggerservercallback#triggerServerCallback":"triggerServerCallback(eventName, delay, ...args)\neventName: string\ndelay: number or null\nAmount of time until this callback can be triggered again\n..args: any","register-client-callback#Register Client Callback":"","onservercallback#onServerCallback":"onServerCallback(eventName, cb)\neventName: string\ncb: function(...args: any)","usage-example#Usage Example":"For this example to fully make sense take a look at the example on the server page for the callbacks.\nimport { onServerCallback, triggerServerCallback } from '@overextended/ox_lib/client'\nonServerCallback('test:client', (...args: [number, number, string]) => {\n console.log(args);\n return {\n clientValue: 'Value from the client',\n };\n});\nsetTimeout(async () => {\n const args = [1, null, 3, null, null, 6];\n const response = await triggerServerCallback<{ serverValue: number }>('test:server', 1, args);\n if (!response) return;\n console.log('Response from server', response);\n}, 100);"}},"/ox_lib/Modules/Callback/JavaScript/Server":{"title":"Server","data":{"trigger-client-callback#Trigger Client Callback":"","triggerclientcallback#triggerClientCallback":"triggerClientCallback(eventName, playerId, ...args)\neventName: string\nplayerId: number\n...args: any","register-server-callback#Register Server Callback":"","onclientcallback#onClientCallback":"onClientCallback(eventName, cb)\neventName: string\ncb: function(playerId: number, ...args: any)","usage-example#Usage Example":"For this example to fully make sense take a look at the example on the client page for the callbacks.\nimport { onClientCallback, triggerClientCallback } from '@overextended/ox_lib/server';\nonClientCallback('test:server', (playerId, ...args: [number, null, number, null, null, number]) => {\n console.log('onClientCallback', playerId, ...args);\n return {\n serverValue: 3000,\n };\n});\nsetTimeout(async () => {\n const response = await triggerClientCallback<{ clientValue: string }>('test:client', 1, [1, null, 3, null, null, 6])\n if (!response) return;\n console.log(response.clientValue);\n console.log('Response from client', response);\n}, 100);"}},"/ox_lib/Modules/Callback/Lua/Client":{"title":"Client","data":{"trigger-server-callback#Trigger Server Callback":"","libcallback#lib.callback":"The response is handled in a separate coroutine.\nlib.callback(name, delay, cb, ...)\nname: string\ndelay: number or false\nAmount of time until this callback can be triggered again\ncb: function\n...: any\nlib.callback('ox_inventory:getItemCount', false, function(count)\n print(count)\nend, 'water', {type = 'fresh'})","libcallbackawait#lib.callback.await":"The current coroutine is yielded until a response is received.\nlib.callback.await(name, delay, ...)\nname: string\ndelay: number or false\nAmount of time until this callback can be triggered again\n...: any\nlocal count = lib.callback.await('ox_inventory:getItemCount', false, 'water', {type = 'fresh'})\nprint(count)","register-client-callback#Register Client Callback":"","libcallbackregister#lib.callback.register":"Register an event handler for responding to server requests.\nlib.callback.register(name, cb)\nname: string\ncb: function\nlib.callback.register('ox:getNearbyVehicles', function(radius)\n local nearbyVehicles = lib.getNearbyVehicles(GetEntityCoords(cache.ped), radius, true)\n return nearbyVehicles\nend)"}},"/ox_lib/Modules/Callback/Lua/Server":{"title":"Server","data":{"trigger-client-callback#Trigger Client Callback":"","libcallback#lib.callback":"The response is handled in a separate coroutine.\nlib.callback(name, playerId, cb, ...)\nname: string\nplayerId: number\ncb: function\n...: any\nlib.callback('ox:getNearbyVehicles', source, function(vehicles)\n for i = 1, #vehicles do\n DeleteEntity(entity)\n end\nend, args.radius)","libcallbackawait#lib.callback.await":"The current coroutine is yielded until a response is received.\nlib.callback.await(name, playerId, ...)\nname: string\nplayerId: number\n...: any\nlocal vehicles = lib.callback.await('ox:getNearbyVehicles', source, args.radius)\nfor i = 1, #vehicles do\n DeleteEntity(entity)\nend","register-server-callback#Register Server Callback":"","libcallbackregister#lib.callback.register":"Register an event handler for responding to client requests.\nlib.callback.register(name, cb)\nname: string\ncb: function\nlib.callback.register('ox_inventory:getItemCount', function(source, item, metadata, target)\n local inventory = target and Inventory(target) or Inventory(source)\n return (inventory and Inventory.GetItem(inventory, item, metadata, true)) or 0\nend)"}},"/ox_lib/Modules/Class/Shared":{"title":"Shared","data":{"libclass#lib.class":"Creates a new class.\nlocal MyClass = lib.class(name, super)\nname: string\nsuper?: table\nSets the new class as a subset of the super class, inheriting its methods and fields.\nReturn:\nclass: table\ntodo: more class info blah, look at the example","example#Example":"local fruits = {}\nlocal Fruit = lib.class('Fruit')\nfunction Fruit:init()\n print(('Created a %s %s'):format(self:getColour(), self:getName()))\n fruits[self.name] = self\nend\nfunction Fruit:remove()\n print('Removed', self:getName(), self)\n fruits[self.name] = nil\nend\nfunction Fruit:getName() return self.name end\nfunction Fruit:getColour() return self.colour end\nfunction Fruit:getSeeds() return self.private.seeds end\n-- Inherits methods and properties from the Fruit class.\nlocal SpoiledFruit = lib.class('SpoiledFruit', Fruit)\nfunction SpoiledFruit:getStench() return self.stench end\nCreateThread(function()\n local apple = Fruit:new({\n name = 'apple',\n colour = math.random(0, 1) == 1 and 'red' or 'green'\n })\n local orange = Fruit:new({\n name = 'orange',\n colour = 'orange',\n -- the private table is not serialisable (data is hidden cross-resource)\n private = {\n seeds = 7\n }\n })\n print(('the apple is %s; the orange contains %d seeds'):format(apple:getColour(), orange:getSeeds()))\n apple:remove()\n local rottenBanana = SpoiledFruit:new({\n name = 'banana',\n colour = 'black',\n stench = 'musty'\n })\n print(('the banana is %s and %s - gross!'):format(rottenBanana:getColour(), rottenBanana:getStench()))\nend)"}},"/ox_lib/Modules/Cron/Server":{"title":"Server","data":{"":"A Lua implementation of cron, allowing tasks to be scheduled to run periodically at fixed times, dates, and intervals.","cron-expression#Cron expression":"A string containing five values separated by white spaces, representing a set of times to execute a task.\nField\tValid values\tMinutes\t0-59\tHours\t0-23\tDay of month\t1-31\tMonth\t1-12 or jan-dec\tDay of week\t1-7 or sun-sat\t\nNote: Day of the week is set to match os.date and starts at 1, unlike the cron-standard which starts at 0.","-wildcards#* Wildcards":"Represents all values, e.g. * * * * * will run every minute, or * * * * 1 will run every minute on Sunday.","-lists#, Lists":"Commas can be used to create a list of values, e.g. * * * * sun,mon,tue will run every minute on Sunday, Monday, and Tuesday.","--ranges#- Ranges":"Dashes define a range of values, e.g. 10-30 * * * * will start running the task at the 10th minute, and every minute until the 30th minute.","-steps#/ Steps":"Slashes can be used for step values, e.g. * */4 * * * will run every 4 hours and is shorthand for * 0,4,8,12,16,20 * * *.","functions#Functions":"","libcronnew#lib.cron.new":"Creates a new cronjob, scheduling a task to run at fixed times or intervals.\nlib.cron.new(expression, job, options)\nexpression: string\nA cron expression such as * * * * * representing minute, hour, day, month, and day of the week\njob: fun(task: OxTask, date: osdate)\noptions?: table\ndebug?: boolean\nReturn:\ntask: OxTask"}},"/ox_lib/Modules/DisableControls/Client":{"title":"Client","data":{"":"A centralized way to track and disable controls.","libdisablecontrols#lib.disableControls":"Call on frame to disable all stored controls.\nlib.disableControls()","libdisablecontrolsadd#lib.disableControls:Add":"Adds the specified control(s) to the stored list.\nIf the control is already being tracked, the stored counter will be incremented.\nlib.disableControls:Add(...)\nvararg: number or table\nControl(s) to add a stored count of","libdisablecontrolsremove#lib.disableControls:Remove":"Removes the specified control(s) from the stored list.\nIf the stored counter for a given control is greater than one, the stored counter will be decremented.\nlib.disableControls:Remove(...)\nvararg: number or table\nControl(s) to remove a stored count of","libdisablecontrolsclear#lib.disableControls:Clear":"Clears the stored counter(s) for the specified control(s).\nlib.disableControls:Clear(...)\nvararg: number or table\nControl(s) to clear out from being tracked"}},"/ox_lib/Modules/GetClosestObject/Shared":{"title":"Shared","data":{"libgetclosestobject#lib.getClosestObject":"Get the object handle and coords of the closest object to a set of coordinates.\nlib.getClosestObject(coords, maxDistance)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nReturn:\nobject?: number\ncoords?: vector3"}},"/ox_lib/Modules/GetClosestPed/Shared":{"title":"Shared","data":{"libgetclosestped#lib.getClosestPed":"Get the ped handle and coords of the closest ped to a set of coordinates.\nlib.getClosestPed(coords, maxDistance)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nReturn:\nped?: number\ncoords?: vector3"}},"/ox_lib/Modules/GetClosestPlayer/Shared":{"title":"Shared","data":{"libgetclosestplayer#lib.getClosestPlayer":"Get the player id, ped handle, and coords of the closest player to a set of coordinates.\nlib.getClosestPlayer(coords, maxDistance, includePlayer)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nincludePlayer?: boolean\nWhether or not to include the current player. Ignored on the server.\nDefault: false\nReturn:\nplayerId?: number\nplayerPed?: number\nplayerCoords?: vector3"}},"/ox_lib/Modules/GetClosestVehicle/Shared":{"title":"Shared","data":{"libgetclosestvehicle#lib.getClosestVehicle":"Get the vehicle handle and coords of the closest vehicle to a set of coordinates.\nlib.getClosestVehicle(coords, maxDistance, includePlayerVehicle)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nincludePlayerVehicle?: boolean\nWhether or not to include the player's current vehicle. Ignored on the server.\nDefault: false\nReturn:\nvehicle?: number\nvehicleCoords?: vector3"}},"/ox_lib/Modules/GetNearbyPeds/Shared":{"title":"Shared","data":{"libgetnearbypeds#lib.getNearbyPeds":"Get the ped handle and coords of all peds within range of a set of coordinates.\nlib.getNearbyPeds(coords, maxDistance)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nReturn:\npeds: { ped: number, coords: vector3 }[]"}},"/ox_lib/Modules/GetNearbyObjects/Shared":{"title":"Shared","data":{"libgetnearbyobjects#lib.getNearbyObjects":"Get the object handle and coords of all objects within range of a set of coordinates.\nlib.getNearbyObjects(coords, maxDistance)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nReturn:\nobjects: { object: number, coords: vector3 }[]"}},"/ox_lib/Modules/GetNearbyPlayers/Shared":{"title":"Shared","data":{"libgetnearbyplayers#lib.getNearbyPlayers":"Get the player id, ped handle, and coords of all players within range of a set of coordinates.\nlib.getNearbyPlayers(coords, maxDistance, includePlayer)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nincludePlayer?: boolean\nWhether or not to include the current player. Ignored on the server.\nDefault: false\nReturn:\nplayers: { id: number, ped: number, coords: vector3 }[]"}},"/ox_lib/Modules/GetNearbyVehicles/Shared":{"title":"Shared","data":{"libgetnearbyvehicles#lib.getNearbyVehicles":"Get the vehicle handle and coords of all vehicles within range of a set of coordinates.\nlib.getNearbyVehicles(coords, maxDistance, includePlayerVehicle)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nincludePlayerVehicle?: boolean\nWhether or not to include the player's current vehicle. Ignored on the server.\nDefault: false\nReturn:\nvehicles: { vehicle: number, coords: vector3 }[]"}},"/ox_lib/Modules/Interface/Client/alert":{"title":"Alert Dialog","data":{"":"Simple alert dialog that can display a message to the player.\nReturns whether the player pressed the confirm button or canceled the dialog.","libalertdialog#lib.alertDialog":"lib.alertDialog(data)\nTriggerClientEvent('ox_lib:alertDialog', source, data)\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nimport lib from '@overextended/ox_lib/client';\nlib.alertDialog(data);\ndata: table (object)\nheader: string\nDialog title.\ncontent: string\nDialog body content, supports markdown.\ncentered?: boolean\nCenters the dialog vertically and horizontally.\ncancel?: boolean\nDisplays a cancel button (ESC is still available if this is not defined).\nsize?: 'xs' or 'sm' or 'md' or 'lg' or 'xl'\noverflow?: boolean\nlabels?: table\nAllows you to define the displayed labels for cancel and/or confirm buttons.\ncancel?: string\nconfirm?: string\nReturns 'confirm' if the player pressed the confirm button, otherwise if the player pressed the cancel button\nor has exited the dialog with ESC the return will be 'cancel'.","libclosealertdialog#lib.closeAlertDialog":"Force closes the active alert dialog and sets its return data as nil\nlib.closeAlertDialog()\nimport lib from '@overextended/ox_lib/client';\nlib.closeAlertDialog();","example#Example":"local alert = lib.alertDialog({\n header = 'Hello there',\n content = 'General Kenobi \\n Markdown support!',\n centered = true,\n cancel = true\n})\nprint(alert)\nimport lib from '@overextended/ox_lib/client';\nconst alert = await lib.alertDialog({\n header: 'Hello there',\n content: 'General Kenobi \\n Markdown support!',\n centered: true,\n cancel: true,\n});\nconsole.log(alert);"}},"/ox_lib/Modules/Interface":{"title":"Interface","data":{"":"If you wish to change the primary colour for the UI to better match your server's theme you can do so easily through the available convars.They don't require you to build the UI, just restart the resource.Convars:\nsetr ox:primaryColor blue\nsetr ox:primaryShade 8\nChanging the primary colour will change the colour in elements such as the progress bar/circle, skill check, radial menu center button and hover,\ndialog confirm buttons, input field focus, and more.You can find the full list of preset colours and shades here:https://v6.mantine.dev/theming/colors/#default-colorsIf you wish to create your own pallete I suggest following the guide on that page.\nKeep in mind doing so will require you to download the source code and build the UI."}},"/ox_lib/Modules/Interface/Client/clipboard":{"title":"Clipboard","data":{"libsetclipboard#lib.setClipboard":"Sets the player's clipboard to the specified string value.\nWill not work if focus is already taken by some NUI component.\nTo create a new line use \\t\\n not just \\n in your string.\nlib.setClipboard(value)\nimport lib from '@overextended/ox_lib/client';\nlib.setClipboard(value);\nvalue: string"}},"/ox_lib/Modules/Interface/Client/context":{"title":"Context Menu","data":{"libregistercontext#lib.registerContext":"Used for registering a context menu.\nlib.registerContext(context)\nimport lib from '@overextended/ox_lib/client';\nlib.registerContext(context);\nid: string\nUnique menu identifier, will be used to open the menu.\ntitle: string\nTitle display in the menu; has markdown support.\nmenu?: string\nMenu identifier - if defined there will be a back arrow next to the menu title that will take you to the menu you defined.\ncanClose: boolean\nIf set to false the user won't be able to exit the menu without pressing one of the buttons.\nonExit?: function\nFunction that will be ran when the user closes their context menu with ESC.\nonBack?: function\nFunction that will be ran when the user presses the back button to return to a previous menu.\noptions: table (object or array)\nitem: key (string) or table (object)\ntitle?: string\nIf not using keys then sets the title for the button; has markdown support.\ndisabled?: boolean\nGrays out the button and makes it unclickable.\nreadOnly? boolean\nRemoves all hover and active styles and disables onSelect if it's defined.\nmenu?: string\nMenu identifier that the button will take you to, when defined an arrow.\nonSelect: function\nFunction that's ran when the button is clicked.\nicon?: string\nFontAwesome icon that will be displayed on the left side, works the same as notification and textui icons.\nAlso supports image urls, png and webp files but are not recommend to use over font awesome icons.\niconColor?: string\nColour of the displayed icon.\niconAnimation?: 'spin' 'spinPulse' 'spinReverse' 'pulse' 'beat' 'fade' 'beatFade' 'bounce' 'shake'\nprogress?: number\nAdds a progress bar filled to this percentage\ncolorScheme?: string\nSets the color scheme of the progress bar. Current options can be found here:\nhttps://v6.mantine.dev/theming/colors/#default-colors\nFor example: blue or teal\narrow?: boolean\nShows an arrow on the right side like menu does, useful when you are opening a menu from an event. Can be set to false to hide it.\ndescription?: string\nDescription that will appear under the button title that is defined as a key; has markdown support.\nimage?: string\nUrl to an image that will be displayed in the button's metadata.\nmetadata?: string[] or object or array\nInformation that will display on the side upon hovering a button.\nlabel: string\nvalue: any\nprogress?: number\nDisplay a progress bar in the metadata.\ncolorScheme?: string\nSame as above.\nevent?: string\nEvent that the button is going to trigger.\nserverEvent?: string\nServer event that the button is going to trigger.\nargs?: any\nArguments that will be sent to the events or onSelect function.\nYou can register as many context menus in one lib.registerContext function\nas you'd like.The menu can be either in the order you write it in, or sorted alphabetically.\nTo sort the menu alphabetically the buttons (and/or metadata) need to be defined as keys, otherwise not using keys and instead using tables will make the menu be in the order you define it as.","libshowcontext#lib.showContext":"Opens a registered context menu by its id.\nlib.showContext(id)\nimport lib from '@overextended/ox_lib/client';\nlib.showContext(id);\nid: string","libhidecontext#lib.hideContext":"Hides any currently visible context menu.\nlib.hideContext(onExit)\nimport lib from '@overextended/ox_lib/client';\nlib.hideContext(onExit);\nonExit: boolean\nDefines whether the onExit function for the menu should be ran or not.","libgetopencontextmenu#lib.getOpenContextMenu":"Returns the id of the currently open context menu.If no context menu is open returns nil.\nlib.getOpenContextMenu()\nimport lib from '@overextended/ox_lib/client';\nlib.getOpenContextMenu();","usage-example#Usage Example":"First we register the menu with our specified options then we call the show function in the command.\nAvoid constantly re-registering a menu that does not depend on any outside values (A.K.A a static menu).\nlib.registerContext({\n id = 'some_menu',\n title = 'Some context menu',\n options = {\n {\n title = 'Empty button',\n },\n {\n title = 'Disabled button',\n description = 'This button is disabled',\n icon = 'hand',\n disabled = true\n },\n {\n title = 'Example button',\n description = 'Example button description',\n icon = 'circle',\n onSelect = function()\n print(\"Pressed the button!\")\n end,\n metadata = {\n {label = 'Value 1', value = 'Some value'},\n {label = 'Value 2', value = 300}\n },\n },\n {\n title = 'Menu button',\n description = 'Takes you to another menu!',\n menu = 'other_menu',\n icon = 'bars'\n },\n {\n title = 'Event button',\n description = 'Open a menu from the event and send event data',\n icon = 'check',\n event = 'test_event',\n arrow = true,\n args = {\n someValue = 500\n }\n }\n }\n})\nimport lib from '@overextended/ox_lib/client';\nlib.registerContext({\n id: 'some_menu',\n title: 'Some context menu',\n options: [\n {\n title: 'Empty button',\n },\n {\n title: 'Disabled button',\n description: 'This button is disabled',\n icon: 'hand',\n disabled: true,\n },\n {\n title: 'Example button',\n description: 'Example button description',\n icon: 'circle',\n onSelect: () => {\n console.log('Pressed the button!');\n },\n metadata: [\n { label: 'Value 1', value: 'Some value' },\n { label: 'Value 2', value: 300 },\n ],\n },\n {\n title: 'Menu button',\n description: 'Takes you to another menu!',\n menu: 'other_menu',\n icon: 'bars',\n },\n {\n title: 'Event button',\n description: 'Open a menu from the event and send event data',\n icon: 'check',\n event: 'test_event',\n arrow: true,\n args: {\n someValue: 500,\n },\n },\n ],\n});\nThen we can also register our second menu called other_menu\nlib.registerContext({\n id = 'other_menu',\n title = 'Other context menu',\n menu = 'some_menu',\n onBack = function()\n print('Went back!')\n end,\n options = {\n {\n title = 'Nothing here'\n }\n }\n})\nlib.registerContext({\n id: 'other_menu',\n title: 'Other context menu',\n menu: 'some_menu',\n onBack: () => {\n console.log('Went back!');\n },\n options: [\n {\n title: 'Nothing here',\n },\n ],\n});\nAnd the event that we are going to run from the some_menu menu, which is going to open another menu.\nRegisterNetEvent('test_event', function(args)\n lib.registerContext({\n id = 'event_menu',\n title = 'Event menu',\n menu = 'some_menu',\n options = {\n {\n title = 'Event value: '..args.someValue,\n }\n }\n })\n lib.showContext('event_menu')\nend)\nonNet('test_event', (args: { someValue: number }) => {\n lib.registerContext({\n id: 'event_menu',\n title: 'Event menu',\n menu: 'some_menu',\n options: [\n {\n title: `Event value: ${args.someValue}`,\n },\n ],\n });\n lib.showContext('event_menu');\n});\nLastly we register a test command to show the some_menu menu.\nRegisterCommand('testcontext', function()\n lib.showContext('some_menu')\nend)\nRegisterCommand('testcontext', () => {\n lib.showContext('some_menu');\n});\nThe data from the args table in the menu is passed as a first argument to the event you register.Using this event we also register a new context menu with it's own options.By defining a menu param to be the id of the first menu we can get the back arrow button next to the menu title that will take us back."}},"/ox_lib/Modules/Interface/Client/input":{"title":"Input Dialog","data":{"":"The input dialog window allows you to take data from the user by setting input fields.","libinputdialog#lib.inputDialog":"lib.inputDialog(heading, rows, options)\nimport lib from '@overextended/ox_lib/client';\nlib.inputDialog(heading, rows, options);\nheading: string\nrows: string[] or table (array)\ntype: 'input' or 'number' or 'checkbox' or 'select' or 'slider' or 'color' or 'multi-select' or 'date' or 'date-range' or 'time' or 'textarea'\noptions?: table(object)\nallowCancel: boolean\nIf false the user will not be able to cancel and close the input dialog until submitted.\nIf not defined, the user is able to cancel and close the input dialog.","field-type-properties#Field Type Properties":"input\nlabel: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string\npassword?: boolean\nmin?: number\nmax?: number\nnumber\nlabel: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: number\nmin?: number\nmax?: number\nprecision?: number\nstep?: number\ncheckbox\nlabel: string\nchecked?: boolean\ndisabled?: boolean\nrequired?: boolean\nselect and multi-select\nlabel: string\noptions: table(array)\nvalue: string\nlabel?: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string | table (only for multi-select)\nvalue of the default option.\nclearable?: boolean\nslider\nlabel: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: number\nmin?: number\nmax?: number\nstep?: number\ncolor\nlabel: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string\nformat?: 'hex' | 'hexa' | 'rgb' | 'rgba' | 'hsl' | 'hsla';\ndate\nlabel: string\ndescription?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string or true\nTrue defaults to current date\nformat?: string\nDate format to display in the field\nreturnString?: boolean\nReturns the date as a string, default format is DD/MM/YYYY, but if format is defined it will use that.\nclearable?: boolean\nmin?: string\n\"01/01/2000\"\nmax?: string\n\"12/12/2023\"\ndate-range\nlabel: string\ndescription?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: [string, string]\nformat?: string\nDate format to display in the field\nreturnString?: boolean\nReturns the date as a string, default format is DD/MM/YYYY, but if format is defined it will use that.\nclearable?: boolean\ntime\nlabel: string\ndescription?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string\nformat?: '12' or '24'\nclearable?: boolean\ntextarea\nlabel: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: number\nmin?: number\nMinimum amount of rows the text area will take.\nmax?: number\nMaxmimum amount of rows the text area will take, when exceeded goes into overflow.\nautosize?: boolean\nIf true text area will grow with content until max rows are reached.\nThe callback data is promise based meaning that the thread will not continue executing until the user either sends the data or exits the popup.The data returned will be a table (array), indexes represent the rows sent to the dialog, so if we want data from the first field that would be index 1 (0), if we want data from the third field, that would be index 3 (2), etc...\nField types such as date, date-range and time return a unix timestamp on the set value.","libcloseinputdialog#lib.closeInputDialog":"Force closes the active input dialog and sets its return data as nil.\nlib.closeInputDialog()\nimport lib from '@overextended/ox_lib/client';\nlib.closeInputDialog();","usage-example#Usage Example":"","basic#Basic":"local input = lib.inputDialog('Basic dialog', {'First row', 'Second row'})\nif not input then return end\nprint(json.encode(input), input[1], input[2])\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nconst input = await lib.inputDialog('Basic dialog', ['First row', 'Second row']);\nif (!input) return;\nconsole.log(input, input[0], input[1]);","advanced#Advanced":"local input = lib.inputDialog('Dialog title', {\n {type = 'input', label = 'Text input', description = 'Some input description', required = true, min = 4, max = 16},\n {type = 'number', label = 'Number input', description = 'Some number description', icon = 'hashtag'},\n {type = 'checkbox', label = 'Simple checkbox'},\n {type = 'color', label = 'Colour input', default = '#eb4034'},\n {type = 'date', label = 'Date input', icon = {'far', 'calendar'}, default = true, format = \"DD/MM/YYYY\"}\n})\nprint(json.encode(input))\n-- Getting rgb values from colour picker\nlocal rgb = lib.math.torgba(input[4])\n-- Transforming date timestamp to a readable format with Lua's os library (server-only)\nlocal timestamp = math.floor(input[5] / 1000)\nlocal date = os.date('%Y-%m-%d %H:%M:%S', timestamp)\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nconst input = await lib.inputDialog('Police locker', [\n { type: 'input', label: 'Text input', description: 'Some input description', required: true, min: 3, max: 16 },\n { type: 'number', label: 'Number input', description: 'Some number description', icon: 'hashtag' },\n { type: 'checkbox', label: 'Simple checkbox' },\n { type: 'color', label: 'Colour input', default: '#eb4034' },\n { type: 'date', label: 'Date input', icon: ['far', 'calendar'], default: true, format: 'DD/MM/YYYY' },\n]);\nconsole.log(JSON.stringify(input, null, 2));\n// Getting r, g and b values from colour picker\nconst regExp = /rgb\\((\\d+),\\s*(\\d+),\\s*(\\d+)\\)/;\nconst colourInput = input[3];\nconst color = regExp.exec(colourInput);\nif (!color) return;\nconsole.log(+color[1], +color[2], +color[3]);"}},"/ox_lib/Modules/Interface/Client/menu":{"title":"Menu","data":{"":"Keyboard navigation menu with specific event functions.","libregistermenu#lib.registerMenu":"Registers and caches a menu under the specified id.\nlib.registerMenu(data, cb)\nimport lib from '@overextended/ox_lib/client';\nlib.registerMenu(data, cb);\ndata: table (object)\nid: string\ntitle: string\noptions: table (array)\nlabel: string\nprogress?: number\ncolorScheme?: string\nicon?: string\nFontAwesome icon that will be displayed on the left side, works the same as notification and textui icons.\nAlso supports image urls, png and webp files but are not recommend to use over font awesome icons.\niconColor?: string\niconAnimation?: 'spin' 'spinPulse' 'spinReverse' 'pulse' 'beat' 'fade' 'beatFade' 'bounce' 'shake'\nvalues?: string[] or { label: string, description: string }[]\nIf provided creates a side scrollable list.\nWhen using object and setting description, the set description will be displayed in the menu tooltip.\nchecked?: boolean\nSetting either true or false will make the button a checkbox, if values is also provided the button will be a\nscrollable list.\ndescription?: string\nDisplays tooltip below menu on hovered item with provided description.\ndefaultIndex?: number\nSets the current index for the list to specified number.\nargs?: {[string]: any}\nAllows you to pass any arguments through the button.\nIf the button has values then isScroll is automatically passed.\nIf the button has checked to either true or false then isCheck is automatically passed.\nclose?: boolean\nIf set to false, it won't close the menu upon interacting with this option.\nposition?: 'top-left' or 'top-right' or 'bottom-left' or 'bottom-right'\nDefault: 'top-left'\ndisableInput?: boolean\nDefault: false\ncanClose: boolean\nIf set to false the user won't be able to exit the menu without pressing one of the buttons.\nonClose: function(keyPressed?: 'Escape' | 'Backspace')\nFunction that runs when the menu is exited via ESC/Backspace.\nonSelected: function(selected: number, secondary: number | boolean, args: {[string]: any})\nFunction being ran when the selected button in the menu changes.\nonSideScroll: function(selected: number, scrollIndex: number, args: {[string]: any})\nFunction ran whenever a scroll list item is changed.\nonCheck: function(selected: number, checked: boolean, args: {[string]: any})\nFunction ran whenever a checkbox is toggled.\ncb: function(selected: number, scrollIndex: number, args: {[string]: any})\nCallback function when the menu item is pressed.","libshowmenu#lib.showMenu":"Displays the menu with the provided id.\nlib.showMenu(id)\nimport lib from '@overextended/ox_lib/client';\nlib.showMenu(id);\nid: string","libhidemenu#lib.hideMenu":"lib.hideMenu(onExit)\nimport lib from '@overextended/ox_lib/client';\nlib.hideMenu(onExit);\nonExit?: boolean\nIf true runs the menu's onClose function.","libgetopenmenu#lib.getOpenMenu":"Returns the id of the currently open menu.\nlib.getOpenMenu()\nimport lib from '@overextended/ox_lib/client';\nlib.getOpenMenu();","libsetmenuoptions#lib.setMenuOptions":"lib.setMenuOptions(id, options, index)\nimport lib from '@overextended/ox_lib/client';\nlib.setMenuOptions(id, options, index);\nid: string\noptions: table (object or array)\nindex?: number\nIf specified only sets the options table on the specified options index.\nExample:\nReplaces the 3rd index option of the specified menu\nlib.setMenuOptions('some_menu_id', {label = 'New option', icon = 'plus'}, 3)\nimport lib from '@overextended/ox_lib/client';\nlib.setMenuOptions('some_menu_id', { label: 'New option', icon: 'plus' }, 3);","usage-example#Usage Example":"First we register the menu with our specified options then we call the show function in the command.\nAvoid constantly re-registering a menu that does not depend on any outside values (A.K.A a static menu).\nlib.registerMenu({\n id = 'some_menu_id',\n title = 'Menu title',\n position = 'top-right',\n onSideScroll = function(selected, scrollIndex, args)\n print(\"Scroll: \", selected, scrollIndex, args)\n end,\n onSelected = function(selected, secondary, args)\n if not secondary then\n print(\"Normal button\")\n else\n if args.isCheck then\n print(\"Check button\")\n end\n if args.isScroll then\n print(\"Scroll button\")\n end\n end\n print(selected, secondary, json.encode(args, {indent=true}))\n end,\n onCheck = function(selected, checked, args)\n print(\"Check: \", selected, checked, args)\n end,\n onClose = function(keyPressed)\n print('Menu closed')\n if keyPressed then\n print(('Pressed %s to close the menu'):format(keyPressed))\n end\n end,\n options = {\n {label = 'Simple button', description = 'It has a description!'},\n {label = 'Checkbox button', checked = true},\n {label = 'Scroll button with icon', icon = 'arrows-up-down-left-right', values={'hello', 'there'}},\n {label = 'Button with args', args = {someArg = 'nice_button'}},\n {label = 'List button', values = {'You', 'can', 'side', 'scroll', 'this'}, description = 'It also has a description!'},\n {label = 'List button with default index', values = {'You', 'can', 'side', 'scroll', 'this'}, defaultIndex = 5},\n {label = 'List button with args', values = {'You', 'can', 'side', 'scroll', 'this'}, args = {someValue = 3, otherValue = 'value'}},\n }\n}, function(selected, scrollIndex, args)\n print(selected, scrollIndex, args)\nend)\nRegisterCommand('testmenu', function()\n lib.showMenu('some_menu_id')\nend)\nimport lib from '@overextended/ox_lib/client';\nlib.registerMenu(\n {\n id: 'some_menu_id',\n title: 'Menu title',\n position: 'top-right',\n onSideScroll: (selected, scrollIndex, args) => {\n console.log('Scroll: ', selected, scrollIndex, args);\n },\n onSelected: (selected, secondary, args) => {\n if (!secondary) {\n console.log('Normal button');\n } else {\n if (args.isCheck) {\n console.log('Check button');\n }\n if (args.isScroll) {\n console.log('Scroll button');\n }\n }\n console.log(selected, secondary, JSON.stringify(args, null, 2));\n },\n onCheck: (selected, checked, args) => {\n console.log('Check: ', selected, checked, args);\n },\n onClose: (keyPressed) => {\n console.log('Menu closed');\n if (keyPressed) {\n console.log(`Pressed ${keyPressed} to close the menu`);\n }\n },\n options: [\n { label: 'Simple button', description: 'It has a description!' },\n { label: 'Checkbox button', checked: true },\n { label: 'Scroll button with icon', icon: 'arrows-up-down-left-right', values: ['hello', 'there'] },\n { label: 'Button with args', args: { someArg: 'nice_button' } },\n {\n label: 'List button',\n values: ['You', 'can', 'side', 'scroll', 'this'],\n description: 'It also has a description!',\n },\n { label: 'List button with default index', values: ['You', 'can', 'side', 'scroll', 'this'], defaultIndex: 5 },\n {\n label: 'List button with args',\n values: ['You', 'can', 'side', 'scroll', 'this'],\n args: { someValue: 3, otherValue: 'value' },\n },\n ],\n },\n (selected, scrollIndex, args) => {\n console.log(selected, scrollIndex, args);\n }\n);\nRegisterCommand(\n 'testmenu',\n () => {\n lib.showMenu('some_menu_id');\n },\n false\n);"}},"/ox_lib/Modules/Interface/Client/notify":{"title":"Notifications","data":{"libnotify#lib.notify":"Custom notifications with a lot of styling options.\nlib.notify(data)\nTriggerClientEvent('ox_lib:notify', source, data)\nimport lib from '@overextended/ox_lib/client';\nlib.notify(data);\nid?: string\nWhen set the current notification will be unique and only shown once on screen when spammed.\ntitle?: string\nMust provide if there is no description\ndescription?: string\nMust provide if there is no title\nMarkdown support\nduration?: number\nposition?: 'top' or 'top-right' or 'top-left' or 'bottom' or 'bottom-right' or 'bottom-left' or 'center-right' or 'center-left'\nDefault: 'top-right'\ntype?: 'inform' or 'error' or 'success'or 'warning'\nDefault: 'inform'\nstyle?: table (object)\nReact CSS styling format\nicon?: string\nFont Awesome 6 icon name\niconColor?: string\niconAnimation?: 'spin' 'spinPulse' 'spinReverse' 'pulse' 'beat' 'fade' 'beatFade' 'bounce' 'shake'\nalignIcon?: 'top' or 'center'\nDefault: 'center'\nSetting iconColor will get rid of the contrasted icon colour and it's circular background.","usage-example#Usage Example":"","standard#Standard":"lib.notify({\n title = 'Notification title',\n description = 'Notification description',\n type = 'success'\n})\nimport lib from '@overextended/ox_lib/client';\nlib.notify({\n title: 'Notification title',\n description: 'Notification description',\n type: 'success',\n});","custom#Custom":"lib.notify({\n id = 'some_identifier',\n title = 'Notification title',\n description = 'Notification description',\n position = 'top',\n style = {\n backgroundColor = '#141517',\n color = '#C1C2C5',\n ['.description'] = {\n color = '#909296'\n }\n },\n icon = 'ban',\n iconColor = '#C53030'\n})\nimport lib from '@overextended/ox_lib/client';\nlib.notify({\n id: 'some_identifier',\n title: 'Notification title',\n description: 'Notification description',\n position: 'top',\n style: {\n backgroundColor: '#141517',\n color: '#C1C2C5',\n '.decription': {\n color: '#909296',\n },\n },\n icon: 'ban',\n iconColor: '#C53030',\n});"}},"/ox_lib/Modules/Interface/Client/progress":{"title":"Progress","data":{"libprogressbar#lib.progressBar":"Displays a running progress bar.\nlib.progressBar(data)\nimport lib from '@overextended/ox_lib/client'\nlib.progressBar(data)\nduration: number\nlabel: string\nuseWhileDead?: boolean\nallowRagdoll?: boolean\nallowCuffed?: boolean\nallowFalling?: boolean\ncanCancel?: boolean\nanim?: table (object)\ndict?: string\nMust specify either scenario or dict\nclip: string\nflag?: number\nDefault: 49\nblendIn?: float\nDefault: 3.0\nblendOut?: float\nDefault: 1.0\nduration?: number\nDefault: -1\nplaybackRate?: number\nDefault: 0\nlockX?: boolean\nlockY?: boolean\nlockZ?: boolean\nscenario?: string\nMust specify either scenario or dict\nplayEnter?: boolean\nDefault: true\nprop?: table (object or array)\n[ If you want to define multiple props, you can pass them as individual tables (array of objects) ]\nmodel: hash\nbone?: number\nDefault: 60309\npos: table\nx: number\ny: number\nz: number\nrot: table (object)\nx: number\ny: number\nz: number\ndisable?: table (object)\nmove?: boolean\ncar?: boolean\ncombat?: boolean\nmouse?: boolean\nsprint?: boolean","usage-example#Usage Example":"if lib.progressBar({\n duration = 2000,\n label = 'Drinking water',\n useWhileDead = false,\n canCancel = true,\n disable = {\n car = true,\n },\n anim = {\n dict = 'mp_player_intdrink',\n clip = 'loop_bottle'\n },\n prop = {\n model = `prop_ld_flow_bottle`,\n pos = vec3(0.03, 0.03, 0.02),\n rot = vec3(0.0, 0.0, -1.5)\n },\n}) then print('Do stuff when complete') else print('Do stuff when cancelled') end\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nimport lib from '@overextended/ox_lib/client'\nif (await lib.progressBar({\n duration: 2000,\n label: 'Drinking water',\n useWhileDead: false,\n canCancel: true,\n disable: {\n car: true,\n },\n anim: {\n dict: 'mp_player_intdrink',\n clip: 'loop_bottle'\n },\n prop: {\n model: `prop_ld_flow_bottle`,\n pos: {x: 0.03, y: 0.03, z: 0.02},\n rot: {x: 0.0, y: 0.0, z: -1.5}\n },\n})) console.log('Do stuff when complete');\nelse console.log('Do stuff when cancelled')","libprogresscircle#lib.progressCircle":"Similar to lib.progressBar except it displays a circle and you can define a position.\nlib.progressCircle(data)\nimport lib from '@overextended/ox_lib/client'\nlib.progressCircle(data)\nduration: number\nlabel?: string\nposition?: 'middle' or 'bottom'\nDefault: 'middle'\nuseWhileDead?: boolean\nallowRagdoll?: boolean\nallowCuffed?: boolean\nallowFalling?: boolean\ncanCancel?: boolean\nanim?: table (object)\ndict?: string\nMust specify either scenario or dict\nclip: string\nflag?: number\nDefault: 49\nblendIn?: float\nDefault: 3.0\nblendOut?: float\nDefault: 1.0\nduration?: number\nDefault: -1\nplaybackRate?: number\nDefault: 0\nlockX?: boolean\nlockY?: boolean\nlockZ?: boolean\nscenario?: string\nMust specify either scenario or dict\nplayEnter?: boolean\nDefault: true\nprop?: table (object or array)\n[ If you want to define multiple props, you can pass them as individual tables (array of objects) ]\nmodel: hash\nbone?: number\nDefault: 60309\npos: table\nx: number\ny: number\nz: number\nrot: table (object)\nx: number\ny: number\nz: number\ndisable?: table (object)\nmove?: boolean\ncar?: boolean\ncombat?: boolean\nmouse?: boolean\nsprint?: boolean","usage-example-1#Usage Example":"if lib.progressCircle({\n duration = 2000,\n position = 'bottom',\n useWhileDead = false,\n canCancel = true,\n disable = {\n car = true,\n },\n anim = {\n dict = 'mp_player_intdrink',\n clip = 'loop_bottle'\n },\n prop = {\n model = `prop_ld_flow_bottle`,\n pos = vec3(0.03, 0.03, 0.02),\n rot = vec3(0.0, 0.0, -1.5)\n },\n}) then print('Do stuff when complete') else print('Do stuff when cancelled') end\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nimport lib from '@overextended/ox_lib/client'\nif (await lib.progressCircle({\n duration: 2000,\n position: 'bottom',\n useWhileDead: false,\n canCancel: true,\n disable: {\n car: true,\n },\n anim: {\n dict: 'mp_player_intdrink',\n clip: 'loop_bottle'\n },\n prop: {\n model: `prop_ld_flow_bottle`,\n pos: {x: 0.03, y: 0.03, z: 0.02},\n rot: {x: 0.0, y: 0.0, z: -1.5}\n },\n})) console.log('Do stuff when complete')\nelse console.log('Do stuff when cancelled')","libprogressactive#lib.progressActive":"Returns true if a progress bar is currently active.\nlib.progressActive()\nimport lib from '@overextended/ox_lib/client'\nlib.progressActive()","libcancelprogress#lib.cancelProgress":"If there is a progress bar active and the\nprogress bar can be cancelled then it cancels it.\nlib.cancelProgress()\nimport lib from '@overextended/ox_lib/client'\nlib.cancelProgress()"}},"/ox_lib/Modules/Interface/Client/radial":{"title":"Radial Menu","data":{"":"Radial menu has a global menu that's by default accessed with z and only displays when there is at least one item.\nYou can add and remove items from the global menu using lib.addRadialItem and lib.removeRadialItem.\nUse lib.registerRadial for creating sub menus and use the menu property on the items to open those sub menus.","libaddradialitem#lib.addRadialItem":"Item or array of items added to the global radial menu.\nlib.addRadialItem(items)\nimport lib from '@overextended/ox_lib/client';\nlib.addRadialItem(items);\nitems: table (object or array)\nid: string\nId that is used for removing options.\nicon: string\nlabel: string\nLabel uses \\n to insert a newline\nmenu?: string\nId of a menu to open.\nonSelect: function(currentMenu: string | nil, itemIndex: number) | string\nFunction that's ran when a user clicks the item.\nkeepOpen?: boolean","libremoveradialitem#lib.removeRadialItem":"Id of an item to be removed from the global menu.\nlib.removeRadialItem(item)\nimport lib from '@overextended/ox_lib/client';\nlib.removeRadialItem(item);\nid: string","libclearradialitems#lib.clearRadialItems":"Removes all items from the radial menu.\nlib.clearRadialItems()\nimport lib from '@overextended/ox_lib/client';\nlib.clearRadialItems();","libregisterradial#lib.registerRadial":"Registers a radial sub menu with predefined options.\nlib.registerRadial(radial)\nimport lib from '@overextended/ox_lib/client';\nlib.registerRadial(radial);\nradial: table (object)\nid: string\nUnique menu id used to open with menu prop on an item.\nitems: array\nicon: string\nlabel: string\nLabel uses \\n to insert a newline\nmenu?: string\nId of a menu to open.\nonSelect?: function(currentMenu: string | nil, itemIndex: number) | string\nFunction that's ran when a user clicks the item.","libhideradial#lib.hideRadial":"Hides the radial menu if one is open.\nlib.hideRadial()\nimport lib from '@overextended/ox_lib/client';\nlib.hideRadial();","libdisableradial#lib.disableRadial":"Disallow players from opening the radial menu.\nlib.disableRadial(state)\nimport lib from '@overextended/ox_lib/client';\nlib.disableRadial(state);\nstate: boolean\nWhether or not radial menu should be disabled","libgetcurrentradialid#lib.getCurrentRadialId":"Returns the id of the currently open radial menu.\nlocal id = lib.getCurrentRadialId()\nimport lib from '@overextended/ox_lib/client';\nlet id = lib.getCurrentRadialId();","usage-example#Usage Example":"When adding radial menu items whether they are global or for a sub menu, make sure to stick to short as possible labels\nas long labels will look out of place and should not be used with the radial menu because of its density.\nHere's a use case example with some global options and an option utilising the lib's points system.\nexports('myMenuHandler', function(menu, item)\n print(menu, item)\n if menu == 'police_menu' and item == 1 then\n print('Handcuffs')\n end\nend)\nlib.registerRadial({\n id = 'police_menu',\n items = {\n {\n label = 'Handcuff',\n icon = 'handcuffs',\n onSelect = 'myMenuHandler'\n },\n {\n label = 'Frisk',\n icon = 'hand'\n },\n {\n label = 'Fingerprint',\n icon = 'fingerprint'\n },\n {\n label = 'Jail',\n icon = 'bus'\n },\n {\n label = 'Search',\n icon = 'magnifying-glass',\n onSelect = function()\n print('Search')\n end\n }\n }\n})\nlib.addRadialItem({\n {\n id = 'police',\n label = 'Police',\n icon = 'shield-halved',\n menu = 'police_menu'\n },\n {\n id = 'business_stuff',\n label = 'Business',\n icon = 'briefcase',\n onSelect = function()\n print(\"Business\")\n end\n }\n})\nlocal coords = GetEntityCoords(cache.ped)\nlocal point = lib.points.new(coords, 5)\nfunction point:onEnter()\n lib.addRadialItem({\n id = 'garage_access',\n icon = 'warehouse',\n label = 'Garage',\n onSelect = function()\n print('Garage')\n end\n })\nend\nfunction point:onExit()\n lib.removeRadialItem('garage_access')\nend\nPoints system in the lib isn't available for the npm package.\nimport lib from '@overextended/ox_lib/client'\nexports('myMenuHandler', (menu, item) => {\n console.log(menu, item)\n if (menu === 'police_menu' and item === 1) {\n console.log('Handcuffs')\n }\n})\nlib.registerRadial({\n id: 'police_menu',\n items: [\n {\n label: 'Handcuff',\n icon: 'handcuffs',\n onSelect: 'myMenuHandler'\n },\n {\n label: 'Frisk',\n icon: 'hand'\n },\n {\n label: 'Fingerprint',\n icon: 'fingerprint'\n },\n {\n label: 'Jail',\n icon: 'bus'\n },\n {\n label: 'Search',\n icon: 'magnifying-glass',\n onSelect: () => {\n console.log('Search')\n }\n }\n ]\n})\nlib.addRadialItem([\n {\n id: 'police',\n label: 'Police',\n icon: 'shield-halved',\n menu: 'police_menu'\n },\n {\n id: 'business_stuff',\n label: 'Business',\n icon: 'briefcase',\n onSelect: () => {\n console.log('Business')\n }\n }\n])"}},"/ox_lib/Modules/Interface/Client/skillcheck":{"title":"Skill Check","data":{"libskillcheck#lib.skillCheck":"Runs a skill check with the defined difficulty.\nlib.skillCheck(difficulty, inputs)\nimport lib from '@overextended/ox_lib/client';\nlib.skillCheck(difficulty, inputs);\ndifficulty: 'easy' or 'medium' or 'hard' or table\nPreset difficulties:\n'easy' - { areaSize: 50, speedMultiplier: 1 }\n'medium' - { areaSize: 40, speedMultiplier: 1.5 }\n'hard' - { areaSize: 25, speedMultiplier: 1.75 }\nCustom difficulties can be set by sending an object instead of one of the preset strings above\nareaSize: number\nSize of the success area in degrees\nspeedMultiplier: number\nMultiplier for the speed of the indicator\ninputs?: string[]\nA random key will be picked from the inputs table for each skill check\nIf no inputs are defined the key is defaulted to e","libskillcheckactive#lib.skillCheckActive":"Returns true if a skill check is currently active.\nlib.skillCheckActive()\nimport lib from '@overextended/ox_lib/client'\nlib.skillCheckActive()","libcancelskillcheck#lib.cancelSkillCheck":"Cancels the currently ongoing skill check.\nlib.cancelSkillCheck()\nimport lib from '@overextended/ox_lib/client'\nlib.cancelSkillCheck()","usage-example#Usage Example":"local success = lib.skillCheck({'easy', 'easy', {areaSize = 60, speedMultiplier = 2}, 'hard'}, {'w', 'a', 's', 'd'})\nimport lib from '@overextended/ox_lib/client';\nconst success = await lib.skillCheck(\n ['easy', 'easy', { areaSize: 60, speedMultiplier: 2 }, 'hard'],\n ['w', 'a', 's', 'd']\n);"}},"/ox_lib/Modules/Interface/Client/textui":{"title":"TextUI","data":{"libshowtextui#lib.showTextUI":"Show the TextUI window.\nDO NOT run this function every tick, it's intended to be used as a toggle.\nlib.showTextUI(text, options)\nimport lib from '@overextended/ox_lib/client';\nlib.showTextUI(text, options);\ntext: string\noptions?: table\nposition?: 'right-center' or 'left-center' or 'top-center'\nDefault: 'right-center'\nicon?: string or table (array)\niconColor?: string\niconAnimation?: 'spin' 'spinPulse' 'spinReverse' 'pulse' 'beat' 'fade' 'beatFade' 'bounce' 'shake'\nstyle?: React.CSSProperties\nalignIcon?: 'top' or 'center'\nDefault: 'center'","libhidetextui#lib.hideTextUI":"Hides the currently visible TextUI window\nlib.hideTextUI()\nimport lib from '@overextended/ox_lib/client';\nlib.hideTextUI();","libistextuiopen#lib.isTextUIOpen":"Returns whether Text UI is opened or not. The currently displayed text is returned as the second value.\nlocal isOpen, text = lib.isTextUIOpen()\nimport lib from '@overextended/ox_lib/client';\nconst [isOpen, text] = lib.isTextUIOpen();","usage-example#Usage Example":"","basic#Basic":"lib.showTextUI('[E] - Fuel vehicle')\nimport lib from '@overextended/ox_lib/client';\nlib.showTextUI('[E] - Fuel vehicle');","custom-styling#Custom styling":"lib.showTextUI('[E] - Pick apple', {\n position = \"top-center\",\n icon = 'hand',\n style = {\n borderRadius = 0,\n backgroundColor = '#48BB78',\n color = 'white'\n }\n})\nimport lib from '@overextended/ox_lib/client';\nlib.showTextUI('[E] - Pick apple', {\n position: 'top-center',\n icon: 'hand',\n style: {\n borderRadius: 0,\n backgroundColor: '#48BB78',\n color: 'white',\n },\n});"}},"/ox_lib/Modules/Locale/Shared":{"title":"Shared","data":{"":"Allows servers to set a preferred language and attempt to load locale files in any resources using the module.\nLocale files should use the ISO Language Code and be saved as ./locales/langcode.json","setup#Setup":"To change the preferred language from English, add the convar to your server.cfg and change en to the desired language code.\nsetr ox:locale en\nCreate a locales directory and a file for your language.\n{\n \"grand_theft_auto\": \"grand theft auto\",\n \"male\": \"male\",\n \"female\": \"female\",\n \"suspect_sex\": \"suspect is %s\"\n}\n{\n \"grand_theft_auto\": \"vol de voiture\",\n \"male\": \"homme\",\n \"female\": \"femme\",\n \"suspect_sex\": \"le suspect est %s\"\n}\nfiles {\n 'locales/*.json'\n}","usage#Usage":"Initialise the locale module in your resource (once).\nlib.locale()\nimport {initLocale} from '@overextended/ox_lib/shared'\ninitLocale()\nFormat your strings with the new locale global.\nAdditional arguments can be sent to format the locale output.\nlocale(str, ...)\nimport { locale } from '@overextended/ox_lib/shared'\nlocale(str, ...)\nstr: string\nvararg?: string or number\nExample\n-- Load the locale module\nlib.locale()\nSetInterval(function()\n print(locale('grand_theft_auto'))\n print(locale('suspect_sex', locale('male')))\nend, 5000)\nimport { initLocale, locale } from '@overextended/ox_lib/shared\n// Load the locale module\ninitLocale()\nsetInterval(() => {\n console.log(locale('grand_theft_auto'))\n console.log(locale('suspect_sex', locale('male')))\n}, 5000)","phrases#Phrases":"You can create a locale string that references other locales to construct a phrase, rather than calling locale multiple times.\n{\n \"hello\": \"hello %s\",\n \"my_name_is\": \"my name is %s\",\n \"hello_my_name_is\": \"${hello}! ${my_name_is}.\"\n}\nprint(locale('hello_my_name_is', 'doka', 'linden'))\nimport { locale } from '@overextended/ox_lib/shared'\nconsole.log(locale('hello_my_name_is', 'doka', 'linden'))","libgetlocale#lib.getLocale":"Gets a locale string from another resource and adds it to the dict.\nlib.getLocale(resource, key)\nresource: string\nkey: string"}},"/ox_lib/Modules/Logger/Server":{"title":"Server","data":{"liblogger#lib.logger":"lib.logger(source, event, message, ...)\nsource: number or string\nPreferably an active player id, otherwise an identifier, or wherever else it originated from.\nevent: string\nA name for the log event (i.e. the trigerring event or a description)\nmessage: string\nThe content for the log.\nvararg: string\nAdditional arguments are converted to tags for additional filtering and searching.\nExample\nlocal vehicle = Ox.CreateVehicle(false, `sultanrs`, vector4(-56.479122, -1116.870362, 26.432250, 0.000030517578))\nlib.logger(-1, 'CreateVehicle', json.encode(vehicle))","datadog#Datadog":"","create-your-datadog-account#Create your Datadog account":"You will receive a free 14 day trial, otherwise refer to their pricing guide.\nFree accounts are limited, however logs will still be retained for 14 days.","create-an-api-key#Create an API key":"This is a UUID used to submit logs to your Datadog organisation.","config#Config":"Set your API key and Datadog site using the following convars.\nset datadog:key \"yourapikey\"\nset datadog:site \"datadoghq.com\"","grafana-loki#Grafana Loki":"Loki is a horizontally scalable, highly available, multi-tenant log aggregation system inspired by Prometheus.\nIt is designed to be very cost effective and easy to operate.\nHas free tier with some restrictions\nEasy to manage\nEasier to setup\nMostly managed by Grafana","create-your-grafana-account#Create your Grafana account":"","head-to-my-account#Head to My Account":"","setup-loki#Setup Loki":"Find the Loki section in your account panel, and click \"Details\".\nGenerate a password and save the API key, as well as your user and url.\nTo setup a grafana instance you'll need docker, and knowledge on containers or kubernetes.\nPlease find a guide to setup a grafana stack (min requirement grafana and grafana loki) and follow that.Once done, setup authentication and use the username and password securing your endpoint.\nBy default self-hosted loki instances do not provide any authentication layers and will require an external authentication layer such as NGINX basic auth or Cloudflare Access.","config-1#Config":"Use the following convars to set your logging service, endpoint, and authentication details.\nset ox:logger \"loki\"\nset loki:user \"\"\nset loki:password \"\"\nset loki:endpoint \"\""}},"/ox_lib/Modules/Math/Shared":{"title":"Shared","data":{"libmath#lib.math":"Extends the standard Lua math table with extra functions.\nmath = lib.math","mathtoscalars#math.toscalars":"Takes a string and returns a set of scalar values.\nmath.toscalars(input, min, max, round)\ninput: string\nmin?: number\nmax?: number\nround?: boolean\nReturn:\n...: number","mathtovector#math.tovector":"Takes a string or table and returns a vector value, or a number if only one value was found.\nmath.tovector(input, min, max, round)\ninput: string or table\nmin?: number\nmax?: number\nround?: boolean\nReturn:\nvalue: number or vector2 or vector3 or vector4","mathnormaltorotation#math.normaltorotation":"Takes a surface normal and tries to convert it to a vector3 rotation.\nmath.normaltorotation(input)\ninput: vector3\nReturn:\nvalue: vector3","mathtorgba#math.torgba":"Takes a string or table and returns a vector value, or a number if only one value was found.\nValues are rounded and must be within the range of 0-255.\nmath.torgba(input)\ninput: string or table\nReturn:\nvalue: number or vector2 or vector3 or vector4","mathhextorgb#math.hextorgb":"Takes a hexadecimal string and returns three integers.\nmath.hextorgb(input)\ninput: string\nA hexadecimal value, e.g. 'eb4034'.\nReturn:\nr: number\ng: number\nb: number","mathtohex#math.tohex":"Takes a number or string and formats it as a hexadecimal string.\nmath.tohex(n, upper)\nn: number or string\nupper?: boolean\nReturn:\nhex: string","mathgroupdigits#math.groupdigits":"Takes a number and formats it into grouped digits.\nmath.groupdigits(number, seperator)\nnumber: number\nseperator?: string\nDefault: ,\nReturn:\ngroupedDigits: string","mathclamp#math.clamp":"Clamps a number between a lower and upper limit.\nmath.clamp(number, lower, upper)\nnumber: number\nlower: number\nupper: number\nReturn:\nnumber: number"}},"/ox_lib/Modules/Points/JavaScript/Client":{"title":"Client","data":{"points#Points":"Simple and centralised distance checking, supporting callbacks when entering, leaving, and standing in-range of set coordinates.\nPoint({coords, distance, onEnter, onExit, nearby, args})\ncoords: number[]\ndistance: number\nonEnter?: function\nonExit?: function\nnearby?: function\nargs?: T\nimport { Point, cache } from '@overextended/ox_lib/client'\nfunction nearby(this: Point<{dunak: string}>) {\n // @ts-ignore\n DrawMarker(2, this.coords.x, this.coords.y, this.coords.z, 0, 0, 0, 0, 180, 0, 1, 1, 1, 200, 20, 20, 50, false, true, 2, false, null, null, false)\n if (this.currentDistance && this.currentDistance < 1 && IsControlJustReleased(0, 38)) {\n console.log('Inside marker', this.id)\n console.log(this.args?.dunak)\n }\n}\nconst point = new Point({\n coords: GetEntityCoords(cache.ped, false),\n distance: 5,\n nearby: nearby,\n args: {\n dunak: 'nerd'\n }\n})\npoint.onEnter = () => {\n console.log('Entered range of point', point.id)\n}\npoint.onExit = () => {\n console.log('Left range of point', point.id)\n}"}},"/ox_lib/Modules/Print/Shared":{"title":"Shared","data":{"":"Prints to console conditionally based on convars set.\nDifferent level prints are colored and labeled.\nResource name is always included.","libprint#lib.print":"lib.print.error(...)\nlib.print.warn(...)\nlib.print.info(...)\nlib.print.verbose(...)\nlib.print.debug(...)\nvararg: any\nWhat to print in console. Converts tables into a pretty-print format.","example#Example":"lib.print.warn(\"query latency high: \", latency)","levels#Levels":"Error\nIndicates a failure in the system.\nWarn\nWarns of an unexpected condition, or a state which is likely to cause an error in the future.\nInfo\nInformation about high-level, successful operations.\nVerbose\nMore detailed information containing intermediate steps of high-level, operations\nDebug\nUsed by developers to understand the system and may contain detailed trace information.\nShould generally not be turned on when not debugging.","config#Config":"Use the following convars to set your print level. Prints less severe than the current level will not be executed.\nFor example, a level of info will print error, warn, and info, but not verbose nor debug. Defaults to info if not set.\nResource specific print levels override the global convar.\nset ox:printlevel \"info\"\nset ox:printlevel:ox_inventory \"warn\"\nset ox:printlevel: \"\""}},"/ox_lib/Modules/Points/Lua/Client":{"title":"Client","data":{"":"Simple and centralised distance checking, supporting callbacks when entering, leaving, and standing in-range of set coordinates.","cpoint-class#CPoint Class":"A table representing a point with the following properties.\nid: number\ncoords: vector3\ndistance: number\nThe distance for the player to be \"inside\" a point (i.e. the point's radius).\ncurrentDistance: number\nThe players current distance from the centre of the point.\nisClosest?: boolean\nremove: function()\nRemoves the point from the points registry.\nonEnter?: function(self: CPoint)\nFunction triggered when player gets within distance of the point\nonExit?: function(self: CPoint)\nFunction triggered when player goes beyond distance of the point\nnearby?: function(self: CPoint)\nFunction triggered on frame when within distance of the point","libpointsnew#lib.points.new":"lib.points.new(data)\ndata: table\ncoords: vector3\ndistance: number\nReturns:\npoint: CPoint","usage-example#Usage Example":"local point = lib.points.new({\n coords = GetEntityCoords(cache.ped),\n distance = 5,\n dunak = 'nerd',\n})\nfunction point:onEnter()\n print('entered range of point', self.id)\nend\nfunction point:onExit()\n print('left range of point', self.id)\nend\nfunction point:nearby()\n DrawMarker(2, self.coords.x, self.coords.y, self.coords.z, 0.0, 0.0, 0.0, 0.0, 180.0, 0.0, 1.0, 1.0, 1.0, 200, 20, 20, 50, false, true, 2, false, nil, nil, false)\n if self.currentDistance < 1 and IsControlJustReleased(0, 38) then\n print('inside marker', self.id, 'dunak is a '.. self.dunak)\n end\nend","libpointsgetallpoints#lib.points.getAllPoints":"Get a table of all points created in the resource.\nlib.points.getAllPoints()\nReturn:\npoints: CPoint[]","libpointsgetnearbypoints#lib.points.getNearbyPoints":"Get an array of all points in range of the player.\nlib.points.getNearbyPoints()\nReturn:\nnearbyPoints: CPoint[]","libpointsgetclosestpoint#lib.points.getClosestPoint":"Get the data for the closest point to the player.\nlib.points.getClosestPoint()\nReturn:\nclosestPoint?: CPoint"}},"/ox_lib/Modules/Raycast/Client":{"title":"Client","data":{"libraycastcam#lib.raycast.cam":"Starts a shapetest originating from the camera, extending to ~10m by default.\nlib.raycast.cam(flags, ignore, distance)\nflags?: number\nSee: https://docs.fivem.net/natives/?_0x377906D8A31E5586\nDefault: 511\nignore?: number\nA bit mask with bits 1, 2, 4, or 7 relating to collider types. 4 and 7 are usually used.\nDefault: 4\ndistance?: number\nDefault: 10\nReturn:\nhit: boolean\nWhether or not an entity was hit\nentityHit: number\nEntity handle of hit entity\nendCoords: vector3\nClosest coords to where the raycast hit\nsurfaceNormal: vector3\nNormal to the surface that was hit\nmaterialHash: number"}},"/ox_lib/Modules/Require/Shared":{"title":"Shared","data":{"":"This module is always loaded by default.","require#require":"Loads the given module. The function starts by indexing the loaded table to determine whether modname is already loaded. If it is, then require returns the value stored at loaded[modname].\nModule names are the path to a file relative to the resource.\nThe module name must point to a .lua file.\nUse . to separate directories in a path.\nModules can be loaded from external resources using @resource.modname.\nrequire 'modname'","usage-example#Usage Example":"- resources/\n - mylib/\n - import.lua\n - data/\n - events.lua\n - myresource/\n - server.lua\nlocal mylib = {\n events = require 'data.events'\n}\nprint('Loaded mylib')\nreturn mylib\nreturn {\n disconnect = 'onPlayerDropped',\n}\nlocal mylib = require '@mylib.import'\nprint(mylib.events.disconnect)","libload#lib.load":"Loads and runs a Lua file at the given path. Unlike require, the chunk is not cached for future use.\nlib.load(filePath, env)\nfilePath: string\nA path to the Lua file, using the same rules as require.\nenv?: table\nA table to use as the global environment, defaulting to _ENV.","usage-example-1#Usage Example":"local events = lib.load('data.events')\nprint('Loaded events')\nreturn {\n disconnect = 'onPlayerDropped',\n}","libloadjson#lib.loadJson":"Loads a JSON file at the given path and decodes it as a table.\nlib.loadJson(filePath)\nfilePath: string\nA path to the Lua file, using the same rules as require.","usage-example-2#Usage Example":"local events = lib.load('data.events')\nprint('Loaded events')\n{\n \"disconnect\": \"onPlayerDropped\"\n}"}},"/ox_lib/Modules/String/Shared":{"title":"Shared","data":{"libstring#lib.string":"Extends the standard Lua string table with extra functions.\nstring = lib.string","stringrandom#string.random":"Outputs a random string based on a given pattern.\nstring.random(pattern, length)\npattern: string\n1 will output a random number from 0-9.\nA will output a random letter from A-Z.\na will output a random letter from a-z.\n. will output a random letter or number.\n^ will output the following character literally.\nAny other character will output said character.\nlength?: number\nSets the length of the returned string, either padding it or omitting characters.\nReturn:\nstring: string"}},"/ox_lib/Modules/Streaming/Client":{"title":"Client","data":{"":"Check if assets exist, such as models, and loads them into memory.\nThrows errors for invalid assets and returns true if the asset is loaded.","librequestanimdict#lib.requestAnimDict":"lib.requestAnimDict(dict, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestAnimDict(dict, timeout)\ndict: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestanimset#lib.requestAnimSet":"lib.requestAnimSet(set, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestAnimSet(set, timeout)\nset: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestmodel#lib.requestModel":"lib.requestModel(model, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestModel(model, timeout)\nmodel: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequeststreamedtexturedict#lib.requestStreamedTextureDict":"lib.requestStreamedTextureDict(dict, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestStreamedTextureDict(dict, timeout)\ndict: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestnamedptfxasset#lib.requestNamedPtfxAsset":"lib.requestNamedPtfxAsset(ptFxName, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestNamedPtfxAsset(ptFxName, timeout)\nptFxName: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestscaleformmovie#lib.requestScaleformMovie":"lib.requestScaleformMovie(scaleformName, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestScaleformMovie(scaleformName, timeout)\nscaleformName: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestweaponasset#lib.requestWeaponAsset":"lib.requestWeaponAsset(weaponType, timeout, weaponResourceFlags, extraWeaponComponentFlags)\nimport lib from '@overextended/ox_lib/client'\nlib.requestWeaponAsset(weaponType, timeout, weaponResourceFlags, extraWeaponComponentFlags)\nweaponType: string | number\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500\nweaponResourceFlags?: WeaponResourceFlags\nDefault: 31\nextraWeaponComponentFlags?: ExtraWeaponComponentFlags\nDefault: 0","weaponresourceflags#WeaponResourceFlags":"1 WRF_REQUEST_BASE_ANIMS\n2 WRF_REQUEST_COVER_ANIMS\n4 WRF_REQUEST_MELEE_ANIMS\n8 WRF_REQUEST_MOTION_ANIMS\n16 WRF_REQUEST_STEALTH_ANIMS\n32 WRF_REQUEST_ALL_MOVEMENT_VARIATION_ANIMS\n31 WRF_REQUEST_ALL_ANIMS","extraweaponcomponentflags#ExtraWeaponComponentFlags":"0 WEAPON_COMPONENT_NONE\n1 WEAPON_COMPONENT_FLASH\n2 WEAPON_COMPONENT_SCOPE\n4 WEAPON_COMPONENT_SUPP\n8 WEAPON_COMPONENT_SCLIP2\n16 WEAPON_COMPONENT_GRIP"}},"/ox_lib/Modules/Table/Shared":{"title":"Shared","data":{"":"Adds additional functions alongside the standard table library.","libtablecontains#lib.table.contains":"Checks if table contains the given value. Only intended for simple values and unnested tables.\nlib.table.contains(tbl, value)\ntbl: table\nvalue: any\nReturn:\nisContained: boolean","libtablematches#lib.table.matches":"Compares if two values are equal, iterating over tables and matching both keys and values.\nlib.table.matches(tableOne, tableTwo)\ntableOne: table\ntableTwo: table\nReturn:\nmatches: boolean","libtabledeepclone#lib.table.deepclone":"Recursively clones a table to ensure no table references remain.\nlib.table.deepclone(tbl)\ntbl: table\nReturn:\nclonedTable: table","libtablemerge#lib.table.merge":"Merges two tables together. Duplicate keys will be added together if they are numbers, otherwise tableTwo's value will be used.\nlib.table.merge(tableOne, tableTwo)\ntableOne: table\ntableTwo: table\nReturn:\ntableOne: table","libtablefreeze#lib.table.freeze":"Makes a table read-only, preventing further modification. Unfrozen tables stored within table are still mutable.\nlib.table.freeze(tbl)\ntbl: table\nReturn:\nfrozenTable: table","libtableisfrozen#lib.table.isFrozen":"Returns true if tbl is set as read-only.\nlib.table.isFrozen(tbl)\ntbl: table\nReturn:\nisFrozen: boolean"}},"/ox_lib/Modules/Version/Server":{"title":"Server","data":{"libversioncheck#lib.versionCheck":"Compares the resource version to the latest published release on GitHub.\nUtilises GitHub's release API\nlib.versionCheck(repository)\nrepository: string\nlib.versionCheck('overextended/ox_lib')\nimport lib from '@overextended/ox_lib/server'\nlib.versionCheck('overextended/ox_lib')"}},"/ox_lib/Modules/VehicleProperties/Client":{"title":"Client","data":{"":"Mostly follows the format used by ESX and QBCore, with extra data such as damaged/missing props.\nhttps://github.com/overextended/ox_lib/blob/master/resource/vehicleProperties/client.lua#L3","libgetvehicleproperties#lib.getVehicleProperties":"lib.getVehicleProperties(vehicle)\nvehicle: number\nvehicle handle of the vehicle to get the properties for\nlib.getVehicleProperties(GetVehiclePedIsUsing(PlayerPedId()))\nimport lib from '@overextended/ox_lib/client'\nlib.getVehicleProperties(GetVehiclePedIsUsing(PlayerPedId()))","libsetvehicleproperties#lib.setVehicleProperties":"Requires the vehicle to belong to the client. Do not use NetworkRequestControlOfEntity.\nlib.setVehicleProperties(vehicle, props)\nvehicle: entity\nprops: table (object)\nRegisterNetEvent('ox_lib:setVehicleProperties', function(netid, data)\n lib.setVehicleProperties(NetToVeh(netid), data)\nend)\nimport lib from '@overextended/ox_lib/client'\nonNet('ox_lib:setVehicleProperties', (netid, data) => {\n lib.setVehicleProperties(NetToVeh(netid), data)\n})","recommended-usage#Recommended Usage":"The server should tell the owner of the entity to set properties, using the following trigger.\nTriggerClientEvent('ox_lib:setVehicleProperties', entityOwner, vehNetId, data)","vehicle-properties#Vehicle Properties":"model?: number\nplate?: string\nplateIndex?: number\nbodyHealth?: number\nengineHealth?: number\ntankHealth?: number\nfuelLevel?: number\noilLevel?: number\ndirtLevel?: number\ncolor1?: number or number[]\ncolor2?: number or number[]\npearlescentColor?: number\ninteriorColor?: number\ndashboardColor?: number\nwheelColor?: number\nwheelWidth?: number\nwheelSize?: number\nwheels?: number\nwindowTint?: number\nxenonColor?: number\nneonEnabled?: boolean[]\nneonColor?: number or number[]\nextras?: table\ntyreSmokeColor?: number or number[]\nmodSpoilers?: number\nmodFrontBumper?: number\nmodRearBumper?: number\nmodSideSkirt?: number\nmodExhaust?: number\nmodFrame?: number\nmodGrille?: number\nmodHood?: number\nmodFender?: number\nmodRightFender?: number\nmodRoof?: number\nmodEngine?: number\nmodBrakes?: number\nmodTransmission?: number\nmodHorns?: number\nmodSuspension?: number\nmodArmor?: number\nmodNitrous?: number\nmodTurbo?: number\nmodSubwoofer?: boolean\nmodSmokeEnabled?: boolean\nmodHydraulics?: boolean\nmodXenon?: boolean\nmodFrontWheels?: number\nmodBackWheels?: number\nmodCustomTiresF?: boolean\nmodCustomTiresR?: boolean\nmodPlateHolder?: number\nmodVanityPlate?: number\nmodTrimA?: number\nmodOrnaments?: number\nmodDashboard?: number\nmodDial?: number\nmodDoorSpeaker?: number\nmodSeats?: number\nmodSteeringWheel?: number\nmodShifterLeavers?: number\nmodAPlate?: number\nmodSpeakers?: number\nmodTrunk?: number\nmodHydrolic?: number\nmodEngineBlock?: number\nmodAirFilter?: number\nmodStruts?: number\nmodArchCover?: number\nmodAerials?: number\nmodTrimB?: number\nmodTank?: number\nmodWindows?: number\nmodDoorR?: number\nmodLivery?: number\nmodRoofLivery?: number\nmodLightbar?: number\nwindows?: number[]\ndoors?: number[]\ntyres?: table\nbulletProofTyres?: boolean"}},"/ox_lib/Modules/Version/Shared":{"title":"Shared","data":{"libcheckdependency#lib.checkDependency":"Check if a resource is using a specified version or higher, allowing for compatibility checks or throwing errors.\nlib.checkDependency(resource, version)\nresource: string\nversion: string\nif not lib.checkDependency('ox_lib', '1.5.0') then error() end\nimport lib from '@overextended/ox_lib/shared'\n// import { checkDependency } from '@overextended/ox_lib/shared'\nif (!lib.checkDependency('ox_lib', '1.5.0')) error()"}},"/ox_lib/Modules/WaitFor/Shared":{"title":"Shared","data":{"libwaitfor#lib.waitFor":"Calls a function repeatedly until it receives a non-nil value, or it times out.\nThe function result is then returned.\nlib.waitFor(cb, errMessage, timeout)\ncb: function\nA function to call each frame.\nerrMessage?: string\nThe error message to display if the function times out.\ntimeout?: number\nThe duration to run the function for, defaulting to 1000ms.\nlocal value --[['abc']] = lib.waitFor(function()\n if math.random(0, 1) == 1 then return 'abc' end\nend)"}},"/ox_target":{"title":"Ox Target","data":{"":"A performant and flexible standalone targeting resource or \"third-eye\", with additional functionality for ox_inventory, ox_core, qb-core, and es_extended.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","install-all-resource-dependencies#Install all resource dependencies":"ox_lib","download-a-release-or-clone-the-source-code#Download a release or clone the source code.":"git clone https://github.com/overextended/ox_target.git","config#Config":"Resource configuration is handled using convars.\n# Toggle targeting when pressing the hotkey, instead of holding it down.\nsetr ox_target:toggleHotkey 0\n# Change the key to enable targeting (https://docs.fivem.net/docs/game-references/input-mapper-parameter-ids/keyboard)\nsetr ox_target:defaultHotkey LMENU\n# Draw a sprite (circle) at the centroid of a zone.\nsetr ox_target:drawSprite 1\n# Enable built-in targeting options, e.g. toggling vehicle doors.\nsetr ox_target:defaults 1\n# Enable debugging / testing options, entity outlines, and a raycast indicator.\nsetr ox_target:debug 0\n# Enable / Disable leftclick to select options\nsetr ox_target:leftClick 1","supported-frameworks#Supported Frameworks":"These aren't necessary to run ox_target, but they will add additional features.\nox_core\nesx\nqb-core"}},"/ox_target/Functions/Client":{"title":"Client","data":{"":"All exports with the options argument expect a table with the targeting properties here.For some examples you can refer to defaults.lua or debug.lua.","disabletargeting#disableTargeting":"Toggle the availability of the targeting menu.\nexports.ox_target:disableTargeting(state)\nstate: boolean\nSetting state to true will turn off the targeting eye if it is active and prevent it from reopening until state is set to false again.","addglobalobject#addGlobalObject":"Creates new targetable options for all Object entity types.\nexports.ox_target:addGlobalObject(options)\noptions: table","removeglobalobject#removeGlobalObject":"Removes all options from the global Object list with the option names.\nexports.ox_target:removeGlobalObject(optionNames)\noptionNames: string or string[]","addglobalped#addGlobalPed":"Creates new targetable options for all Ped entity types (excluding players).\nexports.ox_target:addGlobalPed(options)\noptions: table","removeglobalped#removeGlobalPed":"Removes all options from the global Ped list with the option names.\nexports.ox_target:removeGlobalPed(optionNames)\noptionNames: string or string[]","addglobalplayer#addGlobalPlayer":"Creates new targetable options for all Player entities.\nexports.ox_target:addGlobalPlayer(options)\noptions: table","removeglobalplayer#removeGlobalPlayer":"Removes all options from the global Player list with the option names.\nexports.ox_target:removeGlobalPlayer(optionNames)\noptionNames: string or string[]","addglobalvehicle#addGlobalVehicle":"Creates new targetable options for all Vehicle entity types.\nexports.ox_target:addGlobalVehicle(options)\noptions: table","removeglobalvehicle#removeGlobalVehicle":"Removes all options from the global Vehicle list with the option names.\nexports.ox_target:removeGlobalVehicle(optionNames)\noptionNames: string or string[]","addmodel#addModel":"Creates new targetable options for a specific model or list of models.\nexports.ox_target:addModel(models, options)\nmodels: number or string or Array\noptions: table","removemodel#removeModel":"Removes all options from the models list with the option names.\nexports.ox_target:removeModel(models, optionNames)\nmodels: number or string or Array\noptionNames: string or string[]","addentity#addEntity":"Creates new targetable options for a specific network id or list of network ids (see NetworkGetNetworkIdFromEntity).\nexports.ox_target:addEntity(netIds, options)\nnetIds: number or number[]\noptions: table","removeentity#removeEntity":"Removes all options from the networked entities list with the option names.\nexports.ox_target:removeEntity(netIds, optionNames)\nnetIds: number or number[]\noptionNames: string or string[]","addlocalentity#addLocalEntity":"Creates new targetable options for a specific entity handle or list of entity handles.\nexports.ox_target:addLocalEntity(entities, options)\nentities: number or number[]\noptions: table","removelocalentity#removeLocalEntity":"Removes all options from the entities list with the option names.\nexports.ox_target:removeLocalEntity(entities, optionNames)\nentities: number or number[]\noptionNames: string or string[]","addspherezone#addSphereZone":"Creates a new targetable sphere zone.\nexports.ox_target:addSphereZone(parameters)\nparameters: table\ncoords: vector\nradius?: number\ndebug?: boolean\ndrawSprite?: boolean\noptions: table\nReturn:\nid: number","addboxzone#addBoxZone":"Creates a new targetable box zone.\nexports.ox_target:addBoxZone(parameters)\nparameters: table\ncoords: vector\nsize?: vector3\nrotation?: number\ndebug?: boolean\ndrawSprite?: boolean\noptions: table\nReturn:\nid: number","addpolyzone#addPolyZone":"Creates a new targetable poly zone.\nexports.ox_target:addPolyZone(parameters)\nparameters: table\npoints: vector3[]\nAll z values must match\nthickness?: number\ndebug?: boolean\ndrawSprite?: boolean\noptions: table\nReturn:\nid: number","removezone#removeZone":"Removes a targetable zone with the given id (returned by addBoxZone/addSphereZone).\nexports.ox_target:removeZone(id)\nid: number or string\nThe number id that is returned by addSphereZone, addBoxZone, or addPolyZone\nOR\nThe string name that can be specified by the user"}},"/ox_lib/Modules/Zones/Shared":{"title":"Shared","data":{"":"Faster alternative to PolyZone utilising glm.polygon.\nCurrently zones only have basic support on the server side. Some features will not work such as onEnter, onExit,\nand inside.","libzonespoly#lib.zones.poly":"lib.zones.poly(data)\ndata: table\npoints: vector3[]\nAll z values must match\nthickness?: number\nDefault: 4\nonEnter?: function(self: table)\nonExit?: function(self: table)\ninside?: function(self: table)\ndebug?: boolean","libzonesbox#lib.zones.box":"lib.zones.box(data)\ndata: table\ncoords: vector3\nsize?: vector3\nDefault: vec3(2, 2, 2)\nrotation?: number\nAngle in degrees\nDefault: 0\nonEnter?: function(self: table)\nonExit?: function(self: table)\ninside?: function(self: table)\ndebug?: boolean","libzonessphere#lib.zones.sphere":"lib.zones.sphere(data)\ndata: table\ncoords: vector3\nradius?: number\nDefault: 2\nonEnter?: function(self: table)\nonExit?: function(self: table)\ninside?: function(self: table)\ndebug?: boolean","methods#Methods":"","remove#remove":"Zones can be deleted by using the remove method. The data will not be cleared from the script, and can be used to recreate a zone later.\nlocal zone = lib.zones.box({...})\nzone:remove()\nSetTimeout(500, function()\n lib.zones.poly(zone)\nend)","contains#contains":"Tests if a point exists inside the zone, returning a boolean.\nlocal zone = lib.zones.box({...})\nif zone:contains(vec3(1, 1, 1)) then\n print('point is inside zone!')\nend","usage-examples#Usage Examples":"function onEnter(self)\n print('entered zone', self.id)\nend\nfunction onExit(self)\n print('exited zone', self.id)\nend\nfunction inside(self)\n print('you are inside zone ' .. self.id)\nend\nlocal poly = lib.zones.poly({\n points = {\n vec(413.8, -1026.1, 29),\n vec(411.6, -1023.1, 29),\n vec(412.2, -1018.0, 29),\n vec(417.2, -1016.3, 29),\n vec(422.3, -1020.0, 29),\n vec(426.8, -1015.9, 29),\n vec(431.8, -1013.0, 29),\n vec(437.3, -1018.4, 29),\n vec(432.4, -1027.2, 29),\n vec(424.7, -1023.5, 29),\n vec(420.0, -1030.2, 29),\n vec(409.8, -1028.4, 29),\n },\n thickness = 2,\n debug = true,\n inside = inside,\n onEnter = onEnter,\n onExit = onExit\n})\nlocal sphere = lib.zones.sphere({\n coords = vec3(442.5363, -1017.666, 28.65637),\n radius = 1,\n debug = true,\n inside = inside,\n onEnter = onEnter,\n onExit = onExit\n})\nlocal box = lib.zones.box({\n coords = vec3(442.5363, -1017.666, 28.65637),\n size = vec3(1, 1, 1),\n rotation = 45,\n debug = true,\n inside = inside,\n onEnter = onEnter,\n onExit = onExit\n})","zone-creation-script#Zone creation script":"You can use our builtin zone-creator with /zone - with poly, box or sphere as an argument.\nAvailable controls will be displayed on the right side.Zones will be saved to ox_lib/created_zones.lua with your chosen format.\nlocal poly = lib.zones.poly({\n name = poly,\n points = {\n vec(447.9, -998.8, 25.8),\n vec(450.3, -998.2, 25.8),\n vec(449.9, -995.5, 25.8),\n vec(447.2, -995.6, 25.8),\n vec(446.3, -997.9, 25.8),\n },\n thickness = 2,\n})\n{\n name = poly,\n points = {\n vec(447.9, -998.8, 25.8),\n vec(450.3, -998.2, 25.8),\n vec(449.9, -995.5, 25.8),\n vec(447.2, -995.6, 25.8),\n vec(446.3, -997.9, 25.8),\n },\n thickness = 2,\n},\nexports.ox_target:addPolyZone({\n name = poly,\n points = {\n vec(447.9, -998.8, 25.8),\n vec(450.3, -998.2, 25.8),\n vec(449.9, -995.5, 25.8),\n vec(447.2, -995.6, 25.8),\n vec(446.3, -997.9, 25.8),\n },\n thickness = 2,\n})"}},"/ox_target/Options":{"title":"Options","data":{"":"When creating a targetable option you must send an array of options with the following properties.","option-parameters#Option Parameters":"label: string\nname?: string\nAn identifier used when removing an option.\nicon?: string\nName of a Font Awesome icon.\niconColor?: string\ndistance?: number\nThe max distance to display the option.\nbones?: string or string[]\nA bone name or array of bone names (see GetEntityBoneIndexByName).\noffset?: vector3\nOffset the targetable area of an entity, relative to the model dimensions.\noffsetAbsolute?: vector3\nOffset the targetable area of an entity, relative to the entity's world coords.\noffsetSize?: number\nThe radius of the targetable area for an entity offset.\ngroups?: string or string[] or table\nA group, array of groups, or pairs of groups-grades required to show the option.\nGroups are framework dependent, and may refer to jobs, gangs, etc.\nitems?: string or string[] or table\nAn item, array of items, or pairs of items-count required to show the option.\nItems are framework dependent.\nanyItem?: boolean\nOnly require a single item from the items table to exist.\ncanInteract?: function(entity, distance, coords, name, bone)\nOptions will always display if this is undefined.\nmenuName?: string\nThe option is only displayed when a menu has been set with openMenu.\nopenMenu?: string\nSets the current menu name, displaying only options for the menuName.\nonSelect?: function(data)\nexport?: string\nevent?: string\nserverEvent?: string\ncommand?: string","option-effects#Option Effects":"When selecting an option it will trigger a single action, in order of priority:\nonSelect function\nexport\nevent\nserver event\ncommand"}},"/oxmysql":{"title":"OxMySQL","data":{"":"A replacement of mysql-async and ghmattimysql with expanded API and improved compatibility for MySQL 8.","mysql-or-mariadb#MySQL or MariaDB?":"Most resources for FiveM were designed to be used with MySQL 5.7 and may hit compatibility issues when using MySQL 8, i.e.\nMore reserved keywords, like 'stored' and 'group'.\nLongtext / JSON fields do not support default values.\nMariaDB is highly recommended for compatibility, and improved performance (over all versions of MySQL).","should-i-use-xampp#Should I use XAMPP?":"No. XAMPP is a webserver stack intended to be used for development, allowing easy local development and testing.\nDo not setup XAMPP just to run your database, and install MariaDB directly instead.","installation#Installation":"","download-the-latest-release#Download the latest release.":"","configure-your-server#Configure your server":"When using convars do not replicate sensitive information to the client.\nset will only be set on the server, while setr is replicated.\nStart by opening your server configuration (i.e. server.cfg) and adding start oxmysql before any of its dependents (usually it's the first resource you start).\nSet a mysql connection string using either of the following formats, using your server authentication details and target database.\nset mysql_connection_string \"mysql://root:12345@localhost:3306/es_extended\"\nset mysql_connection_string \"user=root;password=12345;host=localhost;port=3306;database=es_extended\"\nCertain special characters are reserved or unsupported depending on your connection string.\nAvoid using these characters ; , / ? : @ & = + $ #, and try swapping connection string format.","slow-query-warnings#Slow query warnings":"By default you will receive warnings if a query took ~150ms to complete, however\nQuery time is calculated on fxserver based on response time, and may not be entirely accurate.\nServer hitches may delay the query response, and may not indicate a database issue.\nExcessive queries in a short timeframe may report with higher response times.\nYou can adjust the minimum response time with a convar.\nset mysql_slow_query_warning 150\nSlow query warnings are only shown if mysql_ui or mysql_debug is enabled.","debug#Debug":"Enabling the debug option will print all queries in the server console; you can also use an array to only print from a list of resources instead.\nset mysql_debug true\nset mysql_debug [\n \"ox_core\",\n \"ox_inventory\"\n]\nThis value can be changed without restarting oxmysql, and you can temporarily modify the list with commands.\noxmysql_debug remove ox_core\noxmysql_debug add ox_core","mysql-async-compatibility#mysql-async compatibility":"The mysql-async directory must be deleted to properly provide support.\n🗹 Supports server_script '@mysql-async/lib/MySQL.lua'.\n🗹 Supports MySQL.Sync and MySQL.Async methods.\n☐ Raw exports are not supported (i.e. exports['mysql-async].mysql_execute).\n☐ Multi-statements are disabled for security reasons (see #102).","ghmattimysql-compatibility#ghmattimysql compatibility":"The ghmattimysql resource must be stopped to properly provide support.\n🗹 Supports exports.ghmattimysql.execute and other similar exports.\n🗹 Supports exports.ghmattimysql.executeSync and other similar exports.","usage#Usage":"Resources can import oxmysql methods by including our library, granting some type-checking and minor performance improvements over raw export calls.","lua#Lua":"Modify fxmanifest.lua for your resource, and add the following above any other script files.\nserver_script '@oxmysql/lib/MySQL.lua'\nIf you're using Lua Language Server you can get access to basic types and intellisense.\n\"Lua.workspace.library\": [\n \"C:/pathtoserver/resources/oxmysql/lib/define.lua\",\n]","javascript#JavaScript":"You can use raw exports, or install our npm package for intellisense and similar usage as Lua.\n# With pnpm\npnpm add @overextended/oxmysql\n# With Yarn\nyarn add @overextended/oxmysql\n# With npm\nnpm install @overextended/oxmysql\nImport the oxmysql object into your resource.\nimport { oxmysql as MySQL } from '@overextended/oxmysql';","upserting#Upserting":"When uncertain if a row should be inserted into the database, or an existing row should be updated, queries should check for duplicate keys.\nMySQL.prepare('INSERT INTO ox_inventory (owner, name, data) VALUES (?, ?, ?) ON DUPLICATE KEY UPDATE data = VALUES(data)', { owner, dbId, inventory })\nThis is preferred over checking the existence of a row, then inserting or updating depending on the result.\nFurthermore, unlike using 'REPLACE INTO', the row is not deleted and re-inserted."}},"/oxmysql/Functions/prepare":{"title":"prepare","data":{"":"Prepare can be used to execute frequently called queries faster and accepts multiple sets of parameters to be used with a single query.\nDate will not return the datestring commonly used in FiveM\nTINYINT 1 and BIT will not return a boolean\nYou can only use ? value placeholders, ?? column placeholders and named placeholders will throw an error\nUnlike rawExecute, the SELECT statement will return a column, row, or array of rows depending on the number of columns and rows selected.","promise#Promise":"local response = MySQL.prepare.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n})\nprint(json.encode(response, { indent = true, sort_keys = true }))\nconst response = await MySQL.prepare('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n])\nconsole.log(JSON.stringify(response))\nAliases\nexports.oxmysql.prepare_async","callback#Callback":"MySQL.prepare('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n}, function(response)\n print(json.encode(response, { indent = true, sort_keys = true }))\nend)\nMySQL.prepare('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n], (response) => {\n console.log(JSON.stringify(response))\n})\nAliases\nexports.oxmysql.prepare"}},"/oxmysql/Functions/insert":{"title":"insert","data":{"":"Inserts a new entry into the database and returns the insert id for the row, if valid.","promise#Promise":"local id = MySQL.insert.await('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', {\n identifier, firstName, lastName\n})\nprint(id)\nconst id = await MySQL.insert('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', [\n identifier, firstName, lastName\n])\nconsole.log(id)\nAliases\nMySQL.Sync.insert\nexports.ghmattimysql.executeSync\nexports.oxmysql.insert_async","callback#Callback":"MySQL.insert('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', {\n identifier, firstName, lastName\n}, function(id)\n print(id)\nend)\nMySQL.insert('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', [\n identifier, firstName, lastName\n], (id) => {\n console.log(id)\n})\nAliases\nMySQL.Async.insert\nexports.ghmattimysql.execute\nexports.oxmysql.insert"}},"/oxmysql/Functions/query":{"title":"query","data":{"":"When selecting data, returns all matching rows and columns; otherwise, returns data like insertId, affectedRows, etc.","promise#Promise":"local response = MySQL.query.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n})\nif response then\n for i = 1, #response do\n local row = response[i]\n print(row.firstname, row.lastname)\n end\nend\nconst response = await MySQL.query('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n])\nif (response) {\n response.forEach((row) => {\n console.log(row.identifier, row.firstname, row.lastname)\n })\n}\nAliases\nMySQL.Sync.fetchAll\nexports.ghmattimysql.execute\nexports.oxmysql.query_async","callback#Callback":"MySQL.query('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n}, function(response)\n if response then\n for i = 1, #response do\n local row = response[i]\n print(row.firstname, row.lastname)\n end\n end\nend)\nMySQL.query('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n], (response) => {\n if (response) {\n response.forEach((row) => {\n console.log(row.firstname, row.lastname)\n })\n }\n})\nAliases\nMySQL.Async.fetchAll\nexports.ghmattimysql.execute\nexports.oxmysql.query"}},"/oxmysql/Functions/rawExecute":{"title":"rawExecute","data":{"":"rawExecute can be used to execute frequently called queries faster and accepts multiple sets of parameters to be used with a single query.\nDate will not return the datestring commonly used in FiveM\nTINYINT 1 and BIT will not return a boolean\nYou can only use ? value placeholders, ?? column placeholders and named placeholders will throw an error\nUnlike prepare, the SELECT statement will always return an array of rows.\nWhen using SELECT, the return value will match query, single, or scalar depending on the number of columns and rows selected.","promise#Promise":"local response = MySQL.rawExecute.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n})\nprint(json.encode(response, { indent = true, sort_keys = true }))\nconst response = await MySQL.rawExecute('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n])\nconsole.log(JSON.stringify(response))\nAliases\nexports.oxmysql.rawExecute_async","callback#Callback":"MySQL.rawExecute('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n}, function(response)\n print(json.encode(response, { indent = true, sort_keys = true }))\nend)\nMySQL.rawExecute('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n], (response) => {\n console.log(JSON.stringify(response))\n})\nAliases\nexports.oxmysql.rawExecute"}},"/oxmysql/Functions/scalar":{"title":"scalar","data":{"":"Returns the first column for a single row.","promise#Promise":"local firstName = MySQL.scalar.await('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', {\n identifier\n})\nprint(firstName)\nconst firstName = await MySQL.scalar('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', [\n identifier\n])\nconsole.log(firstName)\nAliases\nMySQL.Sync.fetchScalar\nexports.ghmattimysql.scalar\nexports.oxmysql.scalar_async","callback#Callback":"MySQL.scalar('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', {\n identifier\n}, function(firstName)\n print(firstName)\nend)\nMySQL.scalar('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', [\n identifier\n], (firstName) => {\n console.log(firstName)\n})\nAliases\nMySQL.Async.fetchScalar\nexports.ghmattimysql.scalar\nexports.oxmysql.scalar"}},"/oxmysql/Functions/single":{"title":"single","data":{"":"Returns all selected columns for a single row.","promise#Promise":"local row = MySQL.single.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', {\n identifier\n})\nif not row then return end\nprint(row.firstname, row.lastname)\nconst row = await MySQL.single('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', [\n identifier\n])\nif (!row) return;\nconsole.log(row.firstname, row.lastname)\nAliases\nexports.oxmysql.single_async","callback#Callback":"MySQL.single('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', {\n identifier\n}, function(row)\n if not row then return end\n print(row.firstname, row.lastname)\nend)\nMySQL.single('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', [\n identifier\n], (row) => {\n if (!row) return;\n console.log(row.firstname, row.lastname)\n})\nAliases\nexports.oxmysql.single"}},"/oxmysql/Functions/transaction":{"title":"transaction","data":{"":"A transaction executes multiple queries and commits them only if all succeed.\nIf one fails, none of the queries are committed.The return value is a boolean, which is the result of the transaction.","specific-format#Specific format":"When using this format, you must pass an array containing sets of queries and parameters to the transaction method.\nIn this case, your queries do not necessarily match and the values are unique to each query.\n-- You might rename \"values\" as \"parameters\" for mysql-async compatibility.\nlocal queries = {\n { query = 'INSERT INTO `test` (id) VALUES (?)', values = { 1 }},\n { query = 'INSERT INTO `test` (id, name) VALUES (?, ?)', values = { 2, 'bob' }},\n}\n-- You can also pass an array of arrays.\nlocal queries = {\n { 'INSERT INTO `test` (id) VALUES (?)', { 1 } },\n { 'INSERT INTO `test` (id, name) VALUES (?, ?)', { 2, 'bob' } },\n}","shared-format#Shared format":"When using this format, you must pass an array containing queries and a set containing shared parameters to the transaction method.\nIn this case, your queries do not necessarily match and the values are unique to each query.\n-- You might rename \"values\" as \"parameters\" for mysql-async compatibility.\nlocal queries = {\n 'INSERT INTO `test` (id, name) VALUES (@someid, @somename)',\n 'SET `name` = @newname IN `test` WHERE `id` = @someid'\n}\nlocal values = {\n someid = 2,\n somename = 'John Doe',\n newname = 'John Notdoe'\n}","promise#Promise":"local success = MySQL.transaction.await(queries, values --[[leave nil for specific format]])\nprint(success)\nconst success = await MySQL.transaction(queries, values /*leave nil for specific format*/)\nconsole.log(success)\nAliases\nMySQL.Sync.transaction\nexports.ghmattimysql.transaction\nexports.oxmysql.transaction_async","callback#Callback":"-- specific\nMySQL.transaction(queries, values, function(success)\n print(success)\nend)\n-- shared\nMySQL.transaction(queries, function(success)\n print(success)\nend)\n// specific\nMySQL.transaction(queries, (success) => {\n console.log(success)\n})\n// shared\nMySQL.transaction(queries, values, (success) => {\n console.log(success)\n})\nAliases\nMySQL.Async.transaction\nexports.ghmattimysql.transaction\nexports.oxmysql.transaction","transaction-isolation-level#Transaction Isolation Level":"This can be set through the convar mysql_transaction_isolation_level, and is an integer ranging from 1-4.\nThe default value is 2.\nConvar Value\tResult\t1\tRepeatable Read\t2\tRead Committed\t3\tRead Uncommitted\t4\tSerializable"}},"/oxmysql/placeholders":{"title":"Placeholders","data":{"":"Placeholders allow for query parameters to be safely executed, preventing common SQL injection methods.Parameters can be passed an an array or map (referred to as named named parameters).\nlocal identifier = 'license:abc123'\nlocal group = 'admin'\nMySQL.scalar('SELECT `username` FROM `users` WHERE `identifier` = ? AND `group` = ?', { identifier, group })\n-- Named placeholders (deprecated)\nMySQL.scalar('SELECT `username` FROM `users` WHERE `identifier` = @identifier AND `group` = @group', {\n group = group\n identifier = identifier\n})\nThese are distinct from prepared statements which are handled by the MySQL server; you can use MySQL.prepare for more optimised and secure queries."}},"/ox_lib/Modules/Cache/Client":{"title":"Client","data":{"":"Values and cache functionality available to the client, in addition to the shared values.","default-values#Default values":"ped: number\nplayer entity id\nplayerId: number\nplayer id\nserverId: number\nplayer server id\nweapon: number or false\ncurrent weapon hash\nvehicle: number or false\nvehicle entity id\nseat: number or false\nvehicle seat index\ncoords: vector3\ncurrent player coords\nonly populated if using zones or points\ncannot be listened for with lib.onCache\nmount: number or false (RedM only)\nmount entity id","liboncache#lib.onCache":"Register an event handler that is triggered when the cached value is updated.\nlib.onCache(key, function(value) end)\nkey: string\nped\nvehicle\nseat\nweapon\nmount (RedM only)\nvalue: any\nlib.onCache('vehicle', function(value)\n print('old vehicle:', cache.vehicle)\n print('new vehicle:', value)\nend)\nimport { onCache } from '@overextended/ox_lib/client';\nonCache(key, (value) => {});\nkey: string\nped\nvehicle\nseat\nweapon\nmount (RedM only)\nvalue: any\nimport { cache, onCache } from '@overextended/ox_lib/client';\nlib.onCache('vehicle', (value) => {\n console.log('old vehicle:', cache.vehicle);\n console.log('new vehicle:', value);\n});"}},"/oxmysql/ui":{"title":"Using the Debug UI","data":{"":"The debug UI lets you easily see all the queries that have been executed by resources, query response times, and per-resource statistics.\nYou should only enable this during development, or with a small player count - for larger servers, look into builtin MySQL logging.Before using the UI first you have to make sure you have the mysql_ui convar set to true:\nset mysql_ui true\nAlso make sure that you have command or command.mysql ace permission access, then you should be able to use the mysql command in game.\nYou do not need to have the mysql_debug enabled to use the debug ui.","main-page#Main page":"The main page shows you the resources that ran queries where you can filter them through a search bar, your general data\nalong side a pie chart which shows what resources took the most query time.","resource-page#Resource page":"The resource page shows you all the queries and their execution time inside a table that the resource previously ran,\nalongside the total amount of the queries, execution time and slow queries for the selected resource.Columns can be sorted by ascending and descending order, and hovering over a query will display the full query inside a tooltip.\nQueries that exceed mysql_slow_query_warning (default 150ms) are displayed in orange.\nFor demonstation purposes the mysql_slow_query_warning convar was set to 5 here."}},"/oxmysql/issues":{"title":"Common Issues","data":{"unable-to-establish-a-connection#Unable to establish a connection":"This is usually the result of incorrect database settings or your password containing reserved characters.\n; , / ? : @ & = + $ # are reserved.\nEnsure you have entered the correct database settings in the mysql_connection_string convar. You can try using the\nsemicolon-separated format if your password contains reserved characters.","no-such-export--in-resource-oxmysql#No such export ... in resource oxmysql":"Download the latest release build (not the source code) of oxmysql.\nEnsure it is starting before any resources that require it.","numbers-treated-as-string#Numbers treated as string":"To resolve this issue simply enable decimalNumbers in your connection string, ie. mysql://root@localhost/essentialmode?decimalNumbers=true.\nJavaScript treats all numbers as floats, so a double or decimal value will be cast as a float with this setting.\nNumbers will have less precision when this setting is enabled."}},"/guides/nodejs":{"title":"Node.js","data":{"":"Node.js is a JavaScript runtime and is used for building applications. In the context of FiveM it is necessary to bundle resources into a single package that can be ran on both the server and client.\nDownload and install the LTS version of Node.js.\nOpen a command-line terminal (e.g. Terminal, Command Prompt).\nEnter node --version to confirm successful installation."}},"/guides/vscode":{"title":"VS Code","data":{"":"Visual Studio Code is our recommended editor when working with Lua.","recommended-extensions#Recommended extensions":"Extensions let you add languages, debuggers, and other tools to VS Code - improving your developer experience.","sumnekolua#sumneko.lua":"Lua Language Server provides numerous language features to make development easier and faster, e.g.\nAnnotations\nAutocompletion\nCode formatting\nDiagnostics/warnings\nDynamic type checking\nSyntax checking","overextendedcfxlua-vscode#overextended.cfxlua-vscode":"Works alongside Lua Language Server to provide function and type declarations from Cfx's Lua runtime, Lua dialect, environment globals, and game natives."}},"/ox_inventory/Guides/shops":{"title":"Creating Shops","data":{"":"Builtin shops are defined in data/shops.lua, and more can be added here to benefit from the built-in markers or zones support.","shop-definition#Shop definition":"{\n General = {\n name = 'Shop',\n blip = {\n id = 59,\n colour = 69,\n scale = 0.8\n },\n inventory = {\n { name = 'burger', price = 10 },\n { name = 'water', price = 10 },\n { name = 'cola', price = 10 },\n },\n locations = {\n vec3(25.7, -1347.3, 29.49),\n },\n targets = {\n -- Shop using a BoxZone\n {\n loc = vec3(25.06, -1347.32, 29.5),\n length = 0.7,\n width = 0.5,\n heading = 0.0,\n minZ = 29.5,\n maxZ = 29.9,\n distance = 1.5\n },\n -- Shop using a ped\n {\n ped = `mp_m_shopkeep_01`,\n scenario = 'WORLD_HUMAN_AA_COFFEE',\n loc = vec3(24.407, -1347.283, 28.497),\n heading = 270.311,\n },\n }\n }\n}\nname: string\nThe label to display when the shop is open.\nblip?: table\nCreates a blip with the given settings. Leave it undefined for no blip to be created.\nid: number\ncolour: number\nscale: number\ngroups?: table\nKey-value pairs of job name and minimum grade to access the shop.\n{[\"police\"] = 0, [\"ambulance\"] = 2}\ninventory: table\nname: string\nprice: number\ncurrency?: string\nItem to be used as currency.\ncount?: number\nAmount of the item in the stock.\nlicense?: string\nLicense required to purchase the item.\nmetadata?: table\ngrade?: number | number[]\nGrade required to purchase the item.\nlocations?: vector3[]\nAn array of coordinates to create unique instances of the shop archetype at, using markers.\ntargets?: table[]\nAn array of target settings to create unique instances of the shop archetype at, using peds or BoxZones (PolyZone data structure).\nmodel?: number[]\nAn array of models that can be targetted to open a shop. Used for vending machines.\nTargets and model are only available when using a targeting resource like ox_target.","register-during-runtime#Register during runtime":"Shops can be added using exports.ox_inventory:RegisterShop on the server, however they cannot utilise any client-only features.\nBlips, markers, and zones will not be created.\nMust use \"locations\" and not \"targets\" to define each shop using the archetype.","example#Example":"exports.ox_inventory:RegisterShop('TestShop', {\n name = 'Test shop',\n inventory = {\n { name = 'burger', price = 10 },\n { name = 'water', price = 10 },\n { name = 'cola', price = 10 },\n },\n locations = {\n vec3(223.832962, -792.619751, 30.695190),\n },\n groups = {\n police = 0\n },\n})"}},"/oxmysql/Functions/update":{"title":"update","data":{"":"Returns the number of rows affected by the query.","promise#Promise":"local affectedRows = MySQL.update.await('UPDATE users SET firstname = ? WHERE identifier = ?', {\n newName, identifier\n})\nprint(affectedRows)\nconst affectedRows = await MySQL.update('UPDATE users SET firstname = ? WHERE identifier = ?', [\n newName, identifier\n])\nconsole.log(affectedRows)\nAliases\nMySQL.Sync.execute\nexports.ghmattimysql.executeSync\nexports.oxmysql.update_async","callback#Callback":"MySQL.update('UPDATE users SET firstname = ? WHERE identifier = ?', {\n newName, identifier\n}, function(affectedRows)\n print(affectedRows)\nend)\nMySQL.update('UPDATE users SET firstname = ? WHERE identifier = ?', [\n newName, identifier\n], (affectedRows) => {\n console.log(affectedRows)\n})\nAliases\nMySQL.Async.execute\nexports.ghmattimysql.execute\nexports.oxmysql.update"}},"/oxmysql/benchmark":{"title":"Benchmark","data":{"":"Benchmarking is based on the time spent when to receive a response from exports.\nReal query speeds will be reported in the debug UI and in the server console with mysql_debug enabled.Speeds will vary greatly based on system hardware, database settings, database version, and the current workload.","script#Script":"This script tests export times when using the Lua 5.4 runtime with lib/MySQL.lua syntax.\nlocal function execQuery(msg, fn, query, parameters)\n local start = os.nanotime()\n local result = fn(query, parameters)\n local finish = os.nanotime()\n print()\n print(msg)\n print('Executed ' .. (type(query) == 'string' and 1 or #query) .. ' queries in ' .. (finish - start) / 1e6 .. 'ms')\n return result\nend\nCreateThread(function()\n local initTable = {\n 'DROP TABLE `test_table`',\n [[CREATE TABLE `test_table` (\n `id` INT UNSIGNED NOT NULL AUTO_INCREMENT,\n `username` VARCHAR(50) NOT NULL DEFAULT '0',\n `identifier` VARCHAR(50) NOT NULL DEFAULT '0',\n PRIMARY KEY (`id`)\n )]],\n 'TRUNCATE `test_table`',\n 'ALTER TABLE `test_table` AUTO_INCREMENT = 1',\n }\n execQuery('initialise test_table', MySQL.transaction.await, initTable)\n -- You might rename \"values\" as \"parameters\" for mysql-async compatibility.\n local queries = {\n { query = 'INSERT INTO `test_table` (identifier) VALUES (?)', values = { 'abcdef1' }},\n { query = 'UPDATE `test_table` SET `username` = ? WHERE `id` = LAST_INSERT_ID()', values = { 'bob1' }},\n }\n execQuery('{ query: string, values: string }[] transaction', MySQL.transaction.await, queries)\n -- You can pass an array of arrays.\n queries = {\n { 'INSERT INTO `test_table` (identifier) VALUES (?)', { 'abcdef2' } },\n { 'UPDATE `test_table` SET `username` = ? WHERE `id` = LAST_INSERT_ID()', { 'bob2' } },\n }\n execQuery('[string, any[]][] transaction', MySQL.transaction.await, queries)\n -- You can pass an array of queries.\n queries = {\n 'INSERT INTO `test_table` (identifier) VALUES (\"abcdef3\")',\n 'UPDATE `test_table` SET `username` = \"bob3\" WHERE `id` = LAST_INSERT_ID()',\n }\n execQuery('string[] transaction', MySQL.transaction.await, queries)\n local insertUsers = {}\n for i = 1, 10000 do\n insertUsers[i] = { 'INSERT INTO `test_table` (username, identifier) VALUES (?, ?)',\n { 'Testuser_' .. i, 'abcdef' .. i } }\n end\n execQuery('insert ' .. #insertUsers .. ' test users', MySQL.transaction.await, insertUsers)\n local selectUserIds = {}\n for i = 1, 10000 do\n if i % 4 == 0 then\n selectUserIds[math.tointeger(i / 4)] = { 'abcdef' .. i }\n end\n end\n execQuery('select every 4th userid', MySQL.prepare.await, 'SELECT `id` FROM `test_table` WHERE `identifier` = ? LIMIT 1', selectUserIds)\n local insertid = execQuery('insert', MySQL.insert.await, 'INSERT INTO `test_table` (identifier) VALUES (?)', { 'abcdef' })\n local update = execQuery('update', MySQL.update.await, 'UPDATE `test_table` SET `username` = ? WHERE `id` = ?', { 'bobby', insertid })\n local scalar = execQuery('scalar', MySQL.scalar.await, 'SELECT `username` FROM `test_table` WHERE `id` = ?', { insertid })\n local single = execQuery('single', MySQL.single.await, 'SELECT * FROM `test_table` WHERE `id` = ?', { insertid })\n print(json.encode(execQuery('prepare', MySQL.prepare.await, 'SELECT `username` FROM `test_table` WHERE `id` = ?', { insertid })))\n print(insertid, update, scalar, json.encode(single))\n execQuery('query', MySQL.query.await, 'SELECT `username` FROM `test_table` WHERE `id` = ? LIMIT 1', { 419 })\nend)","results#Results":"[script:test] initialise test_table\n[script:test] Executed 4 queries in 42.7789ms\n[script:test]\n[script:test] { query: string, values: string }[] transaction\n[script:test] Executed 2 queries in 8.0145ms\n[script:test]\n[script:test] [string, any[]][] transaction\n[script:test] Executed 2 queries in 4.0278ms\n[script:test]\n[script:test] string[] transaction\n[script:test] Executed 2 queries in 3.4743ms\n[script:test]\n[script:test] insert 10000 test users\n[script:test] Executed 10000 queries in 2064.211ms\n[script:test]\n[script:test] select every 4th userid\n[script:test] Executed 1 queries in 2803.7134ms\n[script:test]\n[script:test] insert\n[script:test] Executed 1 queries in 2.8743ms\n[script:test]\n[script:test] update\n[script:test] Executed 1 queries in 2.8675ms\n[script:test]\n[script:test] scalar\n[script:test] Executed 1 queries in 1.5387ms\n[script:test]\n[script:test] single\n[script:test] Executed 1 queries in 1.3389ms\n[script:test]\n[script:test] prepare\n[script:test] Executed 1 queries in 1.6577ms\n[script:test] \"bobby\"\n[script:test] 10004 1 bobby {\"identifier\":\"abcdef\",\"username\":\"bobby\",\"id\":10004}\n[script:test]\n[script:test] query\n[script:test] Executed 1 queries in 1.1588ms"}}} \ No newline at end of file +{"/guides/git":{"title":"Git","data":{"":"Git is a version control system, allowing changes to be effectively tracked, merged, and reverted.As our resources are hosted on GitHub, it can be incredibly useful to learn how to create your own repository to track changes and keep up-to-date. If you plan on making your own changes to our resources, this will allow you to keep your own changes and prevent loss of data.\nRefer to GitHub's guide to setting up Git.\nYou can use a Git GUI client like GitKraken to improve your workflow and more easily maintain changes."}},"/guides/pnpm":{"title":"pnpm","data":{"":"pnpm is a fast and disk space efficient package manager, serving as an alternative to npm and yarn.\nEnsure you have installed Node.js.\nOpen a command-line terminal (e.g. Terminal, Command Prompt).\nEnter npm install -g pnpm to globally install the package.\nYou can install dependencies with pnpm using pnpm i.\nYou can reference package.json files for available scripts, i.e.\n\"scripts\": {\n \"start\": \"vite\",\n \"watch\": \"vite build --watch\",\n \"build\": \"tsc && vite build\",\n \"preview\": \"vite preview\",\n \"format\": \"prettier --write \\\"./src/**/*.{ts,tsx,css}\\\"\"\n},\nUsing the example above pnpm build will run the build script for the given package."}},"/guides/types":{"title":"Types","data":{"setup-git-vscode-and-vscode-extensions#Setup git, vscode, and vscode extensions":"","download-our-lua-type-definitions#Download our Lua type definitions":"git clone https://github.com/overextended/ox_types.git`","update-your-settings#Update your settings":"You can modify the user, workspace, or folder settings for vscode.\nCreate an entry in Lua.workspace.library pointing to the cloned directory, or specific subdirectories.\n\"Lua.workspace.library\": [\n \"F:/GitHub/ox_types/types\",\n \"F:/GitHub/ox_lib\"\n],"}},"/":{"title":"Introduction","data":{"":"Here you can find all of the official documentation for resources developed by the Overextended team.If you feel like the documentation is lacking in some department then feel free to go onto that page and click the \"Edit this page\" at the bottom and submit a Pull Request.","support-our-team#Support our team":"Our projects will always remain free and open-source, with our core developers working voluntarily.\nIf you love what we do and want to help us continue, why not show your appreciation with a donation?","creator-codes#Creator codes":"Creator codes allow Tebex stores to share a percentage of a purchase with us, while giving a discount to the customer. We make these deals to advertise trusted creators who meet our criteria.\nResources are highly configurable or, preferably, source-available.\nWe trust that customers will be given assistance.\nThe creator is a known member of our community.\nMore information about these creators is available in our Discord.\nStore\tCode\tDiscount\tLink\tAndyyy\tox20\t20%\thttps://andyyy.tebex.io/\tBerkie's Workshop\tox10\t10%\thttps://berkie.tebex.io/\tDolu Mods\toverextended\t15%\thttps://dolu.tebex.io/\tElectus Scripts\tox10\t10%\thttps://store.electus-scripts.com/\tLoaf Scripts\tox5\t5%\thttps://store.loaf-scripts.com/\tOT Studios\tox10\t10%\thttps://store.otstudios.net/ox\tPickle Mods\tox30\t30%\thttps://store.picklemods.com/\trcore\tox10\t10%\thttps://store.rcore.cz/\tRoleplay inventory icons\tox10\t10%\thttps://pixel-art-roleplay-inventory-i.tebex.io/\tRenewed Scripts\tox15\t15%\thttps://renewed.tebex.io/\tWasabi Scripts\tOX20\t20%\thttps://store.wasabiscripts.com/\t\nYou can apply a creator code at checkout under \"Support A Creator\"."}},"/ox_core":{"title":"Ox Core","data":{"":"An experimental framework for FiveM. Limited support and breaking changes guaranteed.\nThis resource does not have a stable (v1.0) release; breaking changes are likely.\nDocumentation may not be kept updated in some cases.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","install-all-resource-dependencies#Install all resource dependencies.":"oxmysql\nox_lib\nfivem-appearance\nox_appearance","download-a-release-or-build-the-source-code#Download a release or build the source code.":"git clone https://github.com/overextended/ox_core.git\ncd ox_core/web\npnpm i\npnpm build","install-optional-dependencies#Install optional dependencies.":"These resources aren't required but provide additional functionality.\nox_inventory\nnpwd\npefcl","optional-configure-pefcl#(Optional) Configure pefcl":"If using it with ox_inventory, open pefcl/config.json and enable framework integration.\n\"frameworkIntegration\": {\n \"enabled\": true,\n \"resource\": \"ox_inventory\",\n \"syncInitialBankBalance\": false\n},","importing-into-resources#Importing into resources":"","lua#Lua":"Lua imports can be defined as part of fxmanifest, or loaded with the load function.\nclient_scripts {\n '@ox_core/imports/client.lua',\n 'client/main.lua',\n}\nserver_scripts {\n '@oxmysql/lib/MySQL.lua',\n '@ox_core/imports/server.lua',\n 'server/main.lua',\n}\nlocal file = ('imports/%s.lua'):format(IsDuplicityVersion() and 'server' or 'client')\nlocal import = LoadResourceFile('ox_core', file)\nlocal chunk = assert(load(import, ('@@ox_core/%s'):format(file)))\nchunk()","javascript#JavaScript":"To use ox_core with your JS/TS resources you'll need to use our npm package, allowing you to import core functions with full type and intellisense support.","config#Config":"Resource configuration is handled using convars.\n# Players must have a valid identifier to join the server. Used to fetch userid from the database.\nset ox:primaryIdentifier \"fivem\"\n# Set the number of active characters a user can have registered.\nsetr ox:characterSlots 5\n# Enables debug and development features. Should only be used in a development environment.\nsetr ox:debug 0\n# Disable death system handle by core.\nsetr ox:deathSystem 0\n# Disable the spawn selection.\nsetr ox:spawnSelect 0"}},"/ox_core/Client/Player":{"title":"Client","data":{"":"When ox_core is imported into a resource it will create the player global.\nIf player is nil, then the client has not yet selected a character and spawned.Example:\nprint(json.encode(player, { indent = true }))\nplayer?: table\nuserId: number\ncharId: number\nstateId: string\nfirstName: string\nlastName: string\nname: string\ngroups: table"}},"/ox_core/Client/Player/callbacks":{"title":"Callbacks","data":{"oxgetstatus#ox:getStatus":"lib.callback.await('ox:getStatus', delay, targetId, statusName)\ndelay: number\ntargetId: number\nThe server id for the player to get statuses for.\nstatusName?: string\nThe name of the status (i.e. hunger). Can be omitted to return all statuses.","oxgetlicense#ox:getLicense":"lib.callback.await('ox:getLicense', delay, licenseName, targetId)\ndelay: number\nlicenseName: string\nThe name of the license to get data for. Can be omitted to return all licenses.\ntargetId?: number\nThe server id to get license data for, defaulting to the current player.","oxgetnearbyvehicles#ox:getNearbyVehicles":"lib.callback.register('ox:getNearbyVehicles', function(radius)\nReturns an array of vehicle netids within a given radius of the player's location.\nradius?: number\nThe radius from the player's location to return vehicles."}},"/ox_core/Client/Player/events":{"title":"Events","data":{"client-events#Client events":"","oxplayerloaded#ox:playerLoaded":"Triggered once the player has selected a character and spawned.\nAddEventHandler('ox:playerLoaded', function(data) end)","oxplayerlogout#ox:playerLogout":"Triggered when the player enters character selection if they were previously playing a character.\nAddEventHandler('ox:playerLogout', function() end)","oxstatustick#ox:statusTick":"Triggered every 1000ms interval, when status values are updated internally.\nAddEventHandler('ox:statusTick', function(statuses) end)","oxplayerdeath#ox:playerDeath":"Triggered on player death and revival.\nAddEventHandler('ox:playerDeath', function(isDead) end)","networked-events#Networked events":"","oxsetgroup#ox:setGroup":"Triggered when the player's grade in a group is modified on the server with player.setGroup.\nRegisterNetEvent('ox:setGroup', function(group, grade) end)","oxlicenseadded#ox:licenseAdded":"Triggered when the player has been granted a license.\nRegisterNetEvent('ox:licenseAdded', function(name) end)","oxlicenseremoved#ox:licenseRemoved":"Triggered when the player's license is revoked.\nRegisterNetEvent('ox:licenseRemoved', function(name) end)"}},"/ox_core/Client/functions":{"title":"Functions","data":{"":"todo"}},"/ox_core/Server/Player":{"title":"Server","data":{"oxgetplayer#Ox.GetPlayer":"Return an instance of OxPlayer for the given player source.\nlocal player = Ox.GetPlayer(source)\nprint(json.encode(player, { indent = true }))\nimport { GetPlayer } from '@overextended/ox_core/server';\nconst player = GetPlayer(source);\nconsole.log(JSON.stringify(player));\nplayer?: table\nsource: number\nuserId: number\ncharId: number\nstateId: string\nfirstName: string\nlastName: string\nname: string\nusername: string","oxgetplayerbyfilter#Ox.GetPlayerByFilter":"Return the first OxPlayer that matches the filter properties.\nlocal filter = { phoneNumber = '556-560-6609' }\nlocal player = Ox.GetPlayerByFilter(filter)\nprint(json.encode(player, { indent = true }))\nimport { GetPlayerByFilter } from '@overextended/ox_core/server';\nconst filter = { phoneNumber: '556-560-6609' };\nconst player = GetPlayerByFilter(filter);\nconsole.log(JSON.stringify(player));","oxgetplayers#Ox.GetPlayers":"Returns an array containing all players. Methods will not be applied if the first argument is false.\nPlayers can be filtered to only return players that match the given properties, or groups.\n-- Get an array containing all players in the police or sheriff groups, with grade 3 or higher.\nlocal filter = { groups = {['sheriff'] = 3, ['police'] = 3} })\nlocal players = Ox.GetPlayers(filter)\nfor i = 1, #players do\n local player = players[i]\n print(json.encode(player, { indent = true }))\nend\nimport { GetPlayers } from '@overextended/ox_core/server';\n// Get an array containing all players in the police or sheriff groups, with grade 3 or higher.\nconst filter = { groups: { sheriff: 3, police: 3 } })\nconst players = GetPlayers(filter);\nfor (let i = 0; i < players.length; i++) {\n const player = players[i];\n console.log(JSON.stringify(player));\n}"}},"/ox_core/Server/Player/events":{"title":"Events","data":{"server-events#Server events":"","oxplayerloaded#ox:playerLoaded":"Triggered after a player has selected a character.\nAddEventHandler('ox:playerLoaded', function(source, userid, charid) end)","oxsetgroup#ox:setGroup":"Triggered when a player's grade in a group is modified with player.setGroup.\nAddEventHandler('ox:setGroup', function(source, group, grade) end)","oxplayerlogout#ox:playerLogout":"Triggered when a player logs out from their current character or disconnects from the server.\nAddEventHandler('ox:playerLogout', function(source, userid, charid) end)","oxcharacterdeleted#ox:characterDeleted":"Triggered when a player has deleted a character.\nAddEventHandler('ox:characterDeleted', function(source, userid, charid) end)","oxlicenseadded#ox:licenseAdded":"Triggered when a player has been granted a license.\nAddEventHandler('ox:licenseAdded', function(source, name) end)","oxlicenseremoved#ox:licenseRemoved":"Triggered when a player's license is revoked.\nAddEventHandler('ox:licenseRemoved', function(source, name) end)","networked-events#Networked events":"","oxplayerdeath#ox:playerDeath":"Triggered on player death and revival.\nRegisterNetEvent('ox:playerDeath', function(isDead) end)","oxsetplayerinservice#ox:setPlayerInService":"Can be triggered to set a player as \"in service\" for a specific group they are a member of.\nRegisterNetEvent('ox:setPlayerInService', function(group) end)"}},"/ox_core/Server/Player/methods":{"title":"Methods","data":{"":"These functions are inherited from the Player class.","playerset#player.set":"Update the player's metadata, optionally syncing it with the client.\nplayer.set(key, value, replicated)\nkey: string\nvalue: any\nreplicated?: boolean","playerget#player.get":"Get a value from the player's metadata, or omit the argument to get all metadata.\nplayer.get(key)\nkey?: string","playergetstate#player.getState":"Return the player's statebag.\nplayer.getState()","playergetcoords#player.getCoords":"Return the player's position.\nplayer.getCoords()","playersetgroup#player.setGroup":"Updates the player's grade for the given group. Any value below 1 will remove the group from the player.\nplayer.setGroup(group, grade)\ngroup: string\ngrade?: number","playergetgroup#player.getGroup":"Returns the player's current grade for a given group.\nplayer.getGroup()","playergetgroups#player.getGroups":"Returns an object of all groups the player is in, with the current grade as the value.\nplayer.getGroups()","playerhasgroup#player.hasGroup":"Check if the player is a member of a given group, and returns the matching group name and grade.\nThe filter can be a string, array, or object where key is the group, and value is the minimum grade.\nplayer.hasGroup(filter)\nfilter: string | string[] | { [string]: number }","playersetstatus#player.setStatus":"Set the current value for a status (i.e. hunger, thirst).\nplayer.setStatus(name, value)\nname: string\nvalue: number","playeraddstatus#player.addStatus":"Add the given amount to the total value for a status (i.e. hunger, thirst).\nplayer.addStatus(name, value)\nname: string\nvalue: number","playerremovestatus#player.removeStatus":"Remove the given amount from the total value for a status (i.e. hunger, thirst).\nplayer.removeStatus(name, value)\nname: string\nvalue: number","playergetlicenses#player.getLicenses":"Get all licenses for the player.\nplayer.getLicenses()","playergetlicense#player.getLicense":"Get the license of the given name for the player, as an object containing license information.\nplayer.getLicense(name)\nname: string","playeraddlicense#player.addLicense":"Grants a license to the player and triggers 'ox:licenseAdded' on the server and client.\nplayer.addLicense(name)\nname: string","playerremovelicense#player.removeLicense":"Revokes a license from the player and triggers 'ox:licenseRemoved' on the server and client.\nplayer.removeLicense(name)\nname: string","playergetplayersinscope#player.getPlayersInScope":"Return an array of all player id's inside the player's scope.\nplayer.getPlayersInScope()","playerisplayerinscope#player.isPlayerInScope":"Check if the given source is inside the player's scope.\nplayer.isPlayerInScope(target)\ntarget: number","playertriggerscopedevent#player.triggerScopedEvent":"player.triggerScopedEvent(eventName, ...)\neventName: string\n...?: any[]"}},"/ox_core/Server/Vehicle":{"title":"Server","data":{"oxgetvehicle#Ox.GetVehicle":"Return an instance of OxVehicle for the given entity.\nlocal vehicle = Ox.GetVehicle(entity)\nprint(json.encode(vehicle, { indent = true }))","oxgetvehicles#Ox.GetVehicles":"Returns an array containing all vehicles. Methods will not be applied if the first argument is false.\nlocal vehicles = Ox.GetVehicles(usemetatable)\nfor i = 1, #vehicles do\n local vehicle = vehicles[i]\n print(json.encode(vehicle, { indent = true }))\nend","oxcreatevehicle#Ox.CreateVehicle":"Spawns a vehicle and returns the instance of OxVehicle.\nIf the first argument is a number, it will attempt to spawn a vehicle from the database with a matching id.\nlocal vehicleId = MySQL.scalar.await('SELECT id FROM vehicles WHERE owner = ? LIMIT 1', { player.charid })\nif vehicleId then\n local coords = player.getCoords()\n local vehicle = Ox.CreateVehicle(vehicleId, vector3(coords.x, coords.y + 1.0, coords.z) , GetEntityHeading(player.ped))\n if vehicle then\n print(json.encode(vehicle, { indent = true }))\n end\nend\nIf the first argument is a table and the owner property is a number, or nil, the vehicle will be added to the database.\nSetting the owner as false creates a non-persistent vehicle.\nlocal vehicle = Ox.CreateVehicle({\n model = 'sultanrs',\n owner = player.charid,\n}, player.getCoords(), GetEntityHeading(player.ped))"}},"/ox_core/Server/Vehicle/callbacks":{"title":"Callbacks","data":{"oxgetnearbyvehicles#ox:getNearbyVehicles":"Get all vehicles within range of the target player.\nlib.callback.await('ox:getNearbyVehicles', playerId, radius)\nplayerId: number\nradius?: number"}},"/ox_core/Server/Vehicle/methods":{"title":"Methods","data":{"":"These functions are inherited from the Vehicle class.","vehicleset#vehicle.set":"Sets the vehicle's metadata for key to the given value.\nvehicle.set(key, value)\nkey: string\nvalue: any","vehicleget#vehicle.get":"Get a value from the vehicles's metadata, or omit the argument to get all metadata.\nvehicle.get(key)\nkey?: string","vehiclegetstate#vehicle.getState":"Return the vehicle's statebag.\nvehicle.getState()","vehiclegetcoords#vehicle.getCoords":"Return the vehicle's position.\nvehicle.getCoords()","vehicledespawn#vehicle.despawn":"Despawns the vehicle but doesn't save it or update the stored value.","vehicledelete#vehicle.delete":"Remove the vehicle from the database and despawns the entity.\nvehicle.delete()","vehiclesetstored#vehicle.setStored":"Updates the vehicle's \"stored\" value and optionally despawns it.\nvehicle.setStored(value, despawn)\nvalue?: string\ndespawn?: boolean","vehiclesetowner#vehicle.setOwner":"Sets the vehicle's owner, matching a charid or nil to set it as unowned.\nvehicle.setOwner(owner)\nowner?: number","vehiclesetgroup#vehicle.setGroup":"Sets the vehicle's group, which can be used for garage restrictions, unowned group vehicles, etc.\nvehicle.setGroup(group)\ngroup?: string","vehiclesetplate#vehicle.setPlate":"Sets the vehicle's plate, used in the database to ensure uniqueness. Does not necessarily match the plate property (i.e. fake plates).\nPlate is always formatted to 8 characters.\nvehicle.setPlate(plate)\nplate: string"}},"/ox_core/Server/functions":{"title":"Functions","data":{"":"todo"}},"/ox_core/concepts":{"title":"Concepts","data":{"":"We'll try to explain some technical but core concepts used in ox_core here.","classes#Classes":"Lua doesn't have support for true classes, but rather prototype-based inheritance.\nA prototype can hold its own variables and methods, which another object (an instance) can reference or call.\n-- OxPlayer will hold all inherited variables and methods for instances of it.\nlocal OxPlayer = {}\n-- Sets the \"index metamethod\" of OxPlayer to reference itself.\n-- This is how instances will know to look up the table.\nOxPlayer.__index = OxPlayer\n-- Set a new metatable on the table passed to the function.\n-- The important code here is { __index = OxPlayer }.\nfunction OxPlayer.new(player)\n return setmetatable(player, OxPlayer)\nend\n-- Using the `:` syntax will pass the object as the first parameter.\nfunction OxPlayer:getUsername()\n return self.username\nend\n-- Create our instance of OxPlayer.\nlocal player = OxPlayer.new({\n username = 'Bob the Builder'\n})\n-- This is the same as OxPlayer.getUsername(player).\nlocal username = player:getUsername()\n-- 'Bob the Builder'\nprint(username)\nWhen using the imported classes in your resources you can treat the methods as if you are calling a regular function.\nlocal player = Ox.GetPlayer(playerId)\nprint(player.getUsername())"}},"/ox_doorlock":{"title":"Ox Doorlock","data":{"":"A door management resource that can be used standalone or alongside ox_core, qb-core, and es_extended.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","install-all-resource-dependencies#Install all resource dependencies.":"oxmysql\nox_lib","download-a-release-or-build-the-source-code#Download a release or build the source code.":"git clone https://github.com/overextended/ox_doorlock.git\ncd ox_doorlock/web\npnpm i\npnpm build","install-optional-dependencies#Install optional dependencies.":"These resources aren't required but provide additional functionality.\nox_target or qb-target","opening-the-ui#Opening the UI":"If you have installed and started the resource, you can use /doorlock to open the UI.\nIf the cursor is displayed but not the UI then you have not built it.\nYou may not be authorised to use the command.\nEnter test_ace player.1 command.doorlock in the server console (replace 1 with your server id).","convert-doors#Convert doors":"Door configuration files written for nui_doorlock (and its fork, qb-doorlock) can be automatically added to your MySQL database.\nAny files with the .lua extension placed in the ox_doorlock/convert directory will be read on resource start.\nIf the directory doesn't exist, you can create it.\nConversion cannot be guaranteed, especially if the config was not written for nui_doorlock.","adding-new-native-audio#Adding new native audio":"A guide can be found here for adding new native audio."}},"/ox_doorlock/Client/functions":{"title":"Functions","data":{"pickclosestdoor#pickClosestDoor":"Attempt to pick the lock of the closest door. Dependant on server-side checks and may fail.\nexports.ox_doorlock:pickClosestDoor()","useclosestdoor#useClosestDoor":"Interact with the closest door. Dependant on server-side checks and may fail.\nexports.ox_doorlock:useClosestDoor()"}},"/ox_doorlock/Server/events":{"title":"Events","data":{"handlers#Handlers":"These events should not be triggered by any other scripts.","ox_doorlockstatechanged#ox_doorlock:stateChanged":"Triggered when a doors state is updated.\nAddEventHandler('ox_doorlock:stateChanged', function(source, doorId, state, usedItem) end)\nsource: number or nil\ndoorId: number\nstate: boolean\nusedItem: string or false or nil"}},"/ox_doorlock/Server/functions":{"title":"Functions","data":{"":"Gets data for a door with the given id, matching the id for the database entry.","getdoor#getDoor":"exports.ox_doorlock:getDoor(doorId)\nGets data for a door with the given id, matching the id for the database entry.\nid: number\nReturn:\ndoor: table","getdoorfromname#getDoorFromName":"exports.ox_doorlock:getDoorFromName(name)\nGets data for a door with the given name, matching the name for the database entry.\nname: string\nReturn:\ndoor: table","editdoor#editDoor":"exports.ox_doorlock:editDoor(doorId, data)\nEdit configuration for the given doorId.\ndoorId: number\ndata: table","setdoorstate#setDoorState":"exports.ox_doorlock:setDoorState(doorId, state)\nSets a door with the given doorId as locked if state is true or 1.\ndoorId: number\nstate: 0 or 1 or boolean"}},"/ox_doorlock/settings":{"title":"Door Settings","data":{"general#General":"Door name\nUsed to easily identify the door.\nPasscode\nDoor can be unlocked by anybody by using the code or phrase.\nAutolock interval\nDoor will be locked after x seconds.\nInteract distance\nDoor can only be used when within x metres.\nDoor rate\nDoor movement speed for sliding/garage/automatic doors, or swinging doors when locked.\nLocked\nSets the door as locked by default.\nDouble\nDoor is a set of two doors, controlled together.\nAutomatic\nSliding/garage/automatic door.\nLockpick\nDoor can be lockpicked when interacting with a targeting resource.\nHide UI\nNo indicators (i.e. icon, text) will display on the door.\nHold Open\nHolds the door open while unlocked.","characters#Characters":"Character Id\nCharacter identifier used by a framework (i.e. player.charid, xPlayer.identifier, Player.CitizenId).","groups#Groups":"Group\nFramework dependent, referring to jobs, gangs, etc.\nGrade\nThe minimum grade to allow access for the group (0 to allow all).","items#Items":"Item\nName of the item.\nMetadata type\nRequires metadata support (i.e. ox_inventory) to check slot.metadata.type.\nRemove on use\nRemoves the item after interacting with the door.","lockpick#Lockpick":"Difficulty\nSets the skillcheck difficulty (see docs).\nArea size\nCustom difficulty area size in degrees.\nSpeed multiplier\nCustom difficulty idicator speed multipier.","sound#Sound":"Lock sound\nSound to play on door lock.\nUnlock sound\nSound to play on door unlock.\nNote: Sounds are stored in the ./web/public/sounds directory."}},"/ox_fuel":{"title":"Ox Fuel","data":{"":"A simple fuel resource meant to replace LegacyFuel or serve as a showcase for using petrol cans as an item.","installation#Installation":"","install-all-resource-dependencies#Install all resource dependencies.":"ox_lib\nox_inventory","download-a-release-or-clone-the-source-code#Download a release or clone the source code.":"git clone https://github.com/overextended/ox_fuel.git","install-optional-dependencies#Install optional dependencies.":"These resources aren't required but provide additional functionality.\nox_target"}},"/ox_fuel/Server/functions":{"title":"Functions","data":{"setpaymentmethod#setPaymentMethod":"Override the built-in payment method.\nexports.ox_fuel:setPaymentMethod(method)","parameters#Parameters":"method: function(): boolean?","example#Example":"exports.ox_fuel:setPaymentMethod(function(playerId, amount)\n local xPlayer = ESX.GetPlayerFromId(playerId)\n local bankAmount = xPlayer.getAccount('bank').money\n if bankAmount >= amount then\n xPlayer.removeAccountMoney('bank', amount)\n return true\n end\n TriggerClientEvent('ox_lib:notify', source, {\n type = 'error',\n description = locale('not_enough_money', amount - bankAmount)\n })\nend)"}},"/ox_fuel/Client/functions":{"title":"Functions","data":{"setmoneycheck#setMoneyCheck":"Override the built-in money check.\nexports.ox_fuel:setMoneyCheck(method)","parameters#Parameters":"method: function(): number","example#Example":"exports.ox_fuel:setMoneyCheck(function()\n local accounts = ESX.GetPlayerData().accounts\n for i = 1, #accounts do\n if accounts[i].name == 'bank' then\n return accounts[i].money\n end\n end\n return 0\nend)"}},"/ox_fuel/Shared":{"title":"Shared","data":{"get-vehicle-fuel-amount#Get vehicle fuel amount":"local fuel = Entity(vehicleId).state.fuel","set-vehicle-fuel-amount#Set vehicle fuel amount":"Entity(vehicleId).state.fuel = fuelAmount"}},"/ox_inventory":{"title":"Ox Inventory","data":{"":"A slot-based inventory with item metadata for \"item uniqueness\".\nIf you are replacing a built-in framework inventory there will be compatibility errors.\nIf you are unwilling or incapable of resolving incompatibilities, do not install this resource.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","install-all-resource-dependencies#Install all resource dependencies":"oxmysql\nox_lib","download-a-release-or-build-the-source-code#Download a release or build the source code.":"git clone https://github.com/overextended/ox_inventory.git\ncd ox_inventory/web\npnpm i\npnpm build","install-optional-dependencies#Install optional dependencies":"These resources aren't required but provide additional functionality.\nox_target","resource-start-order#Resource start order":"It's important for your resources to start in a logical order to prevent errors from missing dependencies.\nstart oxmysql # this should be one of the first resources\nstart ox_lib\nstart framework # the name of your framework (i.e. ox_core, es_extended, qb-core)\nstart ox_target\nstart ox_inventory","config#Config":"Resource configuration is handled using convars.\n### Shared\n# Activate specific event handlers and functions (supported: ox, esx, qb, nd)\nsetr inventory:framework \"esx\"\n# Number of slots for player inventories\nsetr inventory:slots 50\n# Maximum carry capacity for players, in grams (frameworks may override this)\nsetr inventory:weight 30000\n# Integrated support for qtarget/ox_target stashes, shops, etc\n# Note: qtarget is deprecated, a future update may drop support (ox_target only, or gated features)\nsetr inventory:target false\n# Jobs with access to police armoury, evidence lockers, etc\nsetr inventory:police [\"police\", \"sheriff\"]\n### Client\n# The URL to load item images from\nsetr inventory:imagepath \"nui://ox_inventory/web/images\"\n# Weapons will reload after reaching 0 ammo\nsetr inventory:autoreload false\n# Blur the screen while accessing the inventory\nsetr inventory:screenblur true\n# Default hotkeys to access primary and secondary inventories, and hotbar\nsetr inventory:keys [\"F2\", \"K\", \"TAB\"]\n# Enable control action when inventory is open\nsetr inventory:enablekeys [249]\n# Weapons must be aimed before shooting\nsetr inventory:aimedfiring false\n# Show a list of all nearby players when giving items\nsetr inventory:giveplayerlist false\n# Toggle weapon draw/holster animations\nsetr inventory:weaponanims true\n# Toggle item notifications (add/remove)\nsetr inventory:itemnotify true\n# Disable drop markers and spawn a prop instead\nsetr inventory:dropprops true\n# Set the default model used for drop props\nsetr inventory:dropmodel \"prop_med_bag_01b\"\n# Disarm the player if an unexpected weapon is in use (i.e. did not use the weapon item)\nsetr inventory:weaponmismatch true\n# Ignore weapon mismatch checks for the given weapon type (e.g. ['WEAPON_SHOVEL', 'WEAPON_HANDCUFFS'])\nsetr inventory:ignoreweapons []\n# Suppress weapon and ammo pickups\nsetr inventory:suppresspickups 1\n### Server\n# Compare current version to latest release on GitHub\nset inventory:versioncheck true\n# Stashes will be wiped after remaining unchanged for the given time\nset inventory:clearstashes \"6 MONTH\"\n# Discord webhook url, used for imageurl metadata content moderation (image embeds)\nset inventory:webhook \"\"\n# Logging via ox_lib (0: Disable, 1: Standard, 2: Include AddItem/RemoveItem, and all shop purchases)\nset inventory:loglevel 1\n# Item prices fluctuate in shops\nset inventory:randomprices true\n# Loot will randomly generate inside unowned vehicles and dumpsters\nset inventory:randomloot true\n# Minimum job grade to remove items from evidence lockers\nset inventory:evidencegrade 2\n# Trim whitespace from vehicle plates when checking owned vehicles\nsetr inventory:trimplate true\n# Set the contents of randomly generated inventories\n# [item name, minimum, maximum, loot chance]\nset inventory:vehicleloot [\n [\"cola\", 1, 1],\n [\"water\", 1, 1],\n [\"garbage\", 1, 2, 50],\n [\"panties\", 1, 1, 5],\n [\"money\", 1, 50],\n [\"money\", 200, 400, 5],\n [\"bandage\", 1, 1]\n]\nset inventory:dumpsterloot [\n [\"mustard\", 1, 1],\n [\"garbage\", 1, 3],\n [\"money\", 1, 10],\n [\"burger\", 1, 1]\n]\n# Set items to sync with framework accounts\nset inventory:accounts [\"money\"]","framework-incompatibilities#Framework incompatibilities":"Any frameworks with their own built-in inventory, item, or weapon systems are expected to have compatibility issues.\nMoney as an item may conflict with banking/account systems.\nYou can sync these values with server.syncInventory.\nRefer to issue #1297 for known compatibility issues.","using-an-unsupported-framework#Using an unsupported framework":"If your framework does not have official support you'll have to implement it yourself.\nIf you're replacing an existing/built-in inventory system this may be complicated, but is a fairly simple task otherwise.This setup is highly opinionated and rigid, so it's up to your own ability as a developer to make it work.","setup-a-bridge-submodule#Setup a bridge submodule":"You'll want to set the target framework first - this could be the name, an acronym, or just \"custom\".\nsetr inventory:framework \"custom\"\nCopy the ox directory from the bridge directory and give it the name you used above.The bare minimum functions and event handlers are added here, but you'll need to change them to match your framework; we can't provide any help here. You can refer to the other framework bridges if you need inspiration.","setup-database-references#Setup database references":"Take a look at the mysql module. You'll need to reference your player/vehicle tables and id columns.\nelseif shared.framework == 'custom' then\n playerTable = 'characters' -- table storing player / character data\n playerColumn = 'charid' -- primary key for identifying the character (i.e. identifier, citizenid, id)\n vehicleTable = 'vehicles' -- table storing owned vehicle data\n vehicleColumn = 'id' -- primary key for identifying the vehicle (i.e. plate, vin, id)\nend","esx#ESX":"You will need a compatible version of ESX Legacy (1.6.0 or higher).\nYou can convert player inventories with convertinventory esx.\nAll items in the database will be migrated to the internal item data.\nAlways restart the resource when items are migrated!","qbcore#QBCore":"Support for QBCore is extremely limited, highly incompatible, and unlikely to improve.\nYou can use any \"version\" of qb-core that supports QBCore.Functions.AddPlayerMethod.\nYou can convert player and vehicle inventories with convertinventory qb.\nAll QB.Shared.Items will be migrated to the internal item data.\nAlways restart the resource when items are migrated!","qbox-project#Qbox Project":"Qbox Project GitHub\nQbox txAdmin Recipe\nQbox is a fork of QBCore developed by former team members and contributors to QBCore.\nImproved security and performance of qb resources.\nIntegrated support for ox_inventory, with improved compatibility.\nSupport for ox_lib and ox_target."}},"/ox_inventory/Events/Server":{"title":"Server","data":{"":"This is not a comprehensive list of events and is missing events intended for internal use only.","handlers#Handlers":"These events should not be triggered by any other scripts.","ox_inventoryopenedinventory#ox_inventory:openedInventory":"Triggered after an inventory is opened by a player.\nAddEventHandler('ox_inventory:openedInventory', function(playerId, inventoryId) end)\nplayerId: number\ninventoryId: string","ox_inventoryclosedinventory#ox_inventory:closedInventory":"Triggered after an inventory is closed by a player.\nAddEventHandler('ox_inventory:closedInventory', function(playerId, inventoryId) end)","ox_inventoryuseditem#ox_inventory:usedItem":"AddEventHandler('ox_inventory:usedItem', function(playerId, name, slotId, metadata) end)\nplayerId: number\nname: string\nslotId: number\nmetadata?: table"}},"/ox_inventory/Events/Client":{"title":"Client","data":{"":"This is not a comprehensive list of events and is missing events intended for internal use only.","event-triggers#Event Triggers":"These events are safe to trigger and handle in other scripts.","ox_inventorydisarm#ox_inventory:disarm":"Can be triggered to force the player to disarm.\nTriggerClientEvent('ox_inventory:disarm', playerId, noAnim)\nplayerId: number\nnoAnim: boolean\nIf true, disarm animation will be skipped","event-handlers#Event Handlers":"These events should not be triggered by any other scripts.","ox_inventoryupdateinventory#ox_inventory:updateInventory":"Triggered after inventory slots have been updated, included on load.\nChanges is a table containing all updated slot data indexed by slotId. Empty slots are false.\nAddEventHandler('ox_inventory:updateInventory', function(changes) end)\nchanges: table","ox_inventorycurrentweapon#ox_inventory:currentWeapon":"Triggered when a weapon is equipped or its metadata is altered.\nAddEventHandler('ox_inventory:currentWeapon', function(weapon) end)\nweapon?: table","ox_inventoryitemcount#ox_inventory:itemCount":"Triggered when the amount of an item in the player's inventory is changed.\nNote: Not available for ESX, use esx:addInventoryItem or esx:removeInventoryItem.\nAddEventHandler('ox_inventory:itemCount', function(itemName, totalCount) end)\nitemName: string\ntotalCount: number","ox_inventoryupdateweaponcomponent#ox_inventory:updateWeaponComponent":"AddEventHandler('ox_inventory:updateWeaponComponent', function(action, componentHash, componentItem) end)\naction: 'added' | 'removed'\ncomponentHash: number\ncomponentItem: string","ox_inventoryuseditem#ox_inventory:usedItem":"AddEventHandler('ox_inventory:usedItem', function(name, slotId, metadata) end)\nname: string\nslotId: number\nmetadata?: table"}},"/ox_inventory/Frameworks/esx":{"title":"ESX","data":{"compatibility#Compatibility":"Ox Inventory is a complete replacement for existing item, inventory, and weapon systems; it is inherently incompatible with ESX and any resources that rely on default behaviour.\nLoadouts do not exist and weapons are treated as items.\nStandard shops and stashes (i.e. esx_shops, esx_weaponshop, and esx_policejob).\nResources that alter the default esx inventory or provide a ui (i.e. esx_trunkinventory, esx_inventoryhud).","installation#Installation":"Use a compatible version of ESX Legacy (1.6.0+).\nModify your server.cfg, starting ox_inventory immediately after es_extended.\nstart oxmysql\nstart ox_lib\nstart es_extended\nstart qtarget\nstart ox_inventory","convert-esx-inventory-data#Convert ESX inventory data":"Start the server and type convertinventory esx into the server console.\nOptionally, type convertinventory esxproperty into the server console.\nRestart the server once conversion is complete.","optional-optimisation#Optional Optimisation":"All item related functions from xPlayer, such as xPlayer.getInventoryItem, have been modified for compatibility purposes; however they are considered deprecated.The reasoning is fairly simple - there's now additional function references and overhead to consider. Fortunately, the new Inventory functions can be used directly and offer a great deal of improvements over the old ones.You should read through the functions section for further information, but the following should give you a decent idea.\nif xPlayer.getInventoryItem('acetone').count > 2 and xPlayer.getInventoryItem('antifreeze').count > 4 and xPlayer.getInventoryItem('sudo').count > 9 then\n xPlayer.removeInventoryItem(\"acetone\", 3)\n xPlayer.removeInventoryItem(\"antifreeze\", 5)\n xPlayer.removeInventoryItem(\"sudo\", 10)\nend\nAdd the following code somewhere in your resource to cache the exports metatable.\nlocal ox_inventory = exports.ox_inventory\nYou will be able to reference any functions exposed through the export.\nlocal items = ox_inventory:Search(source, 'count', {'acetone', 'antifreeze', 'sudo'})\nif items and items.acetone > 2 and items.antifreeze > 4 and items.sudo > 9 then\n ox_inventory:RemoveItem(source, 'acetone', 3)\n ox_inventory:RemoveItem(source, 'antifreeze', 5)\n ox_inventory:RemoveItem(source, 'sudo', 10)\nend"}},"/ox_inventory/Frameworks/qb":{"title":"QBCore","data":{"":"QBCore support is experimental and cannot work as a \"drag and drop\" solution due to many incompatibilities.","compatibility#Compatibility":"Ox Inventory provides a complete suite of tools to replace the built-in items and inventory system from QBCore, and is not intended to be used with resources designed around it.\nStashes used by qb-inventory and its forks do not work, but can possibly be converted.\nRemove qb-inventory (or similar), or qb-core will not function properly.\nRemove qb-shops and qb-weapons, as they depend on qb-inventory and conflict.\nWeapon holstering and draw animations (like in qb-smallresources) may break our own methods.","qbox-project#Qbox Project":"Qbox is a fork of QBCore being developed by a team of former contributors and developers on QBCore. The team is focused on improving performance and security, as well as converting resources to support our resources (mainly ox_lib and ox_inventory).We strongly advise using Qbox as an alternative to QBCore.\nQbox Project GitHub\nQbox Project Discord","installation#Installation":"Setup qb-core or qbox.\nEdit your server.cfg.\nAdd setr inventory:framework \"qb\" before starting your resources.\nStart ox_inventory immediately after qb-core.","convert-qbcore#Convert QBCore":"If you have existing player data, you will need to convert it to a compatible format.\nStart the server and type convertinventory qb into the server console.\nRestart the server once conversion is complete.","optional-optimisation#Optional Optimisation":"All item related functions from Player, such as Player.Functions.GetItemByName, have been modified for compatibility purposes; however they are considered deprecated.The reasoning is fairly simple - there's now additional function references and overhead to consider. Fortunately, the new Inventory functions can be used directly and offer a great deal of improvements over the old ones.You should read through the functions section for further information, but the following should give you a decent idea.\nlocal acetone = Player.Functions.GetItemByName('acetone')\nlocal antifreeze = Player.Functions.GetItemByName('antifreeze')\nlocal sudo = Player.Functions.GetItemByName('sudo')\nif acetone?.amount > 2 and antifreeze?.amount > 4 and sudo?.amount > 9 then\n Player.Functions.RemoveItem(\"acetone\", 3)\n Player.Functions.RemoveItem(\"antifreeze\", 5)\n Player.Functions.RemoveItem(\"sudo\", 10)\nend\nAdd the following code somewhere in your resource to cache the exports metatable.\nlocal ox_inventory = exports.ox_inventory\nYou will be able to reference any functions exposed through the export.\nlocal items = ox_inventory:Search(source, 'count', {'acetone', 'antifreeze', 'sudo'})\nif items and items.acetone > 2 and items.antifreeze > 4 and items.sudo > 9 then\n ox_inventory:RemoveItem(source, 'acetone', 3)\n ox_inventory:RemoveItem(source, 'antifreeze', 5)\n ox_inventory:RemoveItem(source, 'sudo', 10)\nend"}},"/ox_inventory/Functions/Client":{"title":"Client","data":{"openinventory#openInventory":"Opens an inventory using the passed data.\nexports.ox_inventory:openInventory(invType, data)\ninvType: string\n'player'\n'shop'\n'stash'\n'crafting'\n'container'\n'drop'\n'glovebox'\n'trunk'\n'dumpster'\ndata: number or string or table\nExamples\nOpen the target player's inventory.\nexports.ox_inventory:openInventory('player', 3)\nOpen the fourth \"General Store\" location.\nexports.ox_inventory:openInventory('shop', { type = 'General', id = 4 })\nOpen the first stash in data/stashes.\nexports.ox_inventory:openInventory('stash', 1)\nOpen a custom stash (created on the server with RegisterStash).\nexports.ox_inventory:openInventory('stash', 'society_police')\nOpen a stash with a specific owner.\nexports.ox_inventory:openInventory('stash', { id = 'police_locker', owner = 'license:xxxxxxxx' })","opennearbyinventory#openNearbyInventory":"If possible opens the nearby player's inventory.The player trying to open the inventory must be able to open their own and\nif the player does not have a police job, the target player must be fatally injured or\nplaying one of the death anims.\nexports.ox_inventory:openNearbyInventory()","closeinventory#closeInventory":"Closes the player's inventory.\nexports.ox_inventory:closeInventory()","items#Items":"Returns a table of all registered items. The format is as defined in data/items.lua.\nexports.ox_inventory:Items()\nThe following snippet can be used in crafting resources such as okokCrafting or core_crafting, rather than retrieving information from the server.\nlocal itemNames = {}\nfor item, data in pairs(exports.ox_inventory:Items()) do\n itemNames[item] = data.label\nend","useitem#useItem":"Uses the passed item, then triggers the callback function.\nShould be calling during item callbacks to utilise the builtin methods (server checks, progress bar, etc.).\nexports.ox_inventory:useItem(data, cb)\ndata: table\ncb?: function\nexports('bandage', function(data, slot)\n local playerPed = PlayerPedId()\n local maxHealth = GetEntityMaxHealth(playerPed)\n local health = GetEntityHealth(playerPed)\n -- Does the ped need to heal?\n if health < maxHealth then\n -- Use the bandage\n exports.ox_inventory:useItem(data, function(data)\n -- The item has been used, so trigger the effects\n if data then\n SetEntityHealth(playerPed, math.min(maxHealth, math.floor(health + maxHealth / 16)))\n lib.notify({description = 'You feel better already'})\n end\n end)\n else\n -- Don't use the item\n lib.notify({type = 'error', description = 'You don\\'t need a bandage right now'})\n end\nend)","useslot#useSlot":"Uses the item in the given inventory slot.\nexports.ox_inventory:useSlot(slot)\nslot: number","setstashtarget#setStashTarget":"Forces the secondary-inventory key to open the passed inventory. Can be useful to enable inventory access while standing inside a marker.\nexports.ox_inventory:setStashTarget(id, owner)\nid: string or number\nStash id.\nowner?: string or number\nExample\nexports.ox_inventory:setStashTarget('motel5', 'bobsmith')","getcurrentweapon#getCurrentWeapon":"Get data for the currently equipped weapon.\nexports.ox_inventory:getCurrentWeapon()\nYou can also listen for changes to the current weapon using an event handler.\nAddEventHandler('ox_inventory:currentWeapon', function(currentWeapon)\n\tCurrentWeapon = currentWeapon\nend)\ncurrentWeapon?: table\nammo?: string Name of the item used as ammo.\nhash: number\nlabel: string\nmelee: boolean\nmetadata: table\nammo?: number Amount of ammo loaded into the weapon.\ncomponents?: table Array of component item names, used to apply weapon components.\ndurability?: number\nregistered?: string Name of the player that bought the weapon at a shop.\nserial?: string\nname: string Name of the item.\nslot: number\nweight: number","displaymetadata#displayMetadata":"Sets a metadata property to display in the tooltip.\nexports.ox_inventory:displayMetadata(metadata, value)\nmetadata: string or table or { [string], [string] }\nIf metadata is a string then it's the metadata property you want to display, value is not optional then.\nCan be a table of key-value pairs, key being the metadata property and value being the label for that property.\nCan be an array of string arrays, i.e. { {'key', 'label' }, {'key2', 'label2' } to set the display order.\nvalue?: string\nLabel for the string metadata property to be displayed.\nExample\nexports.ox_inventory:displayMetadata('mustard', 'Mustard')\nexports.ox_inventory:displayMetadata({\n mustard = 'Mustard',\n ketchup = 'Ketchup'\n})","giveitemtotarget#giveItemToTarget":"Gives an item from the player's inventory to another player.\nexports.ox_inventory:giveItemToTarget(serverId, slotId, count)\nserverId: number\nThe serverId of the target player.\nslotId: number\nThe slotId of the item to give.\ncount?: number\nThe amount of the item to give, with nil, 0 or a value above the slot count giving the entire stack away.","weaponwheel#weaponWheel":"Enables the weapon wheel, but disables the use of inventory items.Mostly used for weaponised vehicles, though could be called for \"minigames\"\nlocal exports.ox_inventory:weaponWheel(state)\nstate: boolean","search#Search":"Searches the inventory for an item, or list of items, with the result varying based on the first argument.\nexports.ox_inventory:Search(search, item, metadata)\nsearch: 'slots' or 'count'\n'slots' returns a table of slots where the item was found at.\n'count' returns the count of the specified item in player's inventory. If searching for multiple items\nreturns key-value pairs of itemName = count.\nitem: table or string\nCan be a single item name or array of item names.\nmetadata?: table or string\nIf metadata is provided as a string it will search the item's metadata.type property.","count#Count":"local count = exports.ox_inventory:Search('count', 'water')\nprint('You have '..count.. ' water')\nlocal inventory = exports.ox_inventory:Search('count', {'meat', 'skin'}, {grade=\"1\"})\nif inventory then\n for name, count in pairs(inventory) do\n print('You have '..count..' '..name)\n end\nend","slots#Slots":"local water = exports.ox_inventory:Search('slots', 'water')\nlocal count = 0\nfor _, v in pairs(water) do\n print(v.slot..' contains '..v.count..' water '..json.encode(v.metadata))\n count = count + v.count\nend\nprint('You have '..count..' water')\nlocal items = exports.ox_inventory:Search('slots', {'meat', 'skin'}, 'deer')\nif items then\n for name, data in pairs(items) do\n local count = 0\n for _, v in pairs(data) do\n if v.slot then\n print(v.slot..' contains '..v.count..' '..name..' '..json.encode(v.metadata))\n count = count + v.count\n end\n end\n print('You have '..count..' '..name)\n end\nend","getitemcount#GetItemCount":"Get the total item count for all items in the player's inventory with the given name and metadata.\nexports.ox_inventory:GetItemCount(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\ncount: number","getplayeritems#GetPlayerItems":"Get all items in the player's inventory.\nexports.ox_inventory:GetPlayerItems()\nReturn:\nitems: table","getplayerweight#GetPlayerWeight":"Get the total weight of all items in the player's inventory.\nexports.ox_inventory:GetPlayerWeight()\nReturn:\ntotalWeight: number","getplayermaxweight#GetPlayerMaxWeight":"Get the maximum carry weight of the player's inventory.\nexports.ox_inventory:GetPlayerMaxWeight()\nReturn:\nmaxWeight: number","getslotidwithitem#GetSlotIdWithItem":"Get a slot id in the player's inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotIdWithItem(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotId: number?","getslotsidwithitem#GetSlotsIdWithItem":"Get all slot ids in the player's inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotIdsWithItem(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotIds: number[]?","getslotwithitem#GetSlotWithItem":"Get data for a slot in the player's inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotWithItem(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotData: table?","getslotswithitem#GetSlotsWithItem":"Get data all slots in the player's inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotsWithItem(itemName, metadata, strict)\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotsData: table[]?","statebags#Statebags":"","invbusy#invBusy":"Returns whether the player's inventory is currently running an action (i.e. using an item).\nCan be set to true to disable opening the inventory.\ninvBusy: boolean\nlocal invBusy = LocalPlayer.state.invBusy\nif invBusy then\n -- Do stuff when busy\nelse\n -- Do stuff when not busy\nend","disable-opening-inventory#Disable opening inventory":"LocalPlayer.state.invBusy = true","invhotkeys#invHotkeys":"Allows you to enable/disable a player's access to inventory hotkeys.\ninvHotkeys: boolean\nLocalPlayer.state.invHotkeys = false","invopen#invOpen":"Returns whether the player's inventory is currently open or not.\ninvOpen: boolean\nlocal invOpen = LocalPlayer.state.invOpen\nif invOpen then\n -- Do stuff when open\nelse\n -- Do stuff when closed\nend","canuseweapons#canUseWeapons":"Allows you to enable/disable the use of weapons for a player.\nLocalPlayer.state.canUseWeapons = false"}},"/ox_inventory/Functions/Server/Hooks":{"title":"Hooks","data":{"":"Event hooks allow 3rd party resources to define new behaviour without modifying the inventory code directly.","registerhook#registerHook":"exports.ox_inventory:registerHook(eventName, function(payload) end, options)\neventName: string\npayload: table\noptions?: table\nprint?: boolean\nPrint to the console when triggering the event.\nitemFilter?: { [string]: true }\nThe event will only trigger for items defined as keys in a set.\ninventoryFilter?: string[]\nThe event will only trigger for inventories that match one of the patterns in the array.\ntypeFilter?: { [string]: true }\nThe event will only trigger for inventories with one of the provided types (e.g. 'player', 'stash')\nReturn:\nhookId: number","swapitems#swapItems":"Triggered when moving any item from one slot to another, or when \"giving\" an item.\nBy returning false, you can cancel the action and revert the inventory state.\nPayload: table\nsource: number\naction: 'move' or 'stack' or 'swap' or 'give'\nfromInventory: table or string or number\ntoInventory: table or string or number\nfromType: string\ntoType: string\nfromSlot: table\ntoSlot?: table or number\ncount: number\nExampleBlacklists \"water\" from being moved into or from gloveboxes and trunks.\nlocal hookId = exports.ox_inventory:registerHook('swapItems', function(payload)\n print(json.encode(payload, { indent = true }))\n return false\nend, {\n print = true,\n itemFilter = {\n water = true,\n },\n inventoryFilter = {\n '^glove[%w]+',\n '^trunk[%w]+',\n }\n})","openinventory#openInventory":"Payload: table\nsource: number\ninventoryId: number or string\ninventoryType: string\nTriggered when a player tries to open a secondary inventory.\nBy returning false, you can cancel the action and keep the player's inventory closed.ExampleDisables gloveboxes and trunks.\nlocal hookId = exports.ox_inventory:registerHook('openInventory', function(payload)\n print(json.encode(payload, { indent = true }))\n return false\nend, {\n print = true,\n inventoryFilter = {\n '^glove[%w]+',\n '^trunk[%w]+',\n }\n})","createitem#createItem":"Payload: table\ninventoryId?: number or string\nmetadata: table\nitem: table\ncount: number\nTriggered when an item is created, either by buying it, using AddItem, or when converting inventory data.\nBy returning a table you can modify or replace the metadata given to an item.ExampleSets the label for \"water\" to \"Mineral Water\".\nlocal hookId = exports.ox_inventory:registerHook('createItem', function(payload)\n print(json.encode(payload, { indent = true }))\n local metadata = payload.metadata\n metadata.label = 'Mineral Water'\n return metadata\nend, {\n print = true,\n itemFilter = {\n water = true\n }\n})","buyitem#buyItem":"Payload: table\nsource: number\nshopType: string\nshopId: number\ntoInventory: number\ntoSlot: number\nitemName: string\nmetadata: table\ncount: number\nprice: number\ntotalPrice: number\ncurrency?: string\nTriggered when an item is about to be purchased and can return false to prevent the transaction.ExamplePrevents players from purchasing items at General stores.\nlocal hookId = exports.ox_inventory:registerHook('buyItem', function(payload)\n print(json.encode(payload, { indent = true, sort_keys = true }))\n return false\nend, {\n print = true,\n itemFilter = {\n water = true\n\t },\n})","craftitem#craftItem":"Payload: table\nsource: number\nbenchId: number\nbenchIndex: number\nrecipe: table\ncount: number\nduration: number\ningredients: table\nname: string\nslot: number\nweight: number\ntoInventory: number\ntoSlot: number\nExamplePrevent lockpicks from being crafted by players.\nlocal hookId = exports.ox_inventory:registerHook('craftItem', function(payload)\n print(json.encode(payload, { indent = true, sort_keys = true }))\n return false\nend, {\n print = true,\n\titemFilter = {\n\t\tlockpick = true\n\t},\n})","removehooks#removeHooks":"Removes a hook created by the invoking resource with the the specified id.\nIf no id is specified then all hooks registered by the resource are removed.\nexports.ox_inventory:removeHooks(id)\nid?: number"}},"/ox_inventory/Functions/Server":{"title":"Server","data":{"setplayerinventory#setPlayerInventory":"Creates and sets the player's inventory.\nexports.ox_inventory:setPlayerInventory(player, data)\nplayer: table\nsource: number\nidentifier: string\nname: string\ngroups?: table\nsex?: string\ndateofbirth?: string\ndata?: table\nIf not provided will load player's inventory data from the db.","forceopeninventory#forceOpenInventory":"Opens an inventory using the passed data.\nForces a player to open an inventory, without usual security checks (groups, coords).\nexports.ox_inventory:forceOpenInventory(playerId, invType, data)\nplayerId: number\ninvType: string\n'player'\n'stash'\n'container'\n'drop'\n'glovebox'\n'trunk'\n'dumpster'\ndata: number or string or table\nOpen the target player's inventory.\nexports.ox_inventory:forceOpenInventory(1, 'player', 3)\nAdmin command to open a player's inventory.\nRegisterCommand('openplayerinv', function(source, args)\n exports.ox_inventory:forceOpenInventory(source, 'player', tonumber(args[1]))\nend, true)\nOpen a custom stash (created on the server with RegisterStash).\nexports.ox_inventory:forceOpenInventory(1, 'stash', 'society_police')\nOpen a stash with a specific owner.\nexports.ox_inventory:forceOpenInventory(1, 'stash', { id = 'police_locker', owner = 'license:xxxxxxxx' })","updatevehicle#UpdateVehicle":"Update the internal reference to vehicle stashes, without triggering a save or updating the database.\nexports.ox_inventory:UpdateVehicle(oldPlate, newPlate)\noldPlate: string\nnewPlate: string","items#Items":"Returns a table of all registered items. The format is as defined in data/items.lua.\nexports.ox_inventory:Items()\nThe following snippet can be used in crafting resources such as okokCrafting or core_crafting, rather than querying the database.\nlocal itemNames\nESX.RegisterServerCallback('crafting:itemNames', function(source, cb)\n if not itemNames then\n itemNames = {}\n for item, data in pairs(exports.ox_inventory:Items()) do\n itemNames[item] = data.label\n end\n end\n cb(itemNames)\nend)","additem#AddItem":"Adds an item into the specified inventory.Should be used alongside CanCarryItem otherwise, the maximum weight may be exceeded.\nexports.ox_inventory:AddItem(inv, item, count, metadata, slot, cb)\ninv: table or string or number\nThe inventory's unique id, or a table with the id and owner.\nplayerId: 1\ninventoryId: gloveVGH283\n{ id = 'personallocker', owner = 'license:xxxxxx'}\nitem: string\nThe name of the item to add to the target.\ncount: number\nThe number of items to add.\nmetadata?: table or string\nA table of unique data to attach to the item object. A string will create a table with the \"type\" field.\nslot?: number\nA specific slot to add the item to. If the slot is invalid, the first available slot will be used instead.\ncb?: function(success: boolean, response?: string)\nIf used for glovebox, trunk or stash you must first check the inventory is loaded with GetInventoryReturns success, response if cb is undefined, otherwise they are used in the callback only.Possible value of the \"response\" argument, on failure:\n\"invalid_item\": the item doesn't exist\n\"invalid_inventory\": the inventory doesn't exist\n\"inventory_full\": no free slots\nExample\nlocal success, response = exports.ox_inventory:AddItem('gloveVGH283', 'bread', 4)\nif not success then\n -- if no slots are available, the value will be \"inventory_full\"\n return print(response)\nend\nprint(json.encode(response, {indent=true}))\n--[[\n {\n \"metadata\": [],\n \"label\": \"Bread\",\n \"slot\": 1,\n \"stack\": true,\n \"close\": true,\n \"name\": \"bread\",\n \"count\": 1,\n \"weight\": 150\n }\n]]","removeitem#RemoveItem":"Removes the specified item from the specified inventory.\nexports.ox_inventory:RemoveItem(inv, item, count, metadata, slot, ignoreTotal)\ninv: table or string or number\nThe inventory's unique id, or a table with the id and owner.\nplayerId: 1\ninventoryId: gloveVGH283\n{ id = 'personallocker', owner = 'license:xxxxxx'}\nitem: string\nThe name of the item to remove from the target.\ncount: number\nThe number of items to remove.\nmetadata?: table or string\nOnly remove items with matching metadata properties.\nslot?: number\nA specific slot to remove the item from. If the slot is invalid, the first available slot will be used instead.\nignoreTotal?: boolean\nRemoves as many items as possible up to count.\nReturns success: boolean, response: string?.Possible values of \"response\" on failure:\n\"invalid_item\": the item doesn't exist\n\"invalid_inventory\": the inventory doesn't exist\n\"not_enough_items\": inventory did not contain enough of the given item\nExample\n-- Removes 2 water from the glovebox for the given plate.\nlocal success = exports.ox_inventory:RemoveItem('gloveVGH283', 'water', 2)","getitem#GetItem":"Returns generic item data from the specified inventory, with the total count.\nexports.ox_inventory:GetItem(inv, item, metadata, returnsCount)\ninv: table or string or number\nitem: table or string\nCan be items array.\nmetadata?: any\nOnly returns the count of items that strictly match the given metadata.\nreturnsCount?: boolean\nIf returnsCount is set to true, the returned value will be the count based on\nhow many times the item was found.\nOtherwise returns the data related to the item and its total count found in the inventory.\nExample\nlocal item = ox_inventory:GetItem(source, 'water', nil, false)\nprint(json.encode(item, {indent=true}))\n--[[\n {\n \"consume\": 1,\n \"count\": 15,\n \"stack\": true,\n \"name\": \"water\",\n \"weight\": 500,\n \"label\": \"Water\",\n \"close\": true\n }\n]]","convertitems#ConvertItems":"Takes traditional item data and updates it to support ox_inventory.\nexports.ox_inventory:ConvertItems(playerId, items)\nplayerId: number\nitems: table\nData Conversion Example\nOld: [{\"cola\":1, \"bread\":3}]\nNew: [{\"slot\":1,\"name\":\"cola\",\"count\":1},\n{\"slot\":2,\"name\":\"bread\",\"count\":3}]","cancarryitem#CanCarryItem":"Returns true or false depending if the inventory can carry the specified item.The function checks for inventory weight and available slots.\nexports.ox_inventory:CanCarryItem(inv, item, count, metadata)\ninv: table or string or number\nitem table or string\nCan be array of items.\ncount: number\nmetadata?: table or string\nIf metadata is passed as string then metadata.type will be checked.\nExample\n-- Checks if the player calling the event can carry 3 water items\nif exports.ox_inventory:CanCarryItem(source, 'water', 3) then\n -- Do stuff if can carry\nelse\n -- Do stuff if can't carry\nend","cancarryamount#CanCarryAmount":"Returns the amount a player can hold based on available weight.\nexports.ox_inventory:CanCarryAmount(inv, item)\ninv: table or string or number\nitem: table or string\nCan be array to check multiple items.\nExample\n-- Checks how much you can carry\namountToAdd = exports.ox_inventory:CanCarryAmount(inv, 'stone')\n-- Adds the amount\nexports.ox_inventory:AddItem(inv, 'stone', amountToAdd)","cancarryweight#CanCarryWeight":"Returns if inventory can carry specified weight and free inventory weight.\nexports.ox_inventory:CanCarryWeight(inv, weight)\ninv: table or string or number\nweight: number\nExample\n-- Checks if player can carry 1000 grams.\nlocal fillAmount = 1000\nlocal canCarryWeight, freeWeight = ox_inventory:CanCarryWeight(playerId, fillAmount)\nif freeWeight == 0 then\n -- Player can't carry weight.\n return\nelseif not canCarryWeight then\n -- Modify fillAmount, because inventory can't carry specified weight\n fillAmount = freeWeight\nend\n-- Do something","setmaxweight#SetMaxWeight":"Sets the maximum weight available for an inventory.\nexports.ox_inventory:SetMaxWeight(inv, maxWeight)\ninv: table or string or number\nmaxWeight: number\nExample\nlocal ox_inventory = exports.ox_inventory\n-- Set the max weight for player 1's inventory to 20kg.\nox_inventory:SetMaxWeight(1, 20000)","canswapitem#CanSwapItem":"Returns true if the item swap is possible based on inventory weight.\nexports.ox_inventory:CanSwapItem(inv, firstItem, firstItemCount, testItem, testItemCount)\ninv: table or string or number\nfirstItem: string\nfirstItemCount: number\ntestItem: string\ntestItemCount: number","getitemcount#GetItemCount":"Get the total item count for all items in an inventory with the given name and metadata.\nexports.ox_inventory:GetItemCount(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nitemCount: number","getitemslots#GetItemSlots":"Returns the number of slots the specified item is in, the item's total count and the remaining empty slots.\nexports.ox_inventory:GetItemSlots(inv, item, metadata)\ninv: table or string or number\nitem: table or string\nmetadata?: table","getslot#GetSlot":"Returns the specified slot data as a table.\nexports.ox_inventory:GetSlot(inv, slot)\ninv: table or string or number\nslot: number\nExample\nlocal slot = exports.ox_inventory:GetSlot(source, 1)\nprint(json.encode(slot, {indent=true}))\n--[[\n {\n \"weight\": 2000,\n \"name\": \"water\",\n \"metadata\": [],\n \"slot\": 1,\n \"label\": \"Water\",\n \"close\": true,\n \"stack\": true,\n \"count: 4\n }\n]]","getslotforitem#GetSlotForItem":"Get the slot id of an existing item matching the given data, or an empty slot.\nexports.ox_inventory:GetSlotForItem(inv, itemName, metadata)\ninv: table or string or number\nitemName: string\nmetadata: table?\nReturn:\nslotId: number?","getslotidwithitem#GetSlotIdWithItem":"Get a slot id in an inventory matching the given item name and metadata.\nexports.ox_inventory:GetSlotIdWithItem(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotId: number?","getslotidswithitem#GetSlotIdsWithItem":"Get all slot ids in an inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotIdsWithItem(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotIds: number[]?","getslotwithitem#GetSlotWithItem":"Get data for a slot in an inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotWithItem(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotData: table?","getslotswithitem#GetSlotsWithItem":"Get data all slots in an inventory matching the given name and metadata.\nexports.ox_inventory:GetSlotsWithItem(inv, itemName, metadata, strict)\ninv: table or string or number\nitemName: string\nmetadata?: table\nstrict?: boolean\nStrictly match metadata properties, otherwise use partial matching.\nReturn:\nslotsData: table[]?","getemptyslot#GetEmptySlot":"Get the first available empty slot in an inventory.\nexports.ox_inventory:GetEmptySlot(inv)\ninv: table or string or number\nReturn:\nslotId: number?","getcontainerfromslot#GetContainerFromSlot":"Returns the inventory associated with the container linked in the slot of the given inventory.\nexports.ox_inventory:GetContainerFromSlot(inv, slotId)\ninv: table or string or number\nslotId: number\nReturn:\ncontainerData: table?","setslotcount#SetSlotCount":"Sets the number of slots available for an inventory.\nexports.ox_inventory:SetSlotCount(inv, slots)\ninv: table or string or number\nslots: number\nExample\nlocal ox_inventory = exports.ox_inventory\n-- Set the slot count for player 1's inventory to 10.\nox_inventory:SetSlotCount(1, 10)","getinventory#GetInventory":"Returns the inventory associated with the ID (and owner if defined). Otherwise returns null.\nexports.ox_inventory:GetInventory(inv, owner)\ninv: number or table\nowner?: string or boolean\nExample\nlocal inventory = exports.ox_inventory:GetInventory('example_stash', false)\nprint(json.encode(inventory, {indent = true}))\n--[[\n {\n \"id\": \"example_stash,\n \"label\": \"Police Stash\",\n \"type\": \"stash,\n \"slots\": 50,\n \"weight\": 0,\n \"maxWeight\": 100000,\n \"owner\": false,\n ...\n }\n]]","getinventoryitems#GetInventoryItems":"Returns all slots with items in a inventory.\nexports.ox_inventory:GetInventoryItems(inv, owner)\ninv: number or table\nowner?: string or boolean\nExample\nlocal playerItems = exports.ox_inventory:GetInventoryItems(source)","confiscateinventory#ConfiscateInventory":"Clears a player's inventory and saves it to a stash.Use ReturnInventory to return the confiscated inventory back to\nthe player.\nexports.ox_inventory:ConfiscateInventory(source)\nsource: number","returninventory#ReturnInventory":"Returns the confiscated inventory back to the player.Use it alongside ConfiscateInventory.\nexports.ox_inventory:ReturnInventory(source)\nsource: number","clearinventory#ClearInventory":"Clears the specified inventory. The keep argument is either a string or an array of strings containing the name(s) of the item(s) to keep in the inventory after clearing.\nexports.ox_inventory:ClearInventory(inv, keep)\ninv: table or string or number\nkeep?: string or string[]","search#Search":"Searches an inventory for a specified item.\nexports.ox_inventory:Search(inv, search, item, metadata)\ninv: table or string or number\nsearch: string\nitem: table or string\nmetadata?: table or string\nsearch can be either 'slots' or 'count', where slots will return a table of data\nand count will return the found amount of the specified item.","registerstash#RegisterStash":"Creates a new custom stash.\nexports.ox_inventory:RegisterStash(id, label, slots, maxWeight, owner, groups, coords)\nid: string or number\nStash identifier when loading from the database.\nlabel: string\nDisplay name when inventory is open.\nslots: number\nmaxWeight: number\nowner: string or boolean or nil\nstring: Can only access the stash linked to the owner.\ntrue: Each player has a unique stash but can request other player's stashes.\nnil: Always shared.\ngroups: table\nTable of player groups (jobs) able to access the stash.\nTable of group names where the numeric value is the minimum grade required.\n{['police'] = 0, ['ambulance'] = 2}\ncoords?: vector3 or vector3[]\nThis function needs to be triggered before a player can open the stash.\nExample\nFor a use case example on this function check out the written Guide for it.","createtemporarystash#CreateTemporaryStash":"Creates a temporary stash which will be removed after some time.\nexports.ox_inventory:CreateTemporaryStash(properties)\nproperties: table\nlabel: string\nslots: number\nmaxWeight: number\nowner?: string number or boolean\nstring: Can only access the stash linked to the owner.\ntrue: Each player has a unique stash but can request other player's stashes.\nThe inventory is always shared if false or nil.\ngroups?: table\nTable of group names (e.g. jobs) where the numeric value is the minimum grade required.\n{['police'] = 0, ['ambulance'] = 2}\ncoords?: vector3\nStash can only be accessed while nearby.\nitems?: { [number]: string, [number]: number, [number]?: table }[]\nAn array of tables, containing a sequence of itemName, count, metadata.\nReturn:\ninventoryId: string\nExample\nlocal mystash = exports.ox_inventory:CreateTemporaryStash({\n label = 'mystash',\n slots = 5,\n maxWeight = 5000,\n items = {\n { 'WEAPON_MINISMG', 1 },\n { 'ammo-9', 69 },\n { 'water', 2, { label = 'Mineral water' } }\n }\n})\nTriggerClientEvent('ox_inventory:openInventory', 1, 'stash', mystash)","customdrop#CustomDrop":"Drops can be created from other resources, containing a variety of items and utilising a custom label (instead of 'Drop 32648').\nexports.ox_inventory:CustomDrop(prefix, items, coords, slots, maxWeight, instance, model)\nprefix: string\nitems: table\nname: string\ncount: number\nmetadata?: table\ncoords: vector3\nslots?: number\nmaxWeight?: number\ninstance?: string or number\nmodel?: number\n-- Create a generic drop with a marker\nexports.ox_inventory:CustomDrop('Carcass', {\n {'meat', 5, { grade = 2, type = 'deer' }},\n {'hide', 5, { grade = 2, type = 'deer' }}\n}, coords)\n-- Create a drop with an entity\nexports.ox_inventory:CustomDrop('SMG', {\n { 'WEAPON_MINISMG', 1 },\n { 'ammo-9', 69 },\n}, GetEntityCoords(GetPlayerPed(1)), 5, 10000, nil, `w_sb_minismg`)","createdropfromplayer#CreateDropFromPlayer":"Creates a new drop with the contents of a player's inventory.\nexports.ox_inventory:CreateDropFromPlayer(playerId)\nplayerId: number\nReturn:\ndropId: string\nExample\nlocal dropId = exports.ox_inventory:CreateDropFromPlayer(1)","getcurrentweapon#GetCurrentWeapon":"Returns the player's currently equipped weapon as a table.\n-- inv: string or number\nexports.ox_inventory:GetCurrentWeapon(inv)\ninv: table or string or number","setdurability#SetDurability":"Sets durability onto the specified slot.Can be used for repairing weapons.\nexports.ox_inventory:SetDurability(inv, slot, durability)\ninv: table or string or number\nslot: number\ndurability: number\nExample\nlocal ox_inventory = exports.ox_inventory\n-- Set the durability of the item in slot 3 of source player's inventory to 100\nox_inventory:SetDurability(source, 3, 100)\n-- Set the durability of the source player's current weapon to 100\nlocal weapon = ox_inventory:GetCurrentWeapon(source)\nif weapon then\n ox_inventory:SetDurability(source, weapon.slot, 100)\nend","setmetadata#SetMetadata":"Sets metadata on the specified slot.\nox_inventory:SetMetadata(inv, slot, metadata)\ninv: table or string or number\nslot: number\nmetadata: table\nExample\nlocal ox_inventory = exports.ox_inventory\nlocal water = ox_inventory:Search(source, 1, 'water')\nfor k, v in pairs(water) do\n print('\\n______________'..'\\n- index '..k)\n print(v.name, 'slot: '..v.slot, 'metadata: '..json.encode(v.metadata))\n water = v\n break\nend\nwater.metadata.type = 'clean'\nox_inventory:SetMetadata(source, water.slot, water.metadata)\nprint(('modified %sx water in slot %s with new metadata'):format(water.count, water.slot))"}},"/ox_inventory/Guides/crafting":{"title":"Crafting","data":{"":"Crafting locations, items and their ingredients are defined in data/crafting.lua.","crafting-definition#Crafting definition":"{\n items = {\n {\n name = 'lockpick',\n ingredients = {\n garbage = 3,\n WEAPON_HAMMER = 0.1\n },\n duration = 5000,\n count = 3,\n metadata = { durability = 20 }\n },\n {\n name = 'garbage',\n ingredients = {\n cola = 1\n },\n metadata = { description = 'An empty soda can.', weight = 20, image = 'trash_can' }\n },\n },\n points = {\n vec3(-1147.083008, -2002.662109, 13.180260),\n },\n zones = {\n {\n coords = vec3(-1146.2, -2002.05, 13.2),\n size = vec3(3.8, 1.05, 0.15),\n distance = 1.5,\n rotation = 315.0,\n },\n },\n blip = { id = 566, colour = 31, scale = 0.8 },\n},\nitems: table\nname: string\ningredients: table\nItem ingredients can be seen in the item tooltip.\nKey-value pairs of item name and consume count\nkey - Item name.\nvalue - If 1 or above it's the consume count, if below 1 and above 0 it's the durability consume amount, if\nset to 0 then the item is required but not consumed.\nduration: number\nCrafting duration in milliseconds.\ncount: number or table (min, max)\nItem amount received upon crafting.\nIf set it to table it requires two number first one is minimum number and second one is maximum, it will generate a random number between those two numbers to add the crafted item to player.\nmetadata: table\nMetadata applied to the item being crafted.\npoints: vector3[]\nInteraction locations that will open the crafting inventory.\ngroups: table\nKey-value pairs of job name and minimum grade to access the crafting location.\n{[\"police\"] = 0, [\"ambulance\"] = 2}\nzones: table\nox_lib targeting zones used for ox_target.\ncoords: vector3\nsize: vector3\ndistance: number\nrotation: number\nblip: table\nid: number\nBlip sprite number.\ncolour: number\nscale: number"}},"/ox_inventory/Guides/creatingItems":{"title":"Creating Items","data":{"defining-item-data#Defining item data":"Before being able to see or use an item in game it must first be defined.All of the items are defined in the /data/items.lua file with key, value pairs.\nKey is the name (not the label) of an item and the value is a table containing the\noptions for the item.\nItem options: table\nlabel: string\nweight?: number\nstack?: boolean\nIf set to false will not allow the item to be stacked.\ndegrade?: number\nAmount of time in minutes the item will degrade after.\ndecay?: boolean\nIf true the item will be deleted when durability reaches 0 (not instant for degraded items).\nclose?: boolean\nIf set to false does not close the inventory on item use.\ndescription?: string\nItem description that will be shown in the tooltip\nconsume?: number\nItem count needed and removed use.\nDefault: 1\nIf set to a decimal will consume durability instead (0.2 = 20%).\nallowArmed?: boolean\nIf set to true will allow use of item while armed with a weapon.\nserver?: table\nexport?: string\nclient?: table\nexport?: string\nExport to be triggered after item use.\nevent?: string\nEvent to be triggered after item use.\nstatus?: table\nAdjust esx_status values after use.\nanim?: table\nAnimation that will be played during the progress bar.\ndict: string\nclip: string\nprop?: table\nAttached prop that will be displayed during the progress bar.\nmodel: string or hash\npos: table (x, y, z)\nrot: table (x, y, z)\ndisable?: table\nActions to be disabled during the progress bar.\nmove?: boolean\ncar?: boolean\ncombat?: boolean\nmouse?: boolean\nsprint?: boolean\nusetime?: number\ncancel?: boolean\nIf set to true the player canc cancel item use.\nadd?: function(total: number)\nFunction that triggers when receiving an item\nReturns total item count as total\nremove?: function(total: number)\nFunction that triggers when removing an item\nReturns total item count as total\nbuttons?: table\nlabel: string\naction: function(slot: number)\nCallback function when button is clicked in context menu, returns item slot.","examples#Examples":"['burger'] = {\n label = 'Burger',\n weight = 220,\n stack = true,\n close = true,\n client = {\n status = { hunger = 200000 },\n anim = { dict = 'mp_player_inteat@burger', clip = 'mp_player_int_eat_burger_fp' },\n prop = {\n model = 'prop_cs_burger_01',\n pos = { x = 0.02, y = 0.02, y = -0.02},\n rot = { x = 0.0, y = 0.0, y = 0.0}\n },\n usetime = 2500,\n }\n}\nA modified burger item which includes a description.\n['burger'] = {\n label = 'Burger',\n description = 'Just what is the secret formula?'\n weight = 220,\n stack = true,\n close = true,\n client = {\n status = { hunger = 200000 },\n anim = { dict = 'mp_player_inteat@burger', clip = 'mp_player_int_eat_burger_fp' },\n prop = {\n model = 'prop_cs_burger_01',\n pos = { x = 0.02, y = 0.02, y = -0.02},\n rot = { x = 0.0, y = 0.0, y = 0.0}\n },\n usetime = 2500,\n }\n}\nA modified burger item, which gives you notifications on add and remove arguments.\n['burger'] = {\n label = 'Burger',\n weight = 220,\n stack = true,\n consume = 0,\n client = {\n add = function(total)\n if total > 0 then\n lib.notify({description = 'Nice burger you got there!'})\n end\n end,\n remove = function(total)\n if total < 1 then\n lib.notify({description = 'You lost all of your burgers!'})\n end\n end\n }\n}","making-the-item-usable#Making the item usable":"If you are using ESX, you can continue using ESX.RegisterUsableItem.\nIf you are using QBCore, you can continue using QBCore.Functions.CreateUseableItem.\nUsing the built-in system is more secure and provides much more functionality.","client-callbacks#Client callbacks":"Item callbacks can be added by defining an export (recommended), or by adding it to items/client.lua.When defining item data, adding client.export will trigger an event on item use.\nThe correct formatting is export = resourceName.exportName.\nexports('bandage', function(data, slot)\n local playerPed = PlayerPedId()\n local maxHealth = GetEntityMaxHealth(playerPed)\n local health = GetEntityHealth(playerPed)\n -- Does the ped need to heal? We can cancel the item from being used.\n if health < maxHealth then\n -- Triggers internal-code to correctly use items.\n -- This adds security, removes the item on use, adds progressbar support, and is necessary for server callbacks.\n exports.ox_inventory:useItem(data, function(data)\n -- The server has verified the item can be used.\n if data then\n SetEntityHealth(playerPed, math.min(maxHealth, math.floor(health + maxHealth / 16)))\n lib.notify({description = 'You feel better already'})\n end\n end)\n else\n -- Don't use the item\n lib.notify({type = 'error', description = 'You don\\'t need a bandage right now'})\n end\nend)","server-callbacks#Server callbacks":"A callback function can be defined on the server to handle several events (usingItem, usedItem, buyItem).\nThis can either be an export (recommended), or added to the bottom of items/server.lua.\nWhen defining item data, adding server.export will trigger an event for the actions above.\nThe correct formatting is export = resourceName.exportName.\nexports('bandage', function(event, item, inventory, slot, data)\n -- Player is attempting to use the item.\n if event == 'usingItem' then\n local playerPed = GetPlayerPed(inventory.id)\n local maxHealth = GetEntityMaxHealth(playerPed)\n local health = GetEntityHealth(playerPed)\n -- Check if the player needs to be healed.\n if health >= maxHealth then\n TriggerClientEvent('ox_lib:notify', inventory.id, {type = 'error', description = 'You don\\'t need a bandage right now'})\n -- Returning 'false' will prevent the item from being used\n return false\n end\n return\n end\n -- Player has finished using the item.\n if event == 'usedItem' then\n return TriggerClientEvent('ox_lib:notify', inventory.id, {description = 'You feel better already'})\n end\n -- Player is attempting to purchase the item.\n if event == 'buying' then\n return TriggerClientEvent('ox_lib:notify', inventory.id, {type = 'success', description = 'You bought a bandage'})\n end\nend)","creating-container-items#Creating container items":"Like with other items the item must first be registered.When registered you can define the item as a container in /modules/items/containers.lua\nThe key for the container is the name you gave it when registering the item.\nYou can also define the number of slots, the maximum weight, blacklist and whitelist items.\nitemName:\nslots: number\nThe number represents the amount of slots\nmaxWeight: number\nThe number represents the maximum weight within the container\nblacklist:\nSupports single and multiple items\n{ 'testburger', 'testburger2' }\nwhitelist:\nSupports single and multiple items\n{ 'testburger', 'testburger2' }","example#Example":"['paperbag'] = {\n label = 'Paper Bag',\n weight = 1,\n stack = false,\n close = false,\n consume = 0\n},\nsetContainerProperties('paperbag', {\n\tslots = 5,\n\tmaxWeight = 1000,\n\tblacklist = { 'testburger' }\n})"}},"/ox_inventory/Guides/metadata":{"title":"Metadata","data":{"":"Item metadata is a very powerful tool that can be used to create multiple different items out of a single item.In this guide we'll use pokemon cards as an example, but you can find an already integrated example in the inventory\nwith the garbage item.","creating-the-base-item#Creating the base item":"First of all we need to create a base item that we'll use to apply metadata to.\n['pokemon_card'] = {\n label = 'Pokemon card',\n weight = 10,\n consume = 0,\n server = {\n export = 'pokemon.pokemon_card'\n }\n}\nIn this case we define the label and the weight as well since we are going to have all the cards weigh the same, but if you\ndo not want them all to weigh the same you can leave it out and apply weight through metadata.We'll also make the item usable by calling the pokemon_card export in the pokemon resource.\nexports('pokemon_card', function(event, item, inventory, slot, data)\n if event == 'usingItem' then\n local itemSlot = exports.ox_inventory:GetSlot(inventory.id, slot)\n print(json.encode(itemSlot.metadata, {indent=true}))\n end\nend)","special-metadata-properties#Special metadata properties":"You can define any metadata property with any value you want it to have, but there are a couple metadata properties that\nhave special use cases.These properties are:\nlabel: string\nDisplay name of the item\nweight: number\nAmount the item will weigh\ndescription: string\nDescription of the item that will be displayed in the tooltip\nimage: string\nImage inside the image path that the item will use\nimageurl: string\nUrl to the image that the item will use\ntype: any\nItem type that is displayed in top right of the tooltip\nWe'll use these properties to create our pokemon cards out of the pokemon_card item that we created earlier.","creating-metadata-items#Creating metadata items":"We can easily create metadata items by defining a hook using createItem and adding it to a shop as well.\ninventory = {\n {name = 'pokemon_card', price = 300, metadata = {\n label = 'Charizard',\n description = 'It is said that Charizard’s fire burns hotter if it has experienced harsh battles.',\n image = 'panties',\n type = 'Fire',\n hp = 78,\n attack = 84,\n defense = 78\n }}\n}\nlocal pokemonMetadata = {\n charizard = {\n label = 'Charizard',\n description = 'It is said that Charizard’s fire burns hotter if it has experienced harsh battles.',\n image = 'panties',\n type = 'Fire',\n hp = 78,\n attack = 84,\n defense = 78\n }\n}\nlocal hookId = exports.ox_inventory:registerHook('createItem', function(payload)\n local pokemon = pokemonMetadata[payload.metadata.type]\n if not pokemon then return end\n return pokemon\nend, {\n itemFilter = {\n pokemon_card = true\n }\n})\nAs seen above when our item is usable, the metadata properties are all there and accessible through the slot.","displaying-custom-metadata-properties#Displaying custom metadata properties":"We can display our custom metadata we set on our charizard card by either using string concatenation and adding them to\nthe description or by using the displayMetadata client function.\nexports.ox_inventory:displayMetadata({\n hp = 'HP',\n attack = 'ATK',\n defense = 'DEF'\n})"}},"/ox_inventory/Guides/stashes":{"title":"Custom Stashes","data":{"":"We can set up custom stashes from outside the resource utilising the exported RegisterStash function.Firstly, we need to define the stashes properties.","stash-properties#Stash properties":"id: string\nUnique name to identify the stash in the database.\nlabel: string\nDisplay name when viewing the stash.\nslots: number\nNumber of slots the stash will have.\nweight: number\nMaximum weight of the stash inventory.\nowner?: string or boolean\ntrue: Each player has their own unique stash, but can request to open the stash of another player\nfalse: Only a single stash exists and is shared between all players\nstring: The stash explicitly belongs to the given owner, usually a player identifier\ngroups?: table\nKey-value pairs of job name and minimum grade to be able to access the stash. ({[\"police\"] = 0, [\"ambulance\"] = 2})\nname: string\ngrade: number\ncoords?: vector3 or table\nYou can set the stash coordinates to prevent the stash from being opened if the player isn't close enough.\nVector or table containing the coordinates of the stash.","example#Example":"Below the value is hardset, but it could be loaded from the database (especially if there are unknown fields, i.e. owner)\n-- Server\nlocal stash = {\n id = '42wallabyway',\n label = '42 Wallaby Way',\n slots = 50,\n weight = 100000,\n owner = 'char1:license'\n}\nAddEventHandler('onServerResourceStart', function(resourceName)\n if resourceName == 'ox_inventory' or resourceName == GetCurrentResourceName() then\n exports.ox_inventory:RegisterStash(stash.id, stash.label, stash.slots, stash.weight, stash.owner)\n end\nend)\n-- Client\nexports.ox_inventory:openInventory('stash', {id='42wallabyway', owner=property.owner})\nThe following sample is based on esx_property's db data.\n-- Server\nlocal properties\nMySQL.query('SELECT * FROM `properties`', {}, function(result)\n properties = result\nend\nRegisterNetEvent('ox:loadStashes', function(id)\nlocal stash = properties[id]\n if stash then\n -- id: 1, name: WhispymoundDrive, label: 2677 Whispymound Drive, coords: {\"x\":118.748,\"y\":566.573,\"z\":175.697}\n ox_inventory:RegisterStash(stash.name, stash.label, 50, 100000, true, false, json.encode(stash.room_menu))\n end\nend)\n-- Client\nlocal ox_inventory = exports.ox_inventory\nif ox_inventory:openInventory('stash', property.id) == false then\n TriggerServerEvent('ox:loadStashes')\n ox_inventory:openInventory('stash', property.id)\nend","example-resource#Example Resource":"We put together an example resource showcasing how to properly utilise the stash API:"}},"/ox_inventory/issues":{"title":"Common Issues","data":{"ui-has-not-been-built#UI has not been built":"Because the UI for inventory is written in React it can't run natively under FiveM so it must first be bundled into html/css/js.We provide an easy way for you to do this by downloading a pre-bundled release, which you can get from here.\nMake sure you download the ox_inventory.zip file as that one contains the bundled files and others are raw source code.If in case you wanted to edit the inventory UI you would have to build these files yourself.\nTo do so please read our Installation guide.","no-such-export--in-resource-ox_inventory#No such export * in resource ox_inventory":"There are several likely causes for this \"issue\".\nAn error occurred while starting ox_inventory or one of its dependencies (e.g. ox_lib).\nThe resource trying to use the export (e.g. esx_addoninventory) is being started before ox_inventory.\nYou're literally trying to call an export that does not exist, which is a you issue.","stashes--trunks-are-not-saved-at-server-restart#Stashes / trunks are not saved at server restart":"Stopping a server or \"restarting\" it does not trigger any events or allow for saving.\nInventories are saved at a 5 minute interval.\ntxAdmin scheduled restarts and shutdowns will trigger a save.\nThe saveinv command can be used manually or triggered in the console.\nAll inventories are saved when the number of online players hits 0."}},"/ox_lib":{"title":"Ox Lib","data":{"":"A standalone library for providing easily reusable code as importable modules and exports.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","download-a-release-or-build-the-source-code#Download a release or build the source code.":"git clone https://github.com/overextended/ox_lib.git\ncd ox_lib/web\npnpm i\npnpm build","config#Config":"Resource configuration is handled using convars.\n# https://v6.mantine.dev/theming/colors/#default-colors\nsetr ox:primaryColor blue\nsetr ox:primaryShade 8\nYou'll also need to grant ace permissions to the resource.\nadd_ace resource.ox_lib command.add_ace allow\nadd_ace resource.ox_lib command.remove_ace allow\nadd_ace resource.ox_lib command.add_principal allow\nadd_ace resource.ox_lib command.remove_principal allow","usage#Usage":"To enable the library inside of your resource just add @ox_lib/init.lua as a shared_script in your fxmanifest.lua file.\nshared_scripts {\n '@ox_lib/init.lua',\n}\nOr if the library is the only shared script you use you can do:\nshared_script '@ox_lib/init.lua'\nYou can specify modules to import from inside your fxmanifest.lua, or load them dynamically.\nox_libs {\n 'locale',\n 'math',\n 'table',\n}\nWhen ox_lib has been imported into your script, it will make several new globals available:\nlib for dynamically importing ox_lib modules into your script.\nrequire for importing modules from your own script.\ncache see here.\nNpm package for the lib does not support all the functions that are available for Lua.All supported functions are located inside the resource folder in the lib.\nYou can get the npm package here.Usage:\nYou can either import the whole library object which contains all the functions for that scope (client/server/shared) or you can deconstruct it and import the functions you find needed at the time.\nimport lib from '@overextended/ox_lib/server';\nimport { versionCheck } from '@overextended/ox_lib/server';\nYou can now use the library functions inside of your resource, check the rest of the documentation to see how to utilise them.","using-icons-for-interface-functions#Using icons for interface functions":"The icon library used is Font Awesome 6.0, if for the icon you define only a string the default icon type will be solid.\nIf you want to use a different icon type, i.e apple as a brand, you need to define icon as a table (array) with the first value being the icon type (fas, far, fab) as a string, and the second being the icon name.\nicon = {'fab', 'apple'}\nicon: ['fab', 'apple'];","building-the-ui#Building the UI":"If you wish to edit any of the UI elements you will need to download the source code, edit what you need and then compile it.\nDO NOT de-bundle and un-minify the release CSS and JS files to edit them.\nRequirements:\nNode.js (LTS)\npnpm\nInstalling Node.js:\nDownload the LTS version of Node.js.\nGo through the install and make sure you install all of the features.\nRun node --version in cmd and make sure that it gives you the version number. If it doesn't then you didn't install it correctly.\nInstalling pnpm:\nAfter installing NodeJS you can install pnpm by running npm install -g pnpm.\nBuilding the UI:\ncd into the web directory.\nrun pnpm i to install the dependencies.\nrun pnpm build to build the source files.\nWhen working in the browser you can run pnpm start, which supports hot reloads meaning that\nyou will see your changes after saving your file.If you want to work in game you can run pnpm start:game which writes changes to disk, so\nthe only thing you have to do is restart the resource for it take affect."}},"/ox_lib/Modules/ACL/Server":{"title":"Server","data":{"":"Wrapper around the built-in ACL system. Handles lib.addCommand and ox_groups permissions.\nRefer to Basic Aces & Principals overview/guide for more information.","libaddace#lib.addAce":"Assigns the ace permission to a principal. Third parameter defaults to 'allow', while passing false sets the permission to 'deny'.\nlib.addAce(principal, ace, allow)\nlib.addAce('group.admin', 'command.say')\nimport lib from '@overextended/ox_lib/server'\nlib.addAce(principal, ace, allow)\nlib.addAce('group.admin', 'command.say')\nprincipal: string\nace: string\nallow: boolean","libremoveace#lib.removeAce":"Removes the ace permission from a principal. Third parameter defaults to 'allow', while passing false sets the permission to 'deny'.\nlib.removeAce(principal, ace, allow)\nlib.removeAce('group.admin', 'command.say')\nimport lib from '@overextended/ox_lib/server'\nlib.removeAce(principal, ace, allow)\nlib.removeAce('group.admin', 'command.say')\nprincipal: string\nace: string\nallow: boolean","libaddprincipal#lib.addPrincipal":"Assigns a principal to a parent principal. Children inherit permissions from the parent.\nlib.addPrincipal(child, parent)\nlib.addPrincipal('player.1', 'group.moderator')\nimport lib from '@overextended/ox_lib/server'\nlib.addPrincipal(child, parent)\nlib.addPrincipal('player.1', 'group.moderator')\nchild: string\nparent: string","libremoveprincipal#lib.removePrincipal":"Removes a principal from a parent principal.\nlib.removePrincipal(child, parent)\nlib.removePrincipal('player.1', 'group.moderator')\nimport lib from '@overextended/ox_lib/server'\nlib.removePrincipal(child, parent)\nlib.removePrincipal('player.1', 'group.moderator')\nchild: string\nparent: string"}},"/ox_lib/Modules/AddCommand/Server":{"title":"Server","data":{"":"Registers commands and simplifies argument validation, permissions, and chat suggestions.\nlib.addCommand(commandName, properties, cb)\ncommandName: string or string[]\nproperties: table or false\nhelp?: string\nrestricted?: boolean or string or string[]\nparams?: table[]\nname: string\nhelp?: string\ntype?: 'number' or 'playerId' or 'string'\noptional?: boolean\nlib.addCommand('giveitem', {\n help = 'Gives an item to a player',\n params = {\n {\n name = 'target',\n type = 'playerId',\n help = 'Target player\\'s server id',\n },\n {\n name = 'item',\n type = 'string',\n help = 'Name of the item to give',\n },\n {\n name = 'count',\n type = 'number',\n help = 'Amount of the item to give, or blank to give 1',\n optional = true,\n },\n {\n name = 'metatype',\n help = 'Sets the item\\'s \"metadata.type\"',\n optional = true,\n },\n },\n restricted = 'group.admin'\n}, function(source, args, raw)\n local item = Items(args.item)\n if item then\n Inventory.AddItem(args.target, item.name, args.count or 1, args.metatype)\n end\nend)"}},"/ox_lib/Modules/AddKeybind/Client":{"title":"Client","data":{"":"Registers keybinds and simplifies interactions of the keybinds.","ckeybind-class#CKeybind Class":"A table representing a keybind with the following properties.\nname: string\ndescription: string\ncurrentKey: string\nKey that the current user has this keybind set to\ndisabled: boolean\nWhether or not the keybind is currently disabled\nhash: number\nInternal hash of the keybind that is used to reference it within the game itself\ndefaultKey?: string\nDefault key to set the keybind to for new players\nNOTE: Changing this will not change the key for existing players\ndefaultMapper?: string\nSee Input Mapper Ids for more information\nsecondaryKey?: string\nAn optional secondary keybind.\nsecondaryMapper?: string\nAn optional mapper for the secondary key, otherwise using the default mapper.\ndisable: function(self: CKeybind, disable: boolean)\nBuilt-in function to enable / disable a keybind\nonPressed?: function(self: CKeybind)\nUser-defined function triggered on keybind press\nonReleased?: function(self: CKeybind)\nUser-defined function triggered on keybind release","libaddkeybind#lib.addKeybind":"lib.addKeybind(data)\ndata: table\nname: string\ndescription: string\ndefaultKey?: string\nDefault: None\ndefaultMapper?: string\nDefault: keyboard\nsecondaryKey?: string\nsecondaryMapper?: string\ndisabled?: boolean\nWhether or not the keybind should be disabled by default\nonPressed?: function(self: CKeybind)\nFunction triggered on keybind press\nonReleased?: function(self: CKeybind)\nFunction triggered on keybind release\nlocal keybind = lib.addKeybind({\n name = 'respects',\n description = 'press F to pay respects',\n defaultKey = 'F',\n onPressed = function(self)\n print(('pressed %s (%s)'):format(self.currentKey, self.name))\n end,\n onReleased = function(self)\n print(('released %s (%s)'):format(self.currentKey, self.name))\n end\n})","enable--disable-keybinds#Enable / Disable Keybinds":"Keybinds can be enabled / disabled by using the disable method.\nkeybind:disable(true) -- disables the keybind\nkeybind:disable(false) -- enables the keybind"}},"/ox_lib/Modules/Cache/Client":{"title":"Client","data":{"":"Values and cache functionality available to the client, in addition to the shared values.","default-values#Default values":"ped: number\nplayer entity id\nplayerId: number\nplayer id\nserverId: number\nplayer server id\nweapon: number or false\ncurrent weapon hash\nvehicle: number or false\nvehicle entity id\nseat: number or false\nvehicle seat index\ncoords: vector3\ncurrent player coords\nonly populated if using zones or points\ncannot be listened for with lib.onCache\nmount: number or false (RedM only)\nmount entity id","liboncache#lib.onCache":"Register an event handler that is triggered when the cached value is updated.\nlib.onCache(key, function(value) end)\nkey: string\nped\nvehicle\nseat\nweapon\nmount (RedM only)\nvalue: any\nlib.onCache('vehicle', function(value)\n print('old vehicle:', cache.vehicle)\n print('new vehicle:', value)\nend)\nimport { onCache } from '@overextended/ox_lib/client';\nonCache(key, (value) => {});\nkey: string\nped\nvehicle\nseat\nweapon\nmount (RedM only)\nvalue: any\nimport { cache, onCache } from '@overextended/ox_lib/client';\nlib.onCache('vehicle', (value) => {\n console.log('old vehicle:', cache.vehicle);\n console.log('new vehicle:', value);\n});"}},"/ox_lib/Modules/Cache/Shared":{"title":"Shared","data":{"":"A table containing cached function results, which may be constants or infrequently changed.","default-values#Default values":"resource: string\nthe value returned by GetCurrentResourceName.\ngame: 'fxserver' | 'fivem' | 'redm'\nthe value returned by GetGameName.","adding-new-cached-values#Adding new cached values":"Values can be cached permanently, or added with a timeout.\ncache(key, func, timeout)\nkey: string\na unique name to store and access the cached state.\nfunc: function\na function to call when the cache is invalidated/empty.\ntimeout?: number\na timer in milliseconds to clear the cached state.\nlocal i = 0\nwhile true do\n Wait(1000)\n i += 1\n print(cache('test', function() return i end, 5000))\nend\n-- output:\n> 1\n> 1\n> 1\n> 1\n> 1\n> 6\n> 6\n> 6"}},"/ox_lib/Modules/Callback/JavaScript/Client":{"title":"Client","data":{"trigger-server-callback#Trigger Server Callback":"","triggerservercallback#triggerServerCallback":"triggerServerCallback(eventName, delay, ...args)\neventName: string\ndelay: number or null\nAmount of time until this callback can be triggered again\n..args: any","register-client-callback#Register Client Callback":"","onservercallback#onServerCallback":"onServerCallback(eventName, cb)\neventName: string\ncb: function(...args: any)","usage-example#Usage Example":"For this example to fully make sense take a look at the example on the server page for the callbacks.\nimport { onServerCallback, triggerServerCallback } from '@overextended/ox_lib/client'\nonServerCallback('test:client', (...args: [number, number, string]) => {\n console.log(args);\n return {\n clientValue: 'Value from the client',\n };\n});\nsetTimeout(async () => {\n const args = [1, null, 3, null, null, 6];\n const response = await triggerServerCallback<{ serverValue: number }>('test:server', 1, args);\n if (!response) return;\n console.log('Response from server', response);\n}, 100);"}},"/ox_lib/Modules/Callback/JavaScript/Server":{"title":"Server","data":{"trigger-client-callback#Trigger Client Callback":"","triggerclientcallback#triggerClientCallback":"triggerClientCallback(eventName, playerId, ...args)\neventName: string\nplayerId: number\n...args: any","register-server-callback#Register Server Callback":"","onclientcallback#onClientCallback":"onClientCallback(eventName, cb)\neventName: string\ncb: function(playerId: number, ...args: any)","usage-example#Usage Example":"For this example to fully make sense take a look at the example on the client page for the callbacks.\nimport { onClientCallback, triggerClientCallback } from '@overextended/ox_lib/server';\nonClientCallback('test:server', (playerId, ...args: [number, null, number, null, null, number]) => {\n console.log('onClientCallback', playerId, ...args);\n return {\n serverValue: 3000,\n };\n});\nsetTimeout(async () => {\n const response = await triggerClientCallback<{ clientValue: string }>('test:client', 1, [1, null, 3, null, null, 6])\n if (!response) return;\n console.log(response.clientValue);\n console.log('Response from client', response);\n}, 100);"}},"/ox_lib/Modules/Callback/Lua/Client":{"title":"Client","data":{"trigger-server-callback#Trigger Server Callback":"","libcallback#lib.callback":"The response is handled in a separate coroutine.\nlib.callback(name, delay, cb, ...)\nname: string\ndelay: number or false\nAmount of time until this callback can be triggered again\ncb: function\n...: any\nlib.callback('ox_inventory:getItemCount', false, function(count)\n print(count)\nend, 'water', {type = 'fresh'})","libcallbackawait#lib.callback.await":"The current coroutine is yielded until a response is received.\nlib.callback.await(name, delay, ...)\nname: string\ndelay: number or false\nAmount of time until this callback can be triggered again\n...: any\nlocal count = lib.callback.await('ox_inventory:getItemCount', false, 'water', {type = 'fresh'})\nprint(count)","register-client-callback#Register Client Callback":"","libcallbackregister#lib.callback.register":"Register an event handler for responding to server requests.\nlib.callback.register(name, cb)\nname: string\ncb: function\nlib.callback.register('ox:getNearbyVehicles', function(radius)\n local nearbyVehicles = lib.getNearbyVehicles(GetEntityCoords(cache.ped), radius, true)\n return nearbyVehicles\nend)"}},"/ox_lib/Modules/Callback/Lua/Server":{"title":"Server","data":{"trigger-client-callback#Trigger Client Callback":"","libcallback#lib.callback":"The response is handled in a separate coroutine.\nlib.callback(name, playerId, cb, ...)\nname: string\nplayerId: number\ncb: function\n...: any\nlib.callback('ox:getNearbyVehicles', source, function(vehicles)\n for i = 1, #vehicles do\n DeleteEntity(entity)\n end\nend, args.radius)","libcallbackawait#lib.callback.await":"The current coroutine is yielded until a response is received.\nlib.callback.await(name, playerId, ...)\nname: string\nplayerId: number\n...: any\nlocal vehicles = lib.callback.await('ox:getNearbyVehicles', source, args.radius)\nfor i = 1, #vehicles do\n DeleteEntity(entity)\nend","register-server-callback#Register Server Callback":"","libcallbackregister#lib.callback.register":"Register an event handler for responding to client requests.\nlib.callback.register(name, cb)\nname: string\ncb: function\nlib.callback.register('ox_inventory:getItemCount', function(source, item, metadata, target)\n local inventory = target and Inventory(target) or Inventory(source)\n return (inventory and Inventory.GetItem(inventory, item, metadata, true)) or 0\nend)"}},"/ox_lib/Modules/Class/Shared":{"title":"Shared","data":{"libclass#lib.class":"Creates a new class.\nlocal MyClass = lib.class(name, super)\nname: string\nsuper?: table\nSets the new class as a subset of the super class, inheriting its methods and fields.\nReturn:\nclass: table\ntodo: more class info blah, look at the example","example#Example":"local fruits = {}\nlocal Fruit = lib.class('Fruit')\nfunction Fruit:init()\n print(('Created a %s %s'):format(self:getColour(), self:getName()))\n fruits[self.name] = self\nend\nfunction Fruit:remove()\n print('Removed', self:getName(), self)\n fruits[self.name] = nil\nend\nfunction Fruit:getName() return self.name end\nfunction Fruit:getColour() return self.colour end\nfunction Fruit:getSeeds() return self.private.seeds end\n-- Inherits methods and properties from the Fruit class.\nlocal SpoiledFruit = lib.class('SpoiledFruit', Fruit)\nfunction SpoiledFruit:getStench() return self.stench end\nCreateThread(function()\n local apple = Fruit:new({\n name = 'apple',\n colour = math.random(0, 1) == 1 and 'red' or 'green'\n })\n local orange = Fruit:new({\n name = 'orange',\n colour = 'orange',\n -- the private table is not serialisable (data is hidden cross-resource)\n private = {\n seeds = 7\n }\n })\n print(('the apple is %s; the orange contains %d seeds'):format(apple:getColour(), orange:getSeeds()))\n apple:remove()\n local rottenBanana = SpoiledFruit:new({\n name = 'banana',\n colour = 'black',\n stench = 'musty'\n })\n print(('the banana is %s and %s - gross!'):format(rottenBanana:getColour(), rottenBanana:getStench()))\nend)"}},"/ox_lib/Modules/Cron/Server":{"title":"Server","data":{"":"A Lua implementation of cron, allowing tasks to be scheduled to run periodically at fixed times, dates, and intervals.","cron-expression#Cron expression":"A string containing five values separated by white spaces, representing a set of times to execute a task.\nField\tValid values\tMinutes\t0-59\tHours\t0-23\tDay of month\t1-31\tMonth\t1-12 or jan-dec\tDay of week\t1-7 or sun-sat\t\nNote: Day of the week is set to match os.date and starts at 1, unlike the cron-standard which starts at 0.","-wildcards#* Wildcards":"Represents all values, e.g. * * * * * will run every minute, or * * * * 1 will run every minute on Sunday.","-lists#, Lists":"Commas can be used to create a list of values, e.g. * * * * sun,mon,tue will run every minute on Sunday, Monday, and Tuesday.","--ranges#- Ranges":"Dashes define a range of values, e.g. 10-30 * * * * will start running the task at the 10th minute, and every minute until the 30th minute.","-steps#/ Steps":"Slashes can be used for step values, e.g. * */4 * * * will run every 4 hours and is shorthand for * 0,4,8,12,16,20 * * *.","functions#Functions":"","libcronnew#lib.cron.new":"Creates a new cronjob, scheduling a task to run at fixed times or intervals.\nlib.cron.new(expression, job, options)\nexpression: string\nA cron expression such as * * * * * representing minute, hour, day, month, and day of the week\njob: fun(task: OxTask, date: osdate)\noptions?: table\ndebug?: boolean\nReturn:\ntask: OxTask"}},"/ox_lib/Modules/DisableControls/Client":{"title":"Client","data":{"":"A centralized way to track and disable controls.","libdisablecontrols#lib.disableControls":"Call on frame to disable all stored controls.\nlib.disableControls()","libdisablecontrolsadd#lib.disableControls:Add":"Adds the specified control(s) to the stored list.\nIf the control is already being tracked, the stored counter will be incremented.\nlib.disableControls:Add(...)\nvararg: number or table\nControl(s) to add a stored count of","libdisablecontrolsremove#lib.disableControls:Remove":"Removes the specified control(s) from the stored list.\nIf the stored counter for a given control is greater than one, the stored counter will be decremented.\nlib.disableControls:Remove(...)\nvararg: number or table\nControl(s) to remove a stored count of","libdisablecontrolsclear#lib.disableControls:Clear":"Clears the stored counter(s) for the specified control(s).\nlib.disableControls:Clear(...)\nvararg: number or table\nControl(s) to clear out from being tracked"}},"/ox_lib/Modules/GetClosestObject/Shared":{"title":"Shared","data":{"libgetclosestobject#lib.getClosestObject":"Get the object handle and coords of the closest object to a set of coordinates.\nlib.getClosestObject(coords, maxDistance)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nReturn:\nobject?: number\ncoords?: vector3"}},"/ox_lib/Modules/GetClosestPed/Shared":{"title":"Shared","data":{"libgetclosestped#lib.getClosestPed":"Get the ped handle and coords of the closest ped to a set of coordinates.\nlib.getClosestPed(coords, maxDistance)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nReturn:\nped?: number\ncoords?: vector3"}},"/ox_lib/Modules/GetClosestVehicle/Shared":{"title":"Shared","data":{"libgetclosestvehicle#lib.getClosestVehicle":"Get the vehicle handle and coords of the closest vehicle to a set of coordinates.\nlib.getClosestVehicle(coords, maxDistance, includePlayerVehicle)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nincludePlayerVehicle?: boolean\nWhether or not to include the player's current vehicle. Ignored on the server.\nDefault: false\nReturn:\nvehicle?: number\nvehicleCoords?: vector3"}},"/ox_lib/Modules/GetClosestPlayer/Shared":{"title":"Shared","data":{"libgetclosestplayer#lib.getClosestPlayer":"Get the player id, ped handle, and coords of the closest player to a set of coordinates.\nlib.getClosestPlayer(coords, maxDistance, includePlayer)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nincludePlayer?: boolean\nWhether or not to include the current player. Ignored on the server.\nDefault: false\nReturn:\nplayerId?: number\nplayerPed?: number\nplayerCoords?: vector3"}},"/ox_lib/Modules/GetNearbyPeds/Shared":{"title":"Shared","data":{"libgetnearbypeds#lib.getNearbyPeds":"Get the ped handle and coords of all peds within range of a set of coordinates.\nlib.getNearbyPeds(coords, maxDistance)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nReturn:\npeds: { ped: number, coords: vector3 }[]"}},"/ox_lib/Modules/GetNearbyObjects/Shared":{"title":"Shared","data":{"libgetnearbyobjects#lib.getNearbyObjects":"Get the object handle and coords of all objects within range of a set of coordinates.\nlib.getNearbyObjects(coords, maxDistance)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nReturn:\nobjects: { object: number, coords: vector3 }[]"}},"/ox_lib/Modules/GetNearbyPlayers/Shared":{"title":"Shared","data":{"libgetnearbyplayers#lib.getNearbyPlayers":"Get the player id, ped handle, and coords of all players within range of a set of coordinates.\nlib.getNearbyPlayers(coords, maxDistance, includePlayer)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nincludePlayer?: boolean\nWhether or not to include the current player. Ignored on the server.\nDefault: false\nReturn:\nplayers: { id: number, ped: number, coords: vector3 }[]"}},"/ox_lib/Modules/GetNearbyVehicles/Shared":{"title":"Shared","data":{"libgetnearbyvehicles#lib.getNearbyVehicles":"Get the vehicle handle and coords of all vehicles within range of a set of coordinates.\nlib.getNearbyVehicles(coords, maxDistance, includePlayerVehicle)\ncoords: vector3\nThe coords to check from.\nmaxDistance?: number\nThe max distance to check.\nDefault: 2.0\nincludePlayerVehicle?: boolean\nWhether or not to include the player's current vehicle. Ignored on the server.\nDefault: false\nReturn:\nvehicles: { vehicle: number, coords: vector3 }[]"}},"/ox_lib/Modules/Interface/Client/alert":{"title":"Alert Dialog","data":{"":"Simple alert dialog that can display a message to the player.\nReturns whether the player pressed the confirm button or canceled the dialog.","libalertdialog#lib.alertDialog":"lib.alertDialog(data)\nTriggerClientEvent('ox_lib:alertDialog', source, data)\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nimport lib from '@overextended/ox_lib/client';\nlib.alertDialog(data);\ndata: table (object)\nheader: string\nDialog title.\ncontent: string\nDialog body content, supports markdown.\ncentered?: boolean\nCenters the dialog vertically and horizontally.\ncancel?: boolean\nDisplays a cancel button (ESC is still available if this is not defined).\nsize?: 'xs' or 'sm' or 'md' or 'lg' or 'xl'\noverflow?: boolean\nlabels?: table\nAllows you to define the displayed labels for cancel and/or confirm buttons.\ncancel?: string\nconfirm?: string\nReturns 'confirm' if the player pressed the confirm button, otherwise if the player pressed the cancel button\nor has exited the dialog with ESC the return will be 'cancel'.","libclosealertdialog#lib.closeAlertDialog":"Force closes the active alert dialog and sets its return data as nil\nlib.closeAlertDialog()\nimport lib from '@overextended/ox_lib/client';\nlib.closeAlertDialog();","example#Example":"local alert = lib.alertDialog({\n header = 'Hello there',\n content = 'General Kenobi \\n Markdown support!',\n centered = true,\n cancel = true\n})\nprint(alert)\nimport lib from '@overextended/ox_lib/client';\nconst alert = await lib.alertDialog({\n header: 'Hello there',\n content: 'General Kenobi \\n Markdown support!',\n centered: true,\n cancel: true,\n});\nconsole.log(alert);"}},"/ox_lib/Modules/Interface":{"title":"Interface","data":{"":"If you wish to change the primary colour for the UI to better match your server's theme you can do so easily through the available convars.They don't require you to build the UI, just restart the resource.Convars:\nsetr ox:primaryColor blue\nsetr ox:primaryShade 8\nChanging the primary colour will change the colour in elements such as the progress bar/circle, skill check, radial menu center button and hover,\ndialog confirm buttons, input field focus, and more.You can find the full list of preset colours and shades here:https://v6.mantine.dev/theming/colors/#default-colorsIf you wish to create your own pallete I suggest following the guide on that page.\nKeep in mind doing so will require you to download the source code and build the UI."}},"/ox_lib/Modules/Interface/Client/clipboard":{"title":"Clipboard","data":{"libsetclipboard#lib.setClipboard":"Sets the player's clipboard to the specified string value.\nWill not work if focus is already taken by some NUI component.\nTo create a new line use \\t\\n not just \\n in your string.\nlib.setClipboard(value)\nimport lib from '@overextended/ox_lib/client';\nlib.setClipboard(value);\nvalue: string"}},"/ox_lib/Modules/Interface/Client/input":{"title":"Input Dialog","data":{"":"The input dialog window allows you to take data from the user by setting input fields.","libinputdialog#lib.inputDialog":"lib.inputDialog(heading, rows, options)\nimport lib from '@overextended/ox_lib/client';\nlib.inputDialog(heading, rows, options);\nheading: string\nrows: string[] or table (array)\ntype: 'input' or 'number' or 'checkbox' or 'select' or 'slider' or 'color' or 'multi-select' or 'date' or 'date-range' or 'time' or 'textarea'\noptions?: table(object)\nallowCancel: boolean\nIf false the user will not be able to cancel and close the input dialog until submitted.\nIf not defined, the user is able to cancel and close the input dialog.","field-type-properties#Field Type Properties":"input\nlabel: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string\npassword?: boolean\nmin?: number\nmax?: number\nnumber\nlabel: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: number\nmin?: number\nmax?: number\nprecision?: number\nstep?: number\ncheckbox\nlabel: string\nchecked?: boolean\ndisabled?: boolean\nrequired?: boolean\nselect and multi-select\nlabel: string\noptions: table(array)\nvalue: string\nlabel?: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string | table (only for multi-select)\nvalue of the default option.\nclearable?: boolean\nslider\nlabel: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: number\nmin?: number\nmax?: number\nstep?: number\ncolor\nlabel: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string\nformat?: 'hex' | 'hexa' | 'rgb' | 'rgba' | 'hsl' | 'hsla';\ndate\nlabel: string\ndescription?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string or true\nTrue defaults to current date\nformat?: string\nDate format to display in the field\nreturnString?: boolean\nReturns the date as a string, default format is DD/MM/YYYY, but if format is defined it will use that.\nclearable?: boolean\nmin?: string\n\"01/01/2000\"\nmax?: string\n\"12/12/2023\"\ndate-range\nlabel: string\ndescription?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: [string, string]\nformat?: string\nDate format to display in the field\nreturnString?: boolean\nReturns the date as a string, default format is DD/MM/YYYY, but if format is defined it will use that.\nclearable?: boolean\ntime\nlabel: string\ndescription?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: string\nformat?: '12' or '24'\nclearable?: boolean\ntextarea\nlabel: string\ndescription?: string\nplaceholder?: string\nicon?: string\nrequired? boolean\ndisabled?: boolean\ndefault?: number\nmin?: number\nMinimum amount of rows the text area will take.\nmax?: number\nMaxmimum amount of rows the text area will take, when exceeded goes into overflow.\nautosize?: boolean\nIf true text area will grow with content until max rows are reached.\nThe callback data is promise based meaning that the thread will not continue executing until the user either sends the data or exits the popup.The data returned will be a table (array), indexes represent the rows sent to the dialog, so if we want data from the first field that would be index 1 (0), if we want data from the third field, that would be index 3 (2), etc...\nField types such as date, date-range and time return a unix timestamp on the set value.","libcloseinputdialog#lib.closeInputDialog":"Force closes the active input dialog and sets its return data as nil.\nlib.closeInputDialog()\nimport lib from '@overextended/ox_lib/client';\nlib.closeInputDialog();","usage-example#Usage Example":"","basic#Basic":"local input = lib.inputDialog('Basic dialog', {'First row', 'Second row'})\nif not input then return end\nprint(json.encode(input), input[1], input[2])\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nconst input = await lib.inputDialog('Basic dialog', ['First row', 'Second row']);\nif (!input) return;\nconsole.log(input, input[0], input[1]);","advanced#Advanced":"local input = lib.inputDialog('Dialog title', {\n {type = 'input', label = 'Text input', description = 'Some input description', required = true, min = 4, max = 16},\n {type = 'number', label = 'Number input', description = 'Some number description', icon = 'hashtag'},\n {type = 'checkbox', label = 'Simple checkbox'},\n {type = 'color', label = 'Colour input', default = '#eb4034'},\n {type = 'date', label = 'Date input', icon = {'far', 'calendar'}, default = true, format = \"DD/MM/YYYY\"}\n})\nprint(json.encode(input))\n-- Getting rgb values from colour picker\nlocal rgb = lib.math.torgba(input[4])\n-- Transforming date timestamp to a readable format with Lua's os library (server-only)\nlocal timestamp = math.floor(input[5] / 1000)\nlocal date = os.date('%Y-%m-%d %H:%M:%S', timestamp)\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nconst input = await lib.inputDialog('Police locker', [\n { type: 'input', label: 'Text input', description: 'Some input description', required: true, min: 3, max: 16 },\n { type: 'number', label: 'Number input', description: 'Some number description', icon: 'hashtag' },\n { type: 'checkbox', label: 'Simple checkbox' },\n { type: 'color', label: 'Colour input', default: '#eb4034' },\n { type: 'date', label: 'Date input', icon: ['far', 'calendar'], default: true, format: 'DD/MM/YYYY' },\n]);\nconsole.log(JSON.stringify(input, null, 2));\n// Getting r, g and b values from colour picker\nconst regExp = /rgb\\((\\d+),\\s*(\\d+),\\s*(\\d+)\\)/;\nconst colourInput = input[3];\nconst color = regExp.exec(colourInput);\nif (!color) return;\nconsole.log(+color[1], +color[2], +color[3]);"}},"/ox_lib/Modules/Interface/Client/context":{"title":"Context Menu","data":{"libregistercontext#lib.registerContext":"Used for registering a context menu.\nlib.registerContext(context)\nimport lib from '@overextended/ox_lib/client';\nlib.registerContext(context);\nid: string\nUnique menu identifier, will be used to open the menu.\ntitle: string\nTitle display in the menu; has markdown support.\nmenu?: string\nMenu identifier - if defined there will be a back arrow next to the menu title that will take you to the menu you defined.\ncanClose: boolean\nIf set to false the user won't be able to exit the menu without pressing one of the buttons.\nonExit?: function\nFunction that will be ran when the user closes their context menu with ESC.\nonBack?: function\nFunction that will be ran when the user presses the back button to return to a previous menu.\noptions: table (object or array)\nitem: key (string) or table (object)\ntitle?: string\nIf not using keys then sets the title for the button; has markdown support.\ndisabled?: boolean\nGrays out the button and makes it unclickable.\nreadOnly? boolean\nRemoves all hover and active styles and disables onSelect if it's defined.\nmenu?: string\nMenu identifier that the button will take you to, when defined an arrow.\nonSelect: function\nFunction that's ran when the button is clicked.\nicon?: string\nFontAwesome icon that will be displayed on the left side, works the same as notification and textui icons.\nAlso supports image urls, png and webp files but are not recommend to use over font awesome icons.\niconColor?: string\nColour of the displayed icon.\niconAnimation?: 'spin' 'spinPulse' 'spinReverse' 'pulse' 'beat' 'fade' 'beatFade' 'bounce' 'shake'\nprogress?: number\nAdds a progress bar filled to this percentage\ncolorScheme?: string\nSets the color scheme of the progress bar. Current options can be found here:\nhttps://v6.mantine.dev/theming/colors/#default-colors\nFor example: blue or teal\narrow?: boolean\nShows an arrow on the right side like menu does, useful when you are opening a menu from an event. Can be set to false to hide it.\ndescription?: string\nDescription that will appear under the button title that is defined as a key; has markdown support.\nimage?: string\nUrl to an image that will be displayed in the button's metadata.\nmetadata?: string[] or object or array\nInformation that will display on the side upon hovering a button.\nlabel: string\nvalue: any\nprogress?: number\nDisplay a progress bar in the metadata.\ncolorScheme?: string\nSame as above.\nevent?: string\nEvent that the button is going to trigger.\nserverEvent?: string\nServer event that the button is going to trigger.\nargs?: any\nArguments that will be sent to the events or onSelect function.\nYou can register as many context menus in one lib.registerContext function\nas you'd like.The menu can be either in the order you write it in, or sorted alphabetically.\nTo sort the menu alphabetically the buttons (and/or metadata) need to be defined as keys, otherwise not using keys and instead using tables will make the menu be in the order you define it as.","libshowcontext#lib.showContext":"Opens a registered context menu by its id.\nlib.showContext(id)\nimport lib from '@overextended/ox_lib/client';\nlib.showContext(id);\nid: string","libhidecontext#lib.hideContext":"Hides any currently visible context menu.\nlib.hideContext(onExit)\nimport lib from '@overextended/ox_lib/client';\nlib.hideContext(onExit);\nonExit: boolean\nDefines whether the onExit function for the menu should be ran or not.","libgetopencontextmenu#lib.getOpenContextMenu":"Returns the id of the currently open context menu.If no context menu is open returns nil.\nlib.getOpenContextMenu()\nimport lib from '@overextended/ox_lib/client';\nlib.getOpenContextMenu();","usage-example#Usage Example":"First we register the menu with our specified options then we call the show function in the command.\nAvoid constantly re-registering a menu that does not depend on any outside values (A.K.A a static menu).\nlib.registerContext({\n id = 'some_menu',\n title = 'Some context menu',\n options = {\n {\n title = 'Empty button',\n },\n {\n title = 'Disabled button',\n description = 'This button is disabled',\n icon = 'hand',\n disabled = true\n },\n {\n title = 'Example button',\n description = 'Example button description',\n icon = 'circle',\n onSelect = function()\n print(\"Pressed the button!\")\n end,\n metadata = {\n {label = 'Value 1', value = 'Some value'},\n {label = 'Value 2', value = 300}\n },\n },\n {\n title = 'Menu button',\n description = 'Takes you to another menu!',\n menu = 'other_menu',\n icon = 'bars'\n },\n {\n title = 'Event button',\n description = 'Open a menu from the event and send event data',\n icon = 'check',\n event = 'test_event',\n arrow = true,\n args = {\n someValue = 500\n }\n }\n }\n})\nimport lib from '@overextended/ox_lib/client';\nlib.registerContext({\n id: 'some_menu',\n title: 'Some context menu',\n options: [\n {\n title: 'Empty button',\n },\n {\n title: 'Disabled button',\n description: 'This button is disabled',\n icon: 'hand',\n disabled: true,\n },\n {\n title: 'Example button',\n description: 'Example button description',\n icon: 'circle',\n onSelect: () => {\n console.log('Pressed the button!');\n },\n metadata: [\n { label: 'Value 1', value: 'Some value' },\n { label: 'Value 2', value: 300 },\n ],\n },\n {\n title: 'Menu button',\n description: 'Takes you to another menu!',\n menu: 'other_menu',\n icon: 'bars',\n },\n {\n title: 'Event button',\n description: 'Open a menu from the event and send event data',\n icon: 'check',\n event: 'test_event',\n arrow: true,\n args: {\n someValue: 500,\n },\n },\n ],\n});\nThen we can also register our second menu called other_menu\nlib.registerContext({\n id = 'other_menu',\n title = 'Other context menu',\n menu = 'some_menu',\n onBack = function()\n print('Went back!')\n end,\n options = {\n {\n title = 'Nothing here'\n }\n }\n})\nlib.registerContext({\n id: 'other_menu',\n title: 'Other context menu',\n menu: 'some_menu',\n onBack: () => {\n console.log('Went back!');\n },\n options: [\n {\n title: 'Nothing here',\n },\n ],\n});\nAnd the event that we are going to run from the some_menu menu, which is going to open another menu.\nRegisterNetEvent('test_event', function(args)\n lib.registerContext({\n id = 'event_menu',\n title = 'Event menu',\n menu = 'some_menu',\n options = {\n {\n title = 'Event value: '..args.someValue,\n }\n }\n })\n lib.showContext('event_menu')\nend)\nonNet('test_event', (args: { someValue: number }) => {\n lib.registerContext({\n id: 'event_menu',\n title: 'Event menu',\n menu: 'some_menu',\n options: [\n {\n title: `Event value: ${args.someValue}`,\n },\n ],\n });\n lib.showContext('event_menu');\n});\nLastly we register a test command to show the some_menu menu.\nRegisterCommand('testcontext', function()\n lib.showContext('some_menu')\nend)\nRegisterCommand('testcontext', () => {\n lib.showContext('some_menu');\n});\nThe data from the args table in the menu is passed as a first argument to the event you register.Using this event we also register a new context menu with it's own options.By defining a menu param to be the id of the first menu we can get the back arrow button next to the menu title that will take us back."}},"/ox_lib/Modules/Interface/Client/menu":{"title":"Menu","data":{"":"Keyboard navigation menu with specific event functions.","libregistermenu#lib.registerMenu":"Registers and caches a menu under the specified id.\nlib.registerMenu(data, cb)\nimport lib from '@overextended/ox_lib/client';\nlib.registerMenu(data, cb);\ndata: table (object)\nid: string\ntitle: string\noptions: table (array)\nlabel: string\nprogress?: number\ncolorScheme?: string\nicon?: string\nFontAwesome icon that will be displayed on the left side, works the same as notification and textui icons.\nAlso supports image urls, png and webp files but are not recommend to use over font awesome icons.\niconColor?: string\niconAnimation?: 'spin' 'spinPulse' 'spinReverse' 'pulse' 'beat' 'fade' 'beatFade' 'bounce' 'shake'\nvalues?: string[] or { label: string, description: string }[]\nIf provided creates a side scrollable list.\nWhen using object and setting description, the set description will be displayed in the menu tooltip.\nchecked?: boolean\nSetting either true or false will make the button a checkbox, if values is also provided the button will be a\nscrollable list.\ndescription?: string\nDisplays tooltip below menu on hovered item with provided description.\ndefaultIndex?: number\nSets the current index for the list to specified number.\nargs?: {[string]: any}\nAllows you to pass any arguments through the button.\nIf the button has values then isScroll is automatically passed.\nIf the button has checked to either true or false then isCheck is automatically passed.\nclose?: boolean\nIf set to false, it won't close the menu upon interacting with this option.\nposition?: 'top-left' or 'top-right' or 'bottom-left' or 'bottom-right'\nDefault: 'top-left'\ndisableInput?: boolean\nDefault: false\ncanClose: boolean\nIf set to false the user won't be able to exit the menu without pressing one of the buttons.\nonClose: function(keyPressed?: 'Escape' | 'Backspace')\nFunction that runs when the menu is exited via ESC/Backspace.\nonSelected: function(selected: number, secondary: number | boolean, args: {[string]: any})\nFunction being ran when the selected button in the menu changes.\nonSideScroll: function(selected: number, scrollIndex: number, args: {[string]: any})\nFunction ran whenever a scroll list item is changed.\nonCheck: function(selected: number, checked: boolean, args: {[string]: any})\nFunction ran whenever a checkbox is toggled.\ncb: function(selected: number, scrollIndex: number, args: {[string]: any})\nCallback function when the menu item is pressed.","libshowmenu#lib.showMenu":"Displays the menu with the provided id.\nlib.showMenu(id)\nimport lib from '@overextended/ox_lib/client';\nlib.showMenu(id);\nid: string","libhidemenu#lib.hideMenu":"lib.hideMenu(onExit)\nimport lib from '@overextended/ox_lib/client';\nlib.hideMenu(onExit);\nonExit?: boolean\nIf true runs the menu's onClose function.","libgetopenmenu#lib.getOpenMenu":"Returns the id of the currently open menu.\nlib.getOpenMenu()\nimport lib from '@overextended/ox_lib/client';\nlib.getOpenMenu();","libsetmenuoptions#lib.setMenuOptions":"lib.setMenuOptions(id, options, index)\nimport lib from '@overextended/ox_lib/client';\nlib.setMenuOptions(id, options, index);\nid: string\noptions: table (object or array)\nindex?: number\nIf specified only sets the options table on the specified options index.\nExample:\nReplaces the 3rd index option of the specified menu\nlib.setMenuOptions('some_menu_id', {label = 'New option', icon = 'plus'}, 3)\nimport lib from '@overextended/ox_lib/client';\nlib.setMenuOptions('some_menu_id', { label: 'New option', icon: 'plus' }, 3);","usage-example#Usage Example":"First we register the menu with our specified options then we call the show function in the command.\nAvoid constantly re-registering a menu that does not depend on any outside values (A.K.A a static menu).\nlib.registerMenu({\n id = 'some_menu_id',\n title = 'Menu title',\n position = 'top-right',\n onSideScroll = function(selected, scrollIndex, args)\n print(\"Scroll: \", selected, scrollIndex, args)\n end,\n onSelected = function(selected, secondary, args)\n if not secondary then\n print(\"Normal button\")\n else\n if args.isCheck then\n print(\"Check button\")\n end\n if args.isScroll then\n print(\"Scroll button\")\n end\n end\n print(selected, secondary, json.encode(args, {indent=true}))\n end,\n onCheck = function(selected, checked, args)\n print(\"Check: \", selected, checked, args)\n end,\n onClose = function(keyPressed)\n print('Menu closed')\n if keyPressed then\n print(('Pressed %s to close the menu'):format(keyPressed))\n end\n end,\n options = {\n {label = 'Simple button', description = 'It has a description!'},\n {label = 'Checkbox button', checked = true},\n {label = 'Scroll button with icon', icon = 'arrows-up-down-left-right', values={'hello', 'there'}},\n {label = 'Button with args', args = {someArg = 'nice_button'}},\n {label = 'List button', values = {'You', 'can', 'side', 'scroll', 'this'}, description = 'It also has a description!'},\n {label = 'List button with default index', values = {'You', 'can', 'side', 'scroll', 'this'}, defaultIndex = 5},\n {label = 'List button with args', values = {'You', 'can', 'side', 'scroll', 'this'}, args = {someValue = 3, otherValue = 'value'}},\n }\n}, function(selected, scrollIndex, args)\n print(selected, scrollIndex, args)\nend)\nRegisterCommand('testmenu', function()\n lib.showMenu('some_menu_id')\nend)\nimport lib from '@overextended/ox_lib/client';\nlib.registerMenu(\n {\n id: 'some_menu_id',\n title: 'Menu title',\n position: 'top-right',\n onSideScroll: (selected, scrollIndex, args) => {\n console.log('Scroll: ', selected, scrollIndex, args);\n },\n onSelected: (selected, secondary, args) => {\n if (!secondary) {\n console.log('Normal button');\n } else {\n if (args.isCheck) {\n console.log('Check button');\n }\n if (args.isScroll) {\n console.log('Scroll button');\n }\n }\n console.log(selected, secondary, JSON.stringify(args, null, 2));\n },\n onCheck: (selected, checked, args) => {\n console.log('Check: ', selected, checked, args);\n },\n onClose: (keyPressed) => {\n console.log('Menu closed');\n if (keyPressed) {\n console.log(`Pressed ${keyPressed} to close the menu`);\n }\n },\n options: [\n { label: 'Simple button', description: 'It has a description!' },\n { label: 'Checkbox button', checked: true },\n { label: 'Scroll button with icon', icon: 'arrows-up-down-left-right', values: ['hello', 'there'] },\n { label: 'Button with args', args: { someArg: 'nice_button' } },\n {\n label: 'List button',\n values: ['You', 'can', 'side', 'scroll', 'this'],\n description: 'It also has a description!',\n },\n { label: 'List button with default index', values: ['You', 'can', 'side', 'scroll', 'this'], defaultIndex: 5 },\n {\n label: 'List button with args',\n values: ['You', 'can', 'side', 'scroll', 'this'],\n args: { someValue: 3, otherValue: 'value' },\n },\n ],\n },\n (selected, scrollIndex, args) => {\n console.log(selected, scrollIndex, args);\n }\n);\nRegisterCommand(\n 'testmenu',\n () => {\n lib.showMenu('some_menu_id');\n },\n false\n);"}},"/ox_lib/Modules/Interface/Client/notify":{"title":"Notifications","data":{"libnotify#lib.notify":"Custom notifications with a lot of styling options.\nlib.notify(data)\nTriggerClientEvent('ox_lib:notify', source, data)\nimport lib from '@overextended/ox_lib/client';\nlib.notify(data);\nid?: string\nWhen set the current notification will be unique and only shown once on screen when spammed.\ntitle?: string\nMust provide if there is no description\ndescription?: string\nMust provide if there is no title\nMarkdown support\nduration?: number\nposition?: 'top' or 'top-right' or 'top-left' or 'bottom' or 'bottom-right' or 'bottom-left' or 'center-right' or 'center-left'\nDefault: 'top-right'\ntype?: 'inform' or 'error' or 'success'or 'warning'\nDefault: 'inform'\nstyle?: table (object)\nReact CSS styling format\nicon?: string\nFont Awesome 6 icon name\niconColor?: string\niconAnimation?: 'spin' 'spinPulse' 'spinReverse' 'pulse' 'beat' 'fade' 'beatFade' 'bounce' 'shake'\nalignIcon?: 'top' or 'center'\nDefault: 'center'\nSetting iconColor will get rid of the contrasted icon colour and it's circular background.","usage-example#Usage Example":"","standard#Standard":"lib.notify({\n title = 'Notification title',\n description = 'Notification description',\n type = 'success'\n})\nimport lib from '@overextended/ox_lib/client';\nlib.notify({\n title: 'Notification title',\n description: 'Notification description',\n type: 'success',\n});","custom#Custom":"lib.notify({\n id = 'some_identifier',\n title = 'Notification title',\n description = 'Notification description',\n position = 'top',\n style = {\n backgroundColor = '#141517',\n color = '#C1C2C5',\n ['.description'] = {\n color = '#909296'\n }\n },\n icon = 'ban',\n iconColor = '#C53030'\n})\nimport lib from '@overextended/ox_lib/client';\nlib.notify({\n id: 'some_identifier',\n title: 'Notification title',\n description: 'Notification description',\n position: 'top',\n style: {\n backgroundColor: '#141517',\n color: '#C1C2C5',\n '.decription': {\n color: '#909296',\n },\n },\n icon: 'ban',\n iconColor: '#C53030',\n});"}},"/ox_lib/Modules/Interface/Client/progress":{"title":"Progress","data":{"libprogressbar#lib.progressBar":"Displays a running progress bar.\nlib.progressBar(data)\nimport lib from '@overextended/ox_lib/client'\nlib.progressBar(data)\nduration: number\nlabel: string\nuseWhileDead?: boolean\nallowRagdoll?: boolean\nallowCuffed?: boolean\nallowFalling?: boolean\ncanCancel?: boolean\nanim?: table (object)\ndict?: string\nMust specify either scenario or dict\nclip: string\nflag?: number\nDefault: 49\nblendIn?: float\nDefault: 3.0\nblendOut?: float\nDefault: 1.0\nduration?: number\nDefault: -1\nplaybackRate?: number\nDefault: 0\nlockX?: boolean\nlockY?: boolean\nlockZ?: boolean\nscenario?: string\nMust specify either scenario or dict\nplayEnter?: boolean\nDefault: true\nprop?: table (object or array)\n[ If you want to define multiple props, you can pass them as individual tables (array of objects) ]\nmodel: hash\nbone?: number\nDefault: 60309\npos: table\nx: number\ny: number\nz: number\nrot: table (object)\nx: number\ny: number\nz: number\ndisable?: table (object)\nmove?: boolean\ncar?: boolean\ncombat?: boolean\nmouse?: boolean\nsprint?: boolean","usage-example#Usage Example":"if lib.progressBar({\n duration = 2000,\n label = 'Drinking water',\n useWhileDead = false,\n canCancel = true,\n disable = {\n car = true,\n },\n anim = {\n dict = 'mp_player_intdrink',\n clip = 'loop_bottle'\n },\n prop = {\n model = `prop_ld_flow_bottle`,\n pos = vec3(0.03, 0.03, 0.02),\n rot = vec3(0.0, 0.0, -1.5)\n },\n}) then print('Do stuff when complete') else print('Do stuff when cancelled') end\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nimport lib from '@overextended/ox_lib/client'\nif (await lib.progressBar({\n duration: 2000,\n label: 'Drinking water',\n useWhileDead: false,\n canCancel: true,\n disable: {\n car: true,\n },\n anim: {\n dict: 'mp_player_intdrink',\n clip: 'loop_bottle'\n },\n prop: {\n model: `prop_ld_flow_bottle`,\n pos: {x: 0.03, y: 0.03, z: 0.02},\n rot: {x: 0.0, y: 0.0, z: -1.5}\n },\n})) console.log('Do stuff when complete');\nelse console.log('Do stuff when cancelled')","libprogresscircle#lib.progressCircle":"Similar to lib.progressBar except it displays a circle and you can define a position.\nlib.progressCircle(data)\nimport lib from '@overextended/ox_lib/client'\nlib.progressCircle(data)\nduration: number\nlabel?: string\nposition?: 'middle' or 'bottom'\nDefault: 'middle'\nuseWhileDead?: boolean\nallowRagdoll?: boolean\nallowCuffed?: boolean\nallowFalling?: boolean\ncanCancel?: boolean\nanim?: table (object)\ndict?: string\nMust specify either scenario or dict\nclip: string\nflag?: number\nDefault: 49\nblendIn?: float\nDefault: 3.0\nblendOut?: float\nDefault: 1.0\nduration?: number\nDefault: -1\nplaybackRate?: number\nDefault: 0\nlockX?: boolean\nlockY?: boolean\nlockZ?: boolean\nscenario?: string\nMust specify either scenario or dict\nplayEnter?: boolean\nDefault: true\nprop?: table (object or array)\n[ If you want to define multiple props, you can pass them as individual tables (array of objects) ]\nmodel: hash\nbone?: number\nDefault: 60309\npos: table\nx: number\ny: number\nz: number\nrot: table (object)\nx: number\ny: number\nz: number\ndisable?: table (object)\nmove?: boolean\ncar?: boolean\ncombat?: boolean\nmouse?: boolean\nsprint?: boolean","usage-example-1#Usage Example":"if lib.progressCircle({\n duration = 2000,\n position = 'bottom',\n useWhileDead = false,\n canCancel = true,\n disable = {\n car = true,\n },\n anim = {\n dict = 'mp_player_intdrink',\n clip = 'loop_bottle'\n },\n prop = {\n model = `prop_ld_flow_bottle`,\n pos = vec3(0.03, 0.03, 0.02),\n rot = vec3(0.0, 0.0, -1.5)\n },\n}) then print('Do stuff when complete') else print('Do stuff when cancelled') end\nThis function is asynchronous requiring you to do a .then callback on the promise or make your function async.\nimport lib from '@overextended/ox_lib/client'\nif (await lib.progressCircle({\n duration: 2000,\n position: 'bottom',\n useWhileDead: false,\n canCancel: true,\n disable: {\n car: true,\n },\n anim: {\n dict: 'mp_player_intdrink',\n clip: 'loop_bottle'\n },\n prop: {\n model: `prop_ld_flow_bottle`,\n pos: {x: 0.03, y: 0.03, z: 0.02},\n rot: {x: 0.0, y: 0.0, z: -1.5}\n },\n})) console.log('Do stuff when complete')\nelse console.log('Do stuff when cancelled')","libprogressactive#lib.progressActive":"Returns true if a progress bar is currently active.\nlib.progressActive()\nimport lib from '@overextended/ox_lib/client'\nlib.progressActive()","libcancelprogress#lib.cancelProgress":"If there is a progress bar active and the\nprogress bar can be cancelled then it cancels it.\nlib.cancelProgress()\nimport lib from '@overextended/ox_lib/client'\nlib.cancelProgress()"}},"/ox_lib/Modules/Interface/Client/skillcheck":{"title":"Skill Check","data":{"libskillcheck#lib.skillCheck":"Runs a skill check with the defined difficulty.\nlib.skillCheck(difficulty, inputs)\nimport lib from '@overextended/ox_lib/client';\nlib.skillCheck(difficulty, inputs);\ndifficulty: 'easy' or 'medium' or 'hard' or table\nPreset difficulties:\n'easy' - { areaSize: 50, speedMultiplier: 1 }\n'medium' - { areaSize: 40, speedMultiplier: 1.5 }\n'hard' - { areaSize: 25, speedMultiplier: 1.75 }\nCustom difficulties can be set by sending an object instead of one of the preset strings above\nareaSize: number\nSize of the success area in degrees\nspeedMultiplier: number\nMultiplier for the speed of the indicator\ninputs?: string[]\nA random key will be picked from the inputs table for each skill check\nIf no inputs are defined the key is defaulted to e","libskillcheckactive#lib.skillCheckActive":"Returns true if a skill check is currently active.\nlib.skillCheckActive()\nimport lib from '@overextended/ox_lib/client'\nlib.skillCheckActive()","libcancelskillcheck#lib.cancelSkillCheck":"Cancels the currently ongoing skill check.\nlib.cancelSkillCheck()\nimport lib from '@overextended/ox_lib/client'\nlib.cancelSkillCheck()","usage-example#Usage Example":"local success = lib.skillCheck({'easy', 'easy', {areaSize = 60, speedMultiplier = 2}, 'hard'}, {'w', 'a', 's', 'd'})\nimport lib from '@overextended/ox_lib/client';\nconst success = await lib.skillCheck(\n ['easy', 'easy', { areaSize: 60, speedMultiplier: 2 }, 'hard'],\n ['w', 'a', 's', 'd']\n);"}},"/ox_lib/Modules/Interface/Client/radial":{"title":"Radial Menu","data":{"":"Radial menu has a global menu that's by default accessed with z and only displays when there is at least one item.\nYou can add and remove items from the global menu using lib.addRadialItem and lib.removeRadialItem.\nUse lib.registerRadial for creating sub menus and use the menu property on the items to open those sub menus.","libaddradialitem#lib.addRadialItem":"Item or array of items added to the global radial menu.\nlib.addRadialItem(items)\nimport lib from '@overextended/ox_lib/client';\nlib.addRadialItem(items);\nitems: table (object or array)\nid: string\nId that is used for removing options.\nicon: string\nEither a font awesome or a custom URI.1\niconWidth?: number\niconHeight?: number\nIn the case of a custom URI, adjust the size of the icon.\nlabel: string\nLabel uses \\n to insert a newline\nmenu?: string\nId of a menu to open.\nonSelect: function(currentMenu: string | nil, itemIndex: number) | string\nFunction that's ran when a user clicks the item.\nkeepOpen?: boolean","libremoveradialitem#lib.removeRadialItem":"Id of an item to be removed from the global menu.\nlib.removeRadialItem(item)\nimport lib from '@overextended/ox_lib/client';\nlib.removeRadialItem(item);\nid: string","libclearradialitems#lib.clearRadialItems":"Removes all items from the radial menu.\nlib.clearRadialItems()\nimport lib from '@overextended/ox_lib/client';\nlib.clearRadialItems();","libregisterradial#lib.registerRadial":"Registers a radial sub menu with predefined options.\nlib.registerRadial(radial)\nimport lib from '@overextended/ox_lib/client';\nlib.registerRadial(radial);\nradial: table (object)\nid: string\nUnique menu id used to open with menu prop on an item.\nitems: array\nicon: string\nlabel: string\nLabel uses \\n to insert a newline\nmenu?: string\nId of a menu to open.\nonSelect?: function(currentMenu: string | nil, itemIndex: number) | string\nFunction that's ran when a user clicks the item.","libhideradial#lib.hideRadial":"Hides the radial menu if one is open.\nlib.hideRadial()\nimport lib from '@overextended/ox_lib/client';\nlib.hideRadial();","libdisableradial#lib.disableRadial":"Disallow players from opening the radial menu.\nlib.disableRadial(state)\nimport lib from '@overextended/ox_lib/client';\nlib.disableRadial(state);\nstate: boolean\nWhether or not radial menu should be disabled","libgetcurrentradialid#lib.getCurrentRadialId":"Returns the id of the currently open radial menu.\nlocal id = lib.getCurrentRadialId()\nimport lib from '@overextended/ox_lib/client';\nlet id = lib.getCurrentRadialId();","usage-example#Usage Example":"When adding radial menu items whether they are global or for a sub menu, make sure to stick to short as possible labels\nas long labels will look out of place and should not be used with the radial menu because of its density.\nHere's a use case example with some global options and an option utilising the lib's points system.\nexports('myMenuHandler', function(menu, item)\n print(menu, item)\n if menu == 'police_menu' and item == 1 then\n print('Handcuffs')\n end\nend)\nlib.registerRadial({\n id = 'police_menu',\n items = {\n {\n label = 'Handcuff',\n icon = 'handcuffs',\n onSelect = 'myMenuHandler'\n },\n {\n label = 'Frisk',\n icon = 'hand'\n },\n {\n label = 'Fingerprint',\n icon = 'fingerprint'\n },\n {\n label = 'Jail',\n icon = 'bus'\n },\n {\n label = 'Search',\n icon = 'magnifying-glass',\n onSelect = function()\n print('Search')\n end\n }\n }\n})\nlib.addRadialItem({\n {\n id = 'police',\n label = 'Police',\n icon = 'shield-halved',\n menu = 'police_menu'\n },\n {\n id = 'business_stuff',\n label = 'Business',\n icon = 'briefcase',\n onSelect = function()\n print(\"Business\")\n end\n }\n})\nlocal coords = GetEntityCoords(cache.ped)\nlocal point = lib.points.new(coords, 5)\nfunction point:onEnter()\n lib.addRadialItem({\n id = 'garage_access',\n icon = 'warehouse',\n label = 'Garage',\n onSelect = function()\n print('Garage')\n end\n })\nend\nfunction point:onExit()\n lib.removeRadialItem('garage_access')\nend\nPoints system in the lib isn't available for the npm package.\nimport lib from '@overextended/ox_lib/client'\nexports('myMenuHandler', (menu, item) => {\n console.log(menu, item)\n if (menu === 'police_menu' and item === 1) {\n console.log('Handcuffs')\n }\n})\nlib.registerRadial({\n id: 'police_menu',\n items: [\n {\n label: 'Handcuff',\n icon: 'handcuffs',\n onSelect: 'myMenuHandler'\n },\n {\n label: 'Frisk',\n icon: 'hand'\n },\n {\n label: 'Fingerprint',\n icon: 'fingerprint'\n },\n {\n label: 'Jail',\n icon: 'bus'\n },\n {\n label: 'Search',\n icon: 'magnifying-glass',\n onSelect: () => {\n console.log('Search')\n }\n }\n ]\n})\nlib.addRadialItem([\n {\n id: 'police',\n label: 'Police',\n icon: 'shield-halved',\n menu: 'police_menu'\n },\n {\n id: 'business_stuff',\n label: 'Business',\n icon: 'briefcase',\n onSelect: () => {\n console.log('Business')\n }\n }\n])"}},"/ox_lib/Modules/Interface/Client/textui":{"title":"TextUI","data":{"libshowtextui#lib.showTextUI":"Show the TextUI window.\nDO NOT run this function every tick, it's intended to be used as a toggle.\nlib.showTextUI(text, options)\nimport lib from '@overextended/ox_lib/client';\nlib.showTextUI(text, options);\ntext: string\noptions?: table\nposition?: 'right-center' or 'left-center' or 'top-center'\nDefault: 'right-center'\nicon?: string or table (array)\niconColor?: string\niconAnimation?: 'spin' 'spinPulse' 'spinReverse' 'pulse' 'beat' 'fade' 'beatFade' 'bounce' 'shake'\nstyle?: React.CSSProperties\nalignIcon?: 'top' or 'center'\nDefault: 'center'","libhidetextui#lib.hideTextUI":"Hides the currently visible TextUI window\nlib.hideTextUI()\nimport lib from '@overextended/ox_lib/client';\nlib.hideTextUI();","libistextuiopen#lib.isTextUIOpen":"Returns whether Text UI is opened or not. The currently displayed text is returned as the second value.\nlocal isOpen, text = lib.isTextUIOpen()\nimport lib from '@overextended/ox_lib/client';\nconst [isOpen, text] = lib.isTextUIOpen();","usage-example#Usage Example":"","basic#Basic":"lib.showTextUI('[E] - Fuel vehicle')\nimport lib from '@overextended/ox_lib/client';\nlib.showTextUI('[E] - Fuel vehicle');","custom-styling#Custom styling":"lib.showTextUI('[E] - Pick apple', {\n position = \"top-center\",\n icon = 'hand',\n style = {\n borderRadius = 0,\n backgroundColor = '#48BB78',\n color = 'white'\n }\n})\nimport lib from '@overextended/ox_lib/client';\nlib.showTextUI('[E] - Pick apple', {\n position: 'top-center',\n icon: 'hand',\n style: {\n borderRadius: 0,\n backgroundColor: '#48BB78',\n color: 'white',\n },\n});"}},"/ox_lib/Modules/Locale/Shared":{"title":"Shared","data":{"":"Allows servers to set a preferred language and attempt to load locale files in any resources using the module.\nLocale files should use the ISO Language Code and be saved as ./locales/langcode.json","setup#Setup":"To change the preferred language from English, add the convar to your server.cfg and change en to the desired language code.\nsetr ox:locale en\nCreate a locales directory and a file for your language.\n{\n \"grand_theft_auto\": \"grand theft auto\",\n \"male\": \"male\",\n \"female\": \"female\",\n \"suspect_sex\": \"suspect is %s\"\n}\n{\n \"grand_theft_auto\": \"vol de voiture\",\n \"male\": \"homme\",\n \"female\": \"femme\",\n \"suspect_sex\": \"le suspect est %s\"\n}\nfiles {\n 'locales/*.json'\n}","usage#Usage":"Initialise the locale module in your resource (once).\nlib.locale()\nimport {initLocale} from '@overextended/ox_lib/shared'\ninitLocale()\nFormat your strings with the new locale global.\nAdditional arguments can be sent to format the locale output.\nlocale(str, ...)\nimport { locale } from '@overextended/ox_lib/shared'\nlocale(str, ...)\nstr: string\nvararg?: string or number\nExample\n-- Load the locale module\nlib.locale()\nSetInterval(function()\n print(locale('grand_theft_auto'))\n print(locale('suspect_sex', locale('male')))\nend, 5000)\nimport { initLocale, locale } from '@overextended/ox_lib/shared\n// Load the locale module\ninitLocale()\nsetInterval(() => {\n console.log(locale('grand_theft_auto'))\n console.log(locale('suspect_sex', locale('male')))\n}, 5000)","phrases#Phrases":"You can create a locale string that references other locales to construct a phrase, rather than calling locale multiple times.\n{\n \"hello\": \"hello %s\",\n \"my_name_is\": \"my name is %s\",\n \"hello_my_name_is\": \"${hello}! ${my_name_is}.\"\n}\nprint(locale('hello_my_name_is', 'doka', 'linden'))\nimport { locale } from '@overextended/ox_lib/shared'\nconsole.log(locale('hello_my_name_is', 'doka', 'linden'))","libgetlocale#lib.getLocale":"Gets a locale string from another resource and adds it to the dict.\nlib.getLocale(resource, key)\nresource: string\nkey: string"}},"/ox_lib/Modules/Logger/Server":{"title":"Server","data":{"liblogger#lib.logger":"lib.logger(source, event, message, ...)\nsource: number or string\nPreferably an active player id, otherwise an identifier, or wherever else it originated from.\nevent: string\nA name for the log event (i.e. the trigerring event or a description)\nmessage: string\nThe content for the log.\nvararg: string\nAdditional arguments are converted to tags for additional filtering and searching.\nExample\nlocal vehicle = Ox.CreateVehicle(false, `sultanrs`, vector4(-56.479122, -1116.870362, 26.432250, 0.000030517578))\nlib.logger(-1, 'CreateVehicle', json.encode(vehicle))","datadog#Datadog":"","create-your-datadog-account#Create your Datadog account":"You will receive a free 14 day trial, otherwise refer to their pricing guide.\nFree accounts are limited, however logs will still be retained for 14 days.","create-an-api-key#Create an API key":"This is a UUID used to submit logs to your Datadog organisation.","config#Config":"Set your API key and Datadog site using the following convars.\nset datadog:key \"yourapikey\"\nset datadog:site \"datadoghq.com\"","grafana-loki#Grafana Loki":"Loki is a horizontally scalable, highly available, multi-tenant log aggregation system inspired by Prometheus.\nIt is designed to be very cost effective and easy to operate.\nHas free tier with some restrictions\nEasy to manage\nEasier to setup\nMostly managed by Grafana","create-your-grafana-account#Create your Grafana account":"","head-to-my-account#Head to My Account":"","setup-loki#Setup Loki":"Find the Loki section in your account panel, and click \"Details\".\nGenerate a password and save the API key, as well as your user and url.\nTo setup a grafana instance you'll need docker, and knowledge on containers or kubernetes.\nPlease find a guide to setup a grafana stack (min requirement grafana and grafana loki) and follow that.Once done, setup authentication and use the username and password securing your endpoint.\nBy default self-hosted loki instances do not provide any authentication layers and will require an external authentication layer such as NGINX basic auth or Cloudflare Access.","config-1#Config":"Use the following convars to set your logging service, endpoint, and authentication details.\nset ox:logger \"loki\"\nset loki:user \"\"\nset loki:password \"\"\nset loki:endpoint \"\""}},"/ox_lib/Modules/Math/Shared":{"title":"Shared","data":{"libmath#lib.math":"Extends the standard Lua math table with extra functions.\nmath = lib.math","mathtoscalars#math.toscalars":"Takes a string and returns a set of scalar values.\nmath.toscalars(input, min, max, round)\ninput: string\nmin?: number\nmax?: number\nround?: boolean\nReturn:\n...: number","mathtovector#math.tovector":"Takes a string or table and returns a vector value, or a number if only one value was found.\nmath.tovector(input, min, max, round)\ninput: string or table\nmin?: number\nmax?: number\nround?: boolean\nReturn:\nvalue: number or vector2 or vector3 or vector4","mathnormaltorotation#math.normaltorotation":"Takes a surface normal and tries to convert it to a vector3 rotation.\nmath.normaltorotation(input)\ninput: vector3\nReturn:\nvalue: vector3","mathtorgba#math.torgba":"Takes a string or table and returns a vector value, or a number if only one value was found.\nValues are rounded and must be within the range of 0-255.\nmath.torgba(input)\ninput: string or table\nReturn:\nvalue: number or vector2 or vector3 or vector4","mathhextorgb#math.hextorgb":"Takes a hexadecimal string and returns three integers.\nmath.hextorgb(input)\ninput: string\nA hexadecimal value, e.g. 'eb4034'.\nReturn:\nr: number\ng: number\nb: number","mathtohex#math.tohex":"Takes a number or string and formats it as a hexadecimal string.\nmath.tohex(n, upper)\nn: number or string\nupper?: boolean\nReturn:\nhex: string","mathgroupdigits#math.groupdigits":"Takes a number and formats it into grouped digits.\nmath.groupdigits(number, seperator)\nnumber: number\nseperator?: string\nDefault: ,\nReturn:\ngroupedDigits: string","mathclamp#math.clamp":"Clamps a number between a lower and upper limit.\nmath.clamp(number, lower, upper)\nnumber: number\nlower: number\nupper: number\nReturn:\nnumber: number"}},"/ox_lib/Modules/Marker/Client":{"title":"Client","data":{"libmarker#lib.marker":"Simple way to create markers","marker-class#Marker Class":"A table representing a marker with the following properties.\ntype: number or string\nThis field accepts either a numerical value representing the marker ID or a string containing the name of a marker as documented on FiveM Docs.\ncoords?: vector3\nwidth?: number\nheight?: number\ncolor?: { r: number, g: number, b: number, a: number}\ndirection?: vector3\nrotation?: vector3","libmarkernew#lib.marker.new":"lib.marker.new(options)\nReturns: Marker","usage-example#Usage Example":"local marker = lib.marker.new({\r\n\ttype = 1,\r\n\tcoords = GetEntityCoords(cache.ped),\r\n\tcolor = { r = 255, g = 0, b = 0, a = 200 },\r\n})\r\n\r\nCitizen.CreateThread(function()\r\n\twhile true do\r\n\t\tmarker:draw()\r\n\r\n\t\tCitizen.Wait(1)\r\n\tend\r\nend)","interactive-example#Interactive Example":"local point = lib.points.new({\r\n coords = SharedConfig.Warehouse.coords,\r\n distance = 20,\r\n})\r\n\r\nlocal marker = lib.marker.new({\r\n coords = GetEntityCoords(SharedConfig.Warehouse.coords),\r\n type = 1,\r\n})\r\n\r\nfunction point:nearby()\r\n marker:draw()\r\n\r\n if self.currentDistance < 1.5 then\r\n if not lib.isTextUIOpen() then\r\n lib.showTextUI(\"Press [E] to get notified\")\r\n end\r\n\r\n if IsControlJustPressed(0, 51) then\r\n lib.notify({\r\n description = \"Hello, World!\"\r\n })\r\n end\r\n else\r\n if lib.isTextUIOpen() then\r\n lib.hideTextUI()\r\n end\r\n end\r\nend"}},"/ox_lib/Modules/Points/JavaScript/Client":{"title":"Client","data":{"points#Points":"Simple and centralised distance checking, supporting callbacks when entering, leaving, and standing in-range of set coordinates.\nPoint({coords, distance, onEnter, onExit, nearby, args})\ncoords: number[]\ndistance: number\nonEnter?: function\nonExit?: function\nnearby?: function\nargs?: T\nimport { Point, cache } from '@overextended/ox_lib/client'\nfunction nearby(this: Point<{dunak: string}>) {\n // @ts-ignore\n DrawMarker(2, this.coords.x, this.coords.y, this.coords.z, 0, 0, 0, 0, 180, 0, 1, 1, 1, 200, 20, 20, 50, false, true, 2, false, null, null, false)\n if (this.currentDistance && this.currentDistance < 1 && IsControlJustReleased(0, 38)) {\n console.log('Inside marker', this.id)\n console.log(this.args?.dunak)\n }\n}\nconst point = new Point({\n coords: GetEntityCoords(cache.ped, false),\n distance: 5,\n nearby: nearby,\n args: {\n dunak: 'nerd'\n }\n})\npoint.onEnter = () => {\n console.log('Entered range of point', point.id)\n}\npoint.onExit = () => {\n console.log('Left range of point', point.id)\n}"}},"/ox_lib/Modules/Points/Lua/Client":{"title":"Client","data":{"":"Simple and centralised distance checking, supporting callbacks when entering, leaving, and standing in-range of set coordinates.","cpoint-class#CPoint Class":"A table representing a point with the following properties.\nid: number\ncoords: vector3\ndistance: number\nThe distance for the player to be \"inside\" a point (i.e. the point's radius).\ncurrentDistance: number\nThe players current distance from the centre of the point.\nisClosest?: boolean\nremove: function()\nRemoves the point from the points registry.\nonEnter?: function(self: CPoint)\nFunction triggered when player gets within distance of the point\nonExit?: function(self: CPoint)\nFunction triggered when player goes beyond distance of the point\nnearby?: function(self: CPoint)\nFunction triggered on frame when within distance of the point","libpointsnew#lib.points.new":"lib.points.new(data)\ndata: table\ncoords: vector3\ndistance: number\nReturns:\npoint: CPoint","usage-example#Usage Example":"local point = lib.points.new({\n coords = GetEntityCoords(cache.ped),\n distance = 5,\n dunak = 'nerd',\n})\nfunction point:onEnter()\n print('entered range of point', self.id)\nend\nfunction point:onExit()\n print('left range of point', self.id)\nend\nfunction point:nearby()\n DrawMarker(2, self.coords.x, self.coords.y, self.coords.z, 0.0, 0.0, 0.0, 0.0, 180.0, 0.0, 1.0, 1.0, 1.0, 200, 20, 20, 50, false, true, 2, false, nil, nil, false)\n if self.currentDistance < 1 and IsControlJustReleased(0, 38) then\n print('inside marker', self.id, 'dunak is a '.. self.dunak)\n end\nend","libpointsgetallpoints#lib.points.getAllPoints":"Get a table of all points created in the resource.\nlib.points.getAllPoints()\nReturn:\npoints: CPoint[]","libpointsgetnearbypoints#lib.points.getNearbyPoints":"Get an array of all points in range of the player.\nlib.points.getNearbyPoints()\nReturn:\nnearbyPoints: CPoint[]","libpointsgetclosestpoint#lib.points.getClosestPoint":"Get the data for the closest point to the player.\nlib.points.getClosestPoint()\nReturn:\nclosestPoint?: CPoint"}},"/ox_lib/Modules/Print/Shared":{"title":"Shared","data":{"":"Prints to console conditionally based on convars set.\nDifferent level prints are colored and labeled.\nResource name is always included.","libprint#lib.print":"lib.print.error(...)\nlib.print.warn(...)\nlib.print.info(...)\nlib.print.verbose(...)\nlib.print.debug(...)\nvararg: any\nWhat to print in console. Converts tables into a pretty-print format.","example#Example":"lib.print.warn(\"query latency high: \", latency)","levels#Levels":"Error\nIndicates a failure in the system.\nWarn\nWarns of an unexpected condition, or a state which is likely to cause an error in the future.\nInfo\nInformation about high-level, successful operations.\nVerbose\nMore detailed information containing intermediate steps of high-level, operations\nDebug\nUsed by developers to understand the system and may contain detailed trace information.\nShould generally not be turned on when not debugging.","config#Config":"Use the following convars to set your print level. Prints less severe than the current level will not be executed.\nFor example, a level of info will print error, warn, and info, but not verbose nor debug. Defaults to info if not set.\nResource specific print levels override the global convar.\nset ox:printlevel \"info\"\nset ox:printlevel:ox_inventory \"warn\"\nset ox:printlevel: \"\""}},"/ox_lib/Modules/Raycast/Client":{"title":"Client","data":{"libraycastcam#lib.raycast.cam":"Starts a shapetest originating from the camera, extending to ~10m by default.\nlib.raycast.cam(flags, ignore, distance)\nflags?: number\nSee: https://docs.fivem.net/natives/?_0x377906D8A31E5586\nDefault: 511\nignore?: number\nA bit mask with bits 1, 2, 4, or 7 relating to collider types. 4 and 7 are usually used.\nDefault: 4\ndistance?: number\nDefault: 10\nReturn:\nhit: boolean\nWhether or not an entity was hit\nentityHit: number\nEntity handle of hit entity\nendCoords: vector3\nClosest coords to where the raycast hit\nsurfaceNormal: vector3\nNormal to the surface that was hit\nmaterialHash: number"}},"/ox_lib/Modules/Require/Shared":{"title":"Shared","data":{"":"This module is always loaded by default.","require#require":"Loads the given module. The function starts by indexing the loaded table to determine whether modname is already loaded. If it is, then require returns the value stored at loaded[modname].\nModule names are the path to a file relative to the resource.\nThe module name must point to a .lua file.\nUse . to separate directories in a path.\nModules can be loaded from external resources using @resource.modname.\nrequire 'modname'\nClient modules must be defined in the file section of the resource manifest.\nfile 'modname.lua'\n-- or\nfiles {\n 'modname.lua'\n}","usage-example#Usage Example":"- resources/\n - mylib/\n - import.lua\n - data/\n - events.lua\n - myresource/\n - server.lua\nlocal mylib = {\n events = require 'data.events'\n}\nprint('Loaded mylib')\nreturn mylib\nreturn {\n disconnect = 'onPlayerDropped',\n}\nlocal mylib = require '@mylib.import'\nprint(mylib.events.disconnect)","libload#lib.load":"Loads and runs a Lua file at the given path. Unlike require, the chunk is not cached for future use.\nlib.load(filePath, env)\nfilePath: string\nA path to the Lua file, using the same rules as require.\nenv?: table\nA table to use as the global environment, defaulting to _ENV.","usage-example-1#Usage Example":"local events = lib.load('data.events')\nprint('Loaded events')\nreturn {\n disconnect = 'onPlayerDropped',\n}","libloadjson#lib.loadJson":"Loads a JSON file at the given path and decodes it as a table.\nlib.loadJson(filePath)\nfilePath: string\nA path to the Lua file, using the same rules as require.","usage-example-2#Usage Example":"local events = lib.loadJson('data.events')\nprint('Loaded events')\n{\n \"disconnect\": \"onPlayerDropped\"\n}"}},"/ox_lib/Modules/Streaming/Client":{"title":"Client","data":{"":"Check if assets exist, such as models, and loads them into memory.\nThrows errors for invalid assets and returns true if the asset is loaded.","librequestanimdict#lib.requestAnimDict":"lib.requestAnimDict(dict, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestAnimDict(dict, timeout)\ndict: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestanimset#lib.requestAnimSet":"lib.requestAnimSet(set, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestAnimSet(set, timeout)\nset: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestmodel#lib.requestModel":"lib.requestModel(model, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestModel(model, timeout)\nmodel: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequeststreamedtexturedict#lib.requestStreamedTextureDict":"lib.requestStreamedTextureDict(dict, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestStreamedTextureDict(dict, timeout)\ndict: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestnamedptfxasset#lib.requestNamedPtfxAsset":"lib.requestNamedPtfxAsset(ptFxName, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestNamedPtfxAsset(ptFxName, timeout)\nptFxName: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestscaleformmovie#lib.requestScaleformMovie":"lib.requestScaleformMovie(scaleformName, timeout)\nimport lib from '@overextended/ox_lib/client'\nlib.requestScaleformMovie(scaleformName, timeout)\nscaleformName: string\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500","librequestweaponasset#lib.requestWeaponAsset":"lib.requestWeaponAsset(weaponType, timeout, weaponResourceFlags, extraWeaponComponentFlags)\nimport lib from '@overextended/ox_lib/client'\nlib.requestWeaponAsset(weaponType, timeout, weaponResourceFlags, extraWeaponComponentFlags)\nweaponType: string | number\ntimeout?: number\nNumber of ticks to wait for the asset to load.\nDefault: 500\nweaponResourceFlags?: WeaponResourceFlags\nDefault: 31\nextraWeaponComponentFlags?: ExtraWeaponComponentFlags\nDefault: 0","weaponresourceflags#WeaponResourceFlags":"1 WRF_REQUEST_BASE_ANIMS\n2 WRF_REQUEST_COVER_ANIMS\n4 WRF_REQUEST_MELEE_ANIMS\n8 WRF_REQUEST_MOTION_ANIMS\n16 WRF_REQUEST_STEALTH_ANIMS\n32 WRF_REQUEST_ALL_MOVEMENT_VARIATION_ANIMS\n31 WRF_REQUEST_ALL_ANIMS","extraweaponcomponentflags#ExtraWeaponComponentFlags":"0 WEAPON_COMPONENT_NONE\n1 WEAPON_COMPONENT_FLASH\n2 WEAPON_COMPONENT_SCOPE\n4 WEAPON_COMPONENT_SUPP\n8 WEAPON_COMPONENT_SCLIP2\n16 WEAPON_COMPONENT_GRIP"}},"/ox_lib/Modules/String/Shared":{"title":"Shared","data":{"libstring#lib.string":"Extends the standard Lua string table with extra functions.\nstring = lib.string","stringrandom#string.random":"Outputs a random string based on a given pattern.\nstring.random(pattern, length)\npattern: string\n1 will output a random number from 0-9.\nA will output a random letter from A-Z.\na will output a random letter from a-z.\n. will output a random letter or number.\n^ will output the following character literally.\nAny other character will output said character.\nlength?: number\nSets the length of the returned string, either padding it or omitting characters.\nReturn:\nstring: string"}},"/ox_lib/Modules/Table/Shared":{"title":"Shared","data":{"":"Adds additional functions alongside the standard table library.","libtablecontains#lib.table.contains":"Checks if table contains the given value. Only intended for simple values and unnested tables.\nlib.table.contains(tbl, value)\ntbl: table\nvalue: any\nReturn:\nisContained: boolean","libtablematches#lib.table.matches":"Compares if two values are equal, iterating over tables and matching both keys and values.\nlib.table.matches(tableOne, tableTwo)\ntableOne: table\ntableTwo: table\nReturn:\nmatches: boolean","libtabledeepclone#lib.table.deepclone":"Recursively clones a table to ensure no table references remain.\nlib.table.deepclone(tbl)\ntbl: table\nReturn:\nclonedTable: table","libtablemerge#lib.table.merge":"Merges two tables together. Duplicate keys will be added together if they are numbers, otherwise tableTwo's value will be used.\nlib.table.merge(tableOne, tableTwo)\ntableOne: table\ntableTwo: table\nReturn:\ntableOne: table","libtablefreeze#lib.table.freeze":"Makes a table read-only, preventing further modification. Unfrozen tables stored within table are still mutable.\nlib.table.freeze(tbl)\ntbl: table\nReturn:\nfrozenTable: table","libtableisfrozen#lib.table.isFrozen":"Returns true if tbl is set as read-only.\nlib.table.isFrozen(tbl)\ntbl: table\nReturn:\nisFrozen: boolean"}},"/ox_lib/Modules/VehicleProperties/Client":{"title":"Client","data":{"":"Mostly follows the format used by ESX and QBCore, with extra data such as damaged/missing props.\nhttps://github.com/overextended/ox_lib/blob/master/resource/vehicleProperties/client.lua#L3","libgetvehicleproperties#lib.getVehicleProperties":"lib.getVehicleProperties(vehicle)\nvehicle: number\nvehicle handle of the vehicle to get the properties for\nlib.getVehicleProperties(GetVehiclePedIsUsing(PlayerPedId()))\nimport lib from '@overextended/ox_lib/client'\nlib.getVehicleProperties(GetVehiclePedIsUsing(PlayerPedId()))","libsetvehicleproperties#lib.setVehicleProperties":"Requires the vehicle to belong to the client. Do not use NetworkRequestControlOfEntity.\nlib.setVehicleProperties(vehicle, props)\nvehicle: entity\nprops: table (object)\nRegisterNetEvent('ox_lib:setVehicleProperties', function(netid, data)\n lib.setVehicleProperties(NetToVeh(netid), data)\nend)\nimport lib from '@overextended/ox_lib/client'\nonNet('ox_lib:setVehicleProperties', (netid, data) => {\n lib.setVehicleProperties(NetToVeh(netid), data)\n})","recommended-usage#Recommended Usage":"The server should tell the owner of the entity to set properties, using the following trigger.\nTriggerClientEvent('ox_lib:setVehicleProperties', entityOwner, vehNetId, data)","vehicle-properties#Vehicle Properties":"model?: number\nplate?: string\nplateIndex?: number\nbodyHealth?: number\nengineHealth?: number\ntankHealth?: number\nfuelLevel?: number\noilLevel?: number\ndirtLevel?: number\ncolor1?: number or number[]\ncolor2?: number or number[]\npearlescentColor?: number\ninteriorColor?: number\ndashboardColor?: number\nwheelColor?: number\nwheelWidth?: number\nwheelSize?: number\nwheels?: number\nwindowTint?: number\nxenonColor?: number\nneonEnabled?: boolean[]\nneonColor?: number or number[]\nextras?: table\ntyreSmokeColor?: number or number[]\nmodSpoilers?: number\nmodFrontBumper?: number\nmodRearBumper?: number\nmodSideSkirt?: number\nmodExhaust?: number\nmodFrame?: number\nmodGrille?: number\nmodHood?: number\nmodFender?: number\nmodRightFender?: number\nmodRoof?: number\nmodEngine?: number\nmodBrakes?: number\nmodTransmission?: number\nmodHorns?: number\nmodSuspension?: number\nmodArmor?: number\nmodNitrous?: number\nmodTurbo?: number\nmodSubwoofer?: boolean\nmodSmokeEnabled?: boolean\nmodHydraulics?: boolean\nmodXenon?: boolean\nmodFrontWheels?: number\nmodBackWheels?: number\nmodCustomTiresF?: boolean\nmodCustomTiresR?: boolean\nmodPlateHolder?: number\nmodVanityPlate?: number\nmodTrimA?: number\nmodOrnaments?: number\nmodDashboard?: number\nmodDial?: number\nmodDoorSpeaker?: number\nmodSeats?: number\nmodSteeringWheel?: number\nmodShifterLeavers?: number\nmodAPlate?: number\nmodSpeakers?: number\nmodTrunk?: number\nmodHydrolic?: number\nmodEngineBlock?: number\nmodAirFilter?: number\nmodStruts?: number\nmodArchCover?: number\nmodAerials?: number\nmodTrimB?: number\nmodTank?: number\nmodWindows?: number\nmodDoorR?: number\nmodLivery?: number\nmodRoofLivery?: number\nmodLightbar?: number\nwindows?: number[]\ndoors?: number[]\ntyres?: table\nbulletProofTyres?: boolean"}},"/ox_lib/Modules/Version/Server":{"title":"Server","data":{"libversioncheck#lib.versionCheck":"Compares the resource version to the latest published release on GitHub.\nUtilises GitHub's release API\nlib.versionCheck(repository)\nrepository: string\nlib.versionCheck('overextended/ox_lib')\nimport lib from '@overextended/ox_lib/server'\nlib.versionCheck('overextended/ox_lib')"}},"/ox_lib/Modules/WaitFor/Shared":{"title":"Shared","data":{"libwaitfor#lib.waitFor":"Calls a function repeatedly until it receives a non-nil value, or it times out.\nThe function result is then returned.\nlib.waitFor(cb, errMessage, timeout)\ncb: function\nA function to call each frame.\nerrMessage?: string\nThe error message to display if the function times out.\ntimeout?: number\nThe duration to run the function for, defaulting to 1000ms.\nlocal value --[['abc']] = lib.waitFor(function()\n if math.random(0, 1) == 1 then return 'abc' end\nend)"}},"/ox_lib/Modules/Version/Shared":{"title":"Shared","data":{"libcheckdependency#lib.checkDependency":"Check if a resource is using a specified version or higher, allowing for compatibility checks or throwing errors.\nlib.checkDependency(resource, version)\nresource: string\nversion: string\nif not lib.checkDependency('ox_lib', '1.5.0') then error() end\nimport lib from '@overextended/ox_lib/shared'\n// import { checkDependency } from '@overextended/ox_lib/shared'\nif (!lib.checkDependency('ox_lib', '1.5.0')) error()"}},"/ox_lib/Modules/Zones/Shared":{"title":"Shared","data":{"":"Faster alternative to PolyZone utilising glm.polygon.\nCurrently zones only have basic support on the server side. Some features will not work such as onEnter, onExit,\nand inside.","libzonespoly#lib.zones.poly":"lib.zones.poly(data)\ndata: table\npoints: vector3[]\nAll z values must match\nthickness?: number\nDefault: 4\nonEnter?: function(self: table)\nonExit?: function(self: table)\ninside?: function(self: table)\ndebug?: boolean","libzonesbox#lib.zones.box":"lib.zones.box(data)\ndata: table\ncoords: vector3\nsize?: vector3\nDefault: vec3(2, 2, 2)\nrotation?: number\nAngle in degrees\nDefault: 0\nonEnter?: function(self: table)\nonExit?: function(self: table)\ninside?: function(self: table)\ndebug?: boolean","libzonessphere#lib.zones.sphere":"lib.zones.sphere(data)\ndata: table\ncoords: vector3\nradius?: number\nDefault: 2\nonEnter?: function(self: table)\nonExit?: function(self: table)\ninside?: function(self: table)\ndebug?: boolean","methods#Methods":"","remove#remove":"Zones can be deleted by using the remove method. The data will not be cleared from the script, and can be used to recreate a zone later.\nlocal zone = lib.zones.box({...})\nzone:remove()\nSetTimeout(500, function()\n lib.zones.poly(zone)\nend)","contains#contains":"Tests if a point exists inside the zone, returning a boolean.\nlocal zone = lib.zones.box({...})\nif zone:contains(vec3(1, 1, 1)) then\n print('point is inside zone!')\nend","usage-examples#Usage Examples":"function onEnter(self)\n print('entered zone', self.id)\nend\nfunction onExit(self)\n print('exited zone', self.id)\nend\nfunction inside(self)\n print('you are inside zone ' .. self.id)\nend\nlocal poly = lib.zones.poly({\n points = {\n vec(413.8, -1026.1, 29),\n vec(411.6, -1023.1, 29),\n vec(412.2, -1018.0, 29),\n vec(417.2, -1016.3, 29),\n vec(422.3, -1020.0, 29),\n vec(426.8, -1015.9, 29),\n vec(431.8, -1013.0, 29),\n vec(437.3, -1018.4, 29),\n vec(432.4, -1027.2, 29),\n vec(424.7, -1023.5, 29),\n vec(420.0, -1030.2, 29),\n vec(409.8, -1028.4, 29),\n },\n thickness = 2,\n debug = true,\n inside = inside,\n onEnter = onEnter,\n onExit = onExit\n})\nlocal sphere = lib.zones.sphere({\n coords = vec3(442.5363, -1017.666, 28.65637),\n radius = 1,\n debug = true,\n inside = inside,\n onEnter = onEnter,\n onExit = onExit\n})\nlocal box = lib.zones.box({\n coords = vec3(442.5363, -1017.666, 28.65637),\n size = vec3(1, 1, 1),\n rotation = 45,\n debug = true,\n inside = inside,\n onEnter = onEnter,\n onExit = onExit\n})","zone-creation-script#Zone creation script":"You can use our builtin zone-creator with /zone - with poly, box or sphere as an argument.\nAvailable controls will be displayed on the right side.Zones will be saved to ox_lib/created_zones.lua with your chosen format.\nlocal poly = lib.zones.poly({\n name = poly,\n points = {\n vec(447.9, -998.8, 25.8),\n vec(450.3, -998.2, 25.8),\n vec(449.9, -995.5, 25.8),\n vec(447.2, -995.6, 25.8),\n vec(446.3, -997.9, 25.8),\n },\n thickness = 2,\n})\n{\n name = poly,\n points = {\n vec(447.9, -998.8, 25.8),\n vec(450.3, -998.2, 25.8),\n vec(449.9, -995.5, 25.8),\n vec(447.2, -995.6, 25.8),\n vec(446.3, -997.9, 25.8),\n },\n thickness = 2,\n},\nexports.ox_target:addPolyZone({\n name = poly,\n points = {\n vec(447.9, -998.8, 25.8),\n vec(450.3, -998.2, 25.8),\n vec(449.9, -995.5, 25.8),\n vec(447.2, -995.6, 25.8),\n vec(446.3, -997.9, 25.8),\n },\n thickness = 2,\n})"}},"/ox_target":{"title":"Ox Target","data":{"":"A performant and flexible standalone targeting resource or \"third-eye\", with additional functionality for ox_inventory, ox_core, qb-core, and es_extended.","installation#Installation":"We strongly recommend referring to Guides for setting up Git, Node.js, and pnpm.","install-all-resource-dependencies#Install all resource dependencies":"ox_lib","download-a-release-or-clone-the-source-code#Download a release or clone the source code.":"git clone https://github.com/overextended/ox_target.git","config#Config":"Resource configuration is handled using convars.\n# Toggle targeting when pressing the hotkey, instead of holding it down.\nsetr ox_target:toggleHotkey 0\n# Change the key to enable targeting (https://docs.fivem.net/docs/game-references/input-mapper-parameter-ids/keyboard)\nsetr ox_target:defaultHotkey LMENU\n# Draw a sprite (circle) at the centroid of a zone.\nsetr ox_target:drawSprite 1\n# Enable built-in targeting options, e.g. toggling vehicle doors.\nsetr ox_target:defaults 1\n# Enable debugging / testing options, entity outlines, and a raycast indicator.\nsetr ox_target:debug 0\n# Enable / Disable leftclick to select options\nsetr ox_target:leftClick 1","supported-frameworks#Supported Frameworks":"These aren't necessary to run ox_target, but they will add additional features.\nox_core\nesx\nqb-core"}},"/ox_target/Functions/Client":{"title":"Client","data":{"":"All exports with the options argument expect a table with the targeting properties here.For some examples you can refer to defaults.lua or debug.lua.","disabletargeting#disableTargeting":"Toggle the availability of the targeting menu.\nexports.ox_target:disableTargeting(state)\nstate: boolean\nSetting state to true will turn off the targeting eye if it is active and prevent it from reopening until state is set to false again.","addglobalobject#addGlobalObject":"Creates new targetable options for all Object entity types.\nexports.ox_target:addGlobalObject(options)\noptions: table","removeglobalobject#removeGlobalObject":"Removes all options from the global Object list with the option names.\nexports.ox_target:removeGlobalObject(optionNames)\noptionNames: string or string[]","addglobalped#addGlobalPed":"Creates new targetable options for all Ped entity types (excluding players).\nexports.ox_target:addGlobalPed(options)\noptions: table","removeglobalped#removeGlobalPed":"Removes all options from the global Ped list with the option names.\nexports.ox_target:removeGlobalPed(optionNames)\noptionNames: string or string[]","addglobalplayer#addGlobalPlayer":"Creates new targetable options for all Player entities.\nexports.ox_target:addGlobalPlayer(options)\noptions: table","removeglobalplayer#removeGlobalPlayer":"Removes all options from the global Player list with the option names.\nexports.ox_target:removeGlobalPlayer(optionNames)\noptionNames: string or string[]","addglobalvehicle#addGlobalVehicle":"Creates new targetable options for all Vehicle entity types.\nexports.ox_target:addGlobalVehicle(options)\noptions: table","removeglobalvehicle#removeGlobalVehicle":"Removes all options from the global Vehicle list with the option names.\nexports.ox_target:removeGlobalVehicle(optionNames)\noptionNames: string or string[]","addmodel#addModel":"Creates new targetable options for a specific model or list of models.\nexports.ox_target:addModel(models, options)\nmodels: number or string or Array\noptions: table","removemodel#removeModel":"Removes all options from the models list with the option names.\nexports.ox_target:removeModel(models, optionNames)\nmodels: number or string or Array\noptionNames: string or string[]","addentity#addEntity":"Creates new targetable options for a specific network id or list of network ids (see NetworkGetNetworkIdFromEntity).\nexports.ox_target:addEntity(netIds, options)\nnetIds: number or number[]\noptions: table","removeentity#removeEntity":"Removes all options from the networked entities list with the option names.\nexports.ox_target:removeEntity(netIds, optionNames)\nnetIds: number or number[]\noptionNames: string or string[]","addlocalentity#addLocalEntity":"Creates new targetable options for a specific entity handle or list of entity handles.\nexports.ox_target:addLocalEntity(entities, options)\nentities: number or number[]\noptions: table","removelocalentity#removeLocalEntity":"Removes all options from the entities list with the option names.\nexports.ox_target:removeLocalEntity(entities, optionNames)\nentities: number or number[]\noptionNames: string or string[]","addspherezone#addSphereZone":"Creates a new targetable sphere zone.\nexports.ox_target:addSphereZone(parameters)\nparameters: table\ncoords: vector\nradius?: number\ndebug?: boolean\ndrawSprite?: boolean\noptions: table\nReturn:\nid: number","addboxzone#addBoxZone":"Creates a new targetable box zone.\nexports.ox_target:addBoxZone(parameters)\nparameters: table\ncoords: vector\nsize?: vector3\nrotation?: number\ndebug?: boolean\ndrawSprite?: boolean\noptions: table\nReturn:\nid: number","addpolyzone#addPolyZone":"Creates a new targetable poly zone.\nexports.ox_target:addPolyZone(parameters)\nparameters: table\npoints: vector3[]\nAll z values must match\nthickness?: number\ndebug?: boolean\ndrawSprite?: boolean\noptions: table\nReturn:\nid: number","removezone#removeZone":"Removes a targetable zone with the given id (returned by addBoxZone/addSphereZone).\nexports.ox_target:removeZone(id)\nid: number or string\nThe number id that is returned by addSphereZone, addBoxZone, or addPolyZone\nOR\nThe string name that can be specified by the user"}},"/ox_target/Options":{"title":"Options","data":{"":"When creating a targetable option you must send an array of options with the following properties.","option-parameters#Option Parameters":"label: string\nname?: string\nAn identifier used when removing an option.\nicon?: string\nName of a Font Awesome icon.\niconColor?: string\ndistance?: number\nThe max distance to display the option.\nbones?: string or string[]\nA bone name or array of bone names (see GetEntityBoneIndexByName).\noffset?: vector3\nOffset the targetable area of an entity, relative to the model dimensions.\noffsetAbsolute?: vector3\nOffset the targetable area of an entity, relative to the entity's world coords.\noffsetSize?: number\nThe radius of the targetable area for an entity offset.\ngroups?: string or string[] or table\nA group, array of groups, or pairs of groups-grades required to show the option.\nGroups are framework dependent, and may refer to jobs, gangs, etc.\nitems?: string or string[] or table\nAn item, array of items, or pairs of items-count required to show the option.\nItems are framework dependent.\nanyItem?: boolean\nOnly require a single item from the items table to exist.\ncanInteract?: function(entity, distance, coords, name, bone)\nOptions will always display if this is undefined.\nmenuName?: string\nThe option is only displayed when a menu has been set with openMenu.\nopenMenu?: string\nSets the current menu name, displaying only options for the menuName.\nonSelect?: function(data)\nexport?: string\nevent?: string\nserverEvent?: string\ncommand?: string","option-effects#Option Effects":"When selecting an option it will trigger a single action, in order of priority:\nonSelect function\nexport\nevent\nserver event\ncommand"}},"/oxmysql":{"title":"OxMySQL","data":{"":"A replacement of mysql-async and ghmattimysql with expanded API and improved compatibility for MySQL 8.","mysql-or-mariadb#MySQL or MariaDB?":"Most resources for FiveM were designed to be used with MySQL 5.7 and may hit compatibility issues when using MySQL 8, i.e.\nMore reserved keywords, like 'stored' and 'group'.\nLongtext / JSON fields do not support default values.\nMariaDB is highly recommended for compatibility, and improved performance (over all versions of MySQL).","should-i-use-xampp#Should I use XAMPP?":"No. XAMPP is a webserver stack intended to be used for development, allowing easy local development and testing.\nDo not setup XAMPP just to run your database, and install MariaDB directly instead.","installation#Installation":"","download-the-latest-release#Download the latest release.":"","configure-your-server#Configure your server":"When using convars do not replicate sensitive information to the client.\nset will only be set on the server, while setr is replicated.\nStart by opening your server configuration (i.e. server.cfg) and adding start oxmysql before any of its dependents (usually it's the first resource you start).\nSet a mysql connection string using either of the following formats, using your server authentication details and target database.\nset mysql_connection_string \"mysql://root:12345@localhost:3306/es_extended\"\nset mysql_connection_string \"user=root;password=12345;host=localhost;port=3306;database=es_extended\"\nCertain special characters are reserved or unsupported depending on your connection string.\nAvoid using these characters ; , / ? : @ & = + $ #, and try swapping connection string format.","slow-query-warnings#Slow query warnings":"By default you will receive warnings if a query took ~150ms to complete, however\nQuery time is calculated on fxserver based on response time, and may not be entirely accurate.\nServer hitches may delay the query response, and may not indicate a database issue.\nExcessive queries in a short timeframe may report with higher response times.\nYou can adjust the minimum response time with a convar.\nset mysql_slow_query_warning 150\nSlow query warnings are only shown if mysql_ui or mysql_debug is enabled.","debug#Debug":"Enabling the debug option will print all queries in the server console; you can also use an array to only print from a list of resources instead.\nset mysql_debug true\nset mysql_debug [\n \"ox_core\",\n \"ox_inventory\"\n]\nThis value can be changed without restarting oxmysql, and you can temporarily modify the list with commands.\noxmysql_debug remove ox_core\noxmysql_debug add ox_core","mysql-async-compatibility#mysql-async compatibility":"The mysql-async directory must be deleted to properly provide support.\n🗹 Supports server_script '@mysql-async/lib/MySQL.lua'.\n🗹 Supports MySQL.Sync and MySQL.Async methods.\n☐ Raw exports are not supported (i.e. exports['mysql-async].mysql_execute).\n☐ Multi-statements are disabled for security reasons (see #102).","ghmattimysql-compatibility#ghmattimysql compatibility":"The ghmattimysql resource must be stopped to properly provide support.\n🗹 Supports exports.ghmattimysql.execute and other similar exports.\n🗹 Supports exports.ghmattimysql.executeSync and other similar exports.","usage#Usage":"Resources can import oxmysql methods by including our library, granting some type-checking and minor performance improvements over raw export calls.","lua#Lua":"Modify fxmanifest.lua for your resource, and add the following above any other script files.\nserver_script '@oxmysql/lib/MySQL.lua'\nIf you're using Lua Language Server you can get access to basic types and intellisense.\n\"Lua.workspace.library\": [\n \"C:/pathtoserver/resources/oxmysql/lib/define.lua\",\n]","javascript#JavaScript":"You can use raw exports, or install our npm package for intellisense and similar usage as Lua.\n# With pnpm\npnpm add @overextended/oxmysql\n# With Yarn\nyarn add @overextended/oxmysql\n# With npm\nnpm install @overextended/oxmysql\nImport the oxmysql object into your resource.\nimport { oxmysql as MySQL } from '@overextended/oxmysql';","upserting#Upserting":"When uncertain if a row should be inserted into the database, or an existing row should be updated, queries should check for duplicate keys.\nMySQL.prepare('INSERT INTO ox_inventory (owner, name, data) VALUES (?, ?, ?) ON DUPLICATE KEY UPDATE data = VALUES(data)', { owner, dbId, inventory })\nThis is preferred over checking the existence of a row, then inserting or updating depending on the result.\nFurthermore, unlike using 'REPLACE INTO', the row is not deleted and re-inserted."}},"/oxmysql/Functions/insert":{"title":"insert","data":{"":"Inserts a new entry into the database and returns the insert id for the row, if valid.","promise#Promise":"local id = MySQL.insert.await('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', {\n identifier, firstName, lastName\n})\nprint(id)\nconst id = await MySQL.insert('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', [\n identifier, firstName, lastName\n])\nconsole.log(id)\nAliases\nMySQL.Sync.insert\nexports.ghmattimysql.executeSync\nexports.oxmysql.insert_async","callback#Callback":"MySQL.insert('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', {\n identifier, firstName, lastName\n}, function(id)\n print(id)\nend)\nMySQL.insert('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', [\n identifier, firstName, lastName\n], (id) => {\n console.log(id)\n})\nAliases\nMySQL.Async.insert\nexports.ghmattimysql.execute\nexports.oxmysql.insert"}},"/oxmysql/Functions/prepare":{"title":"prepare","data":{"":"Prepare can be used to execute frequently called queries faster and accepts multiple sets of parameters to be used with a single query.\nDate will not return the datestring commonly used in FiveM\nTINYINT 1 and BIT will not return a boolean\nYou can only use ? value placeholders, ?? column placeholders and named placeholders will throw an error\nUnlike rawExecute, the SELECT statement will return a column, row, or array of rows depending on the number of columns and rows selected.","promise#Promise":"local response = MySQL.prepare.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n})\nprint(json.encode(response, { indent = true, sort_keys = true }))\nconst response = await MySQL.prepare('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n])\nconsole.log(JSON.stringify(response))\nAliases\nexports.oxmysql.prepare_async","callback#Callback":"MySQL.prepare('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n}, function(response)\n print(json.encode(response, { indent = true, sort_keys = true }))\nend)\nMySQL.prepare('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n], (response) => {\n console.log(JSON.stringify(response))\n})\nAliases\nexports.oxmysql.prepare"}},"/oxmysql/Functions/single":{"title":"single","data":{"":"Returns all selected columns for a single row.","promise#Promise":"local row = MySQL.single.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', {\n identifier\n})\nif not row then return end\nprint(row.firstname, row.lastname)\nconst row = await MySQL.single('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', [\n identifier\n])\nif (!row) return;\nconsole.log(row.firstname, row.lastname)\nAliases\nexports.oxmysql.single_async","callback#Callback":"MySQL.single('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', {\n identifier\n}, function(row)\n if not row then return end\n print(row.firstname, row.lastname)\nend)\nMySQL.single('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', [\n identifier\n], (row) => {\n if (!row) return;\n console.log(row.firstname, row.lastname)\n})\nAliases\nexports.oxmysql.single"}},"/oxmysql/Functions/scalar":{"title":"scalar","data":{"":"Returns the first column for a single row.","promise#Promise":"local firstName = MySQL.scalar.await('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', {\n identifier\n})\nprint(firstName)\nconst firstName = await MySQL.scalar('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', [\n identifier\n])\nconsole.log(firstName)\nAliases\nMySQL.Sync.fetchScalar\nexports.ghmattimysql.scalar\nexports.oxmysql.scalar_async","callback#Callback":"MySQL.scalar('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', {\n identifier\n}, function(firstName)\n print(firstName)\nend)\nMySQL.scalar('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', [\n identifier\n], (firstName) => {\n console.log(firstName)\n})\nAliases\nMySQL.Async.fetchScalar\nexports.ghmattimysql.scalar\nexports.oxmysql.scalar"}},"/oxmysql/Functions/rawExecute":{"title":"rawExecute","data":{"":"rawExecute can be used to execute frequently called queries faster and accepts multiple sets of parameters to be used with a single query.\nDate will not return the datestring commonly used in FiveM\nTINYINT 1 and BIT will not return a boolean\nYou can only use ? value placeholders, ?? column placeholders and named placeholders will throw an error\nUnlike prepare, the SELECT statement will always return an array of rows.\nWhen using SELECT, the return value will match query, single, or scalar depending on the number of columns and rows selected.","promise#Promise":"local response = MySQL.rawExecute.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n})\nprint(json.encode(response, { indent = true, sort_keys = true }))\nconst response = await MySQL.rawExecute('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n])\nconsole.log(JSON.stringify(response))\nAliases\nexports.oxmysql.rawExecute_async","callback#Callback":"MySQL.rawExecute('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n}, function(response)\n print(json.encode(response, { indent = true, sort_keys = true }))\nend)\nMySQL.rawExecute('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n], (response) => {\n console.log(JSON.stringify(response))\n})\nAliases\nexports.oxmysql.rawExecute"}},"/oxmysql/Functions/transaction":{"title":"transaction","data":{"":"A transaction executes multiple queries and commits them only if all succeed.\nIf one fails, none of the queries are committed.The return value is a boolean, which is the result of the transaction.","specific-format#Specific format":"When using this format, you must pass an array containing sets of queries and parameters to the transaction method.\nIn this case, your queries do not necessarily match and the values are unique to each query.\n-- You might rename \"values\" as \"parameters\" for mysql-async compatibility.\nlocal queries = {\n { query = 'INSERT INTO `test` (id) VALUES (?)', values = { 1 }},\n { query = 'INSERT INTO `test` (id, name) VALUES (?, ?)', values = { 2, 'bob' }},\n}\n-- You can also pass an array of arrays.\nlocal queries = {\n { 'INSERT INTO `test` (id) VALUES (?)', { 1 } },\n { 'INSERT INTO `test` (id, name) VALUES (?, ?)', { 2, 'bob' } },\n}","shared-format#Shared format":"When using this format, you must pass an array containing queries and a set containing shared parameters to the transaction method.\nIn this case, your queries do not necessarily match and the values are unique to each query.\n-- You might rename \"values\" as \"parameters\" for mysql-async compatibility.\nlocal queries = {\n 'INSERT INTO `test` (id, name) VALUES (@someid, @somename)',\n 'SET `name` = @newname IN `test` WHERE `id` = @someid'\n}\nlocal values = {\n someid = 2,\n somename = 'John Doe',\n newname = 'John Notdoe'\n}","promise#Promise":"local success = MySQL.transaction.await(queries, values --[[leave nil for specific format]])\nprint(success)\nconst success = await MySQL.transaction(queries, values /*leave nil for specific format*/)\nconsole.log(success)\nAliases\nMySQL.Sync.transaction\nexports.ghmattimysql.transaction\nexports.oxmysql.transaction_async","callback#Callback":"-- specific\nMySQL.transaction(queries, values, function(success)\n print(success)\nend)\n-- shared\nMySQL.transaction(queries, function(success)\n print(success)\nend)\n// specific\nMySQL.transaction(queries, (success) => {\n console.log(success)\n})\n// shared\nMySQL.transaction(queries, values, (success) => {\n console.log(success)\n})\nAliases\nMySQL.Async.transaction\nexports.ghmattimysql.transaction\nexports.oxmysql.transaction","transaction-isolation-level#Transaction Isolation Level":"This can be set through the convar mysql_transaction_isolation_level, and is an integer ranging from 1-4.\nThe default value is 2.\nConvar Value\tResult\t1\tRepeatable Read\t2\tRead Committed\t3\tRead Uncommitted\t4\tSerializable"}},"/oxmysql/Functions/update":{"title":"update","data":{"":"Returns the number of rows affected by the query.","promise#Promise":"local affectedRows = MySQL.update.await('UPDATE users SET firstname = ? WHERE identifier = ?', {\n newName, identifier\n})\nprint(affectedRows)\nconst affectedRows = await MySQL.update('UPDATE users SET firstname = ? WHERE identifier = ?', [\n newName, identifier\n])\nconsole.log(affectedRows)\nAliases\nMySQL.Sync.execute\nexports.ghmattimysql.executeSync\nexports.oxmysql.update_async","callback#Callback":"MySQL.update('UPDATE users SET firstname = ? WHERE identifier = ?', {\n newName, identifier\n}, function(affectedRows)\n print(affectedRows)\nend)\nMySQL.update('UPDATE users SET firstname = ? WHERE identifier = ?', [\n newName, identifier\n], (affectedRows) => {\n console.log(affectedRows)\n})\nAliases\nMySQL.Async.execute\nexports.ghmattimysql.execute\nexports.oxmysql.update"}},"/oxmysql/Functions/query":{"title":"query","data":{"":"When selecting data, returns all matching rows and columns; otherwise, returns data like insertId, affectedRows, etc.","promise#Promise":"local response = MySQL.query.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n})\nif response then\n for i = 1, #response do\n local row = response[i]\n print(row.firstname, row.lastname)\n end\nend\nconst response = await MySQL.query('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n])\nif (response) {\n response.forEach((row) => {\n console.log(row.identifier, row.firstname, row.lastname)\n })\n}\nAliases\nMySQL.Sync.fetchAll\nexports.ghmattimysql.execute\nexports.oxmysql.query_async","callback#Callback":"MySQL.query('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {\n identifier\n}, function(response)\n if response then\n for i = 1, #response do\n local row = response[i]\n print(row.firstname, row.lastname)\n end\n end\nend)\nMySQL.query('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', [\n identifier\n], (response) => {\n if (response) {\n response.forEach((row) => {\n console.log(row.firstname, row.lastname)\n })\n }\n})\nAliases\nMySQL.Async.fetchAll\nexports.ghmattimysql.execute\nexports.oxmysql.query"}},"/oxmysql/placeholders":{"title":"Placeholders","data":{"":"Placeholders allow for query parameters to be safely executed, preventing common SQL injection methods.Parameters can be passed an an array or map (referred to as named named parameters).\nlocal identifier = 'license:abc123'\nlocal group = 'admin'\nMySQL.scalar('SELECT `username` FROM `users` WHERE `identifier` = ? AND `group` = ?', { identifier, group })\n-- Named placeholders (deprecated)\nMySQL.scalar('SELECT `username` FROM `users` WHERE `identifier` = @identifier AND `group` = @group', {\n group = group\n identifier = identifier\n})\nThese are distinct from prepared statements which are handled by the MySQL server; you can use MySQL.prepare for more optimised and secure queries."}},"/oxmysql/issues":{"title":"Common Issues","data":{"unable-to-establish-a-connection#Unable to establish a connection":"This is usually the result of incorrect database settings or your password containing reserved characters.\n; , / ? : @ & = + $ # are reserved.\nEnsure you have entered the correct database settings in the mysql_connection_string convar. You can try using the\nsemicolon-separated format if your password contains reserved characters.","no-such-export--in-resource-oxmysql#No such export ... in resource oxmysql":"Download the latest release build (not the source code) of oxmysql.\nEnsure it is starting before any resources that require it.","numbers-treated-as-string#Numbers treated as string":"To resolve this issue simply enable decimalNumbers in your connection string, ie. mysql://root@localhost/essentialmode?decimalNumbers=true.\nJavaScript treats all numbers as floats, so a double or decimal value will be cast as a float with this setting.\nNumbers will have less precision when this setting is enabled."}},"/oxmysql/ui":{"title":"Using the Debug UI","data":{"":"The debug UI lets you easily see all the queries that have been executed by resources, query response times, and per-resource statistics.\nYou should only enable this during development, or with a small player count - for larger servers, look into builtin MySQL logging.Before using the UI first you have to make sure you have the mysql_ui convar set to true:\nset mysql_ui true\nAlso make sure that you have command or command.mysql ace permission access, then you should be able to use the mysql command in game.\nYou do not need to have the mysql_debug enabled to use the debug ui.","main-page#Main page":"The main page shows you the resources that ran queries where you can filter them through a search bar, your general data\nalong side a pie chart which shows what resources took the most query time.","resource-page#Resource page":"The resource page shows you all the queries and their execution time inside a table that the resource previously ran,\nalongside the total amount of the queries, execution time and slow queries for the selected resource.Columns can be sorted by ascending and descending order, and hovering over a query will display the full query inside a tooltip.\nQueries that exceed mysql_slow_query_warning (default 150ms) are displayed in orange.\nFor demonstation purposes the mysql_slow_query_warning convar was set to 5 here."}},"/guides/nodejs":{"title":"Node.js","data":{"":"Node.js is a JavaScript runtime and is used for building applications. In the context of FiveM it is necessary to bundle resources into a single package that can be ran on both the server and client.\nDownload and install the LTS version of Node.js.\nOpen a command-line terminal (e.g. Terminal, Command Prompt).\nEnter node --version to confirm successful installation."}},"/guides/vscode":{"title":"VS Code","data":{"":"Visual Studio Code is our recommended editor when working with Lua.","recommended-extensions#Recommended extensions":"Extensions let you add languages, debuggers, and other tools to VS Code - improving your developer experience.","sumnekolua#sumneko.lua":"Lua Language Server provides numerous language features to make development easier and faster, e.g.\nAnnotations\nAutocompletion\nCode formatting\nDiagnostics/warnings\nDynamic type checking\nSyntax checking","overextendedcfxlua-vscode#overextended.cfxlua-vscode":"Works alongside Lua Language Server to provide function and type declarations from Cfx's Lua runtime, Lua dialect, environment globals, and game natives."}},"/ox_inventory/Guides/shops":{"title":"Creating Shops","data":{"":"Builtin shops are defined in data/shops.lua, and more can be added here to benefit from the built-in markers or zones support.","shop-definition#Shop definition":"{\n General = {\n name = 'Shop',\n blip = {\n id = 59,\n colour = 69,\n scale = 0.8\n },\n inventory = {\n { name = 'burger', price = 10 },\n { name = 'water', price = 10 },\n { name = 'cola', price = 10 },\n },\n locations = {\n vec3(25.7, -1347.3, 29.49),\n },\n targets = {\n -- Shop using a BoxZone\n {\n loc = vec3(25.06, -1347.32, 29.5),\n length = 0.7,\n width = 0.5,\n heading = 0.0,\n minZ = 29.5,\n maxZ = 29.9,\n distance = 1.5\n },\n -- Shop using a ped\n {\n ped = `mp_m_shopkeep_01`,\n scenario = 'WORLD_HUMAN_AA_COFFEE',\n loc = vec3(24.407, -1347.283, 28.497),\n heading = 270.311,\n },\n }\n }\n}\nname: string\nThe label to display when the shop is open.\nblip?: table\nCreates a blip with the given settings. Leave it undefined for no blip to be created.\nid: number\ncolour: number\nscale: number\ngroups?: table\nKey-value pairs of job name and minimum grade to access the shop.\n{[\"police\"] = 0, [\"ambulance\"] = 2}\ninventory: table\nname: string\nprice: number\ncurrency?: string\nItem to be used as currency.\ncount?: number\nAmount of the item in the stock.\nlicense?: string\nLicense required to purchase the item.\nmetadata?: table\ngrade?: number | number[]\nGrade required to purchase the item.\nlocations?: vector3[]\nAn array of coordinates to create unique instances of the shop archetype at, using markers.\ntargets?: table[]\nAn array of target settings to create unique instances of the shop archetype at, using peds or BoxZones (PolyZone data structure).\nmodel?: number[]\nAn array of models that can be targetted to open a shop. Used for vending machines.\nTargets and model are only available when using a targeting resource like ox_target.","register-during-runtime#Register during runtime":"Shops can be added using exports.ox_inventory:RegisterShop on the server, however they cannot utilise any client-only features.\nBlips, markers, and zones will not be created.\nMust use \"locations\" and not \"targets\" to define each shop using the archetype.","example#Example":"exports.ox_inventory:RegisterShop('TestShop', {\n name = 'Test shop',\n inventory = {\n { name = 'burger', price = 10 },\n { name = 'water', price = 10 },\n { name = 'cola', price = 10 },\n },\n locations = {\n vec3(223.832962, -792.619751, 30.695190),\n },\n groups = {\n police = 0\n },\n})"}},"/oxmysql/benchmark":{"title":"Benchmark","data":{"":"Benchmarking is based on the time spent when to receive a response from exports.\nReal query speeds will be reported in the debug UI and in the server console with mysql_debug enabled.Speeds will vary greatly based on system hardware, database settings, database version, and the current workload.","script#Script":"This script tests export times when using the Lua 5.4 runtime with lib/MySQL.lua syntax.\nlocal function execQuery(msg, fn, query, parameters)\n local start = os.nanotime()\n local result = fn(query, parameters)\n local finish = os.nanotime()\n print()\n print(msg)\n print('Executed ' .. (type(query) == 'string' and 1 or #query) .. ' queries in ' .. (finish - start) / 1e6 .. 'ms')\n return result\nend\nCreateThread(function()\n local initTable = {\n 'DROP TABLE `test_table`',\n [[CREATE TABLE `test_table` (\n `id` INT UNSIGNED NOT NULL AUTO_INCREMENT,\n `username` VARCHAR(50) NOT NULL DEFAULT '0',\n `identifier` VARCHAR(50) NOT NULL DEFAULT '0',\n PRIMARY KEY (`id`)\n )]],\n 'TRUNCATE `test_table`',\n 'ALTER TABLE `test_table` AUTO_INCREMENT = 1',\n }\n execQuery('initialise test_table', MySQL.transaction.await, initTable)\n -- You might rename \"values\" as \"parameters\" for mysql-async compatibility.\n local queries = {\n { query = 'INSERT INTO `test_table` (identifier) VALUES (?)', values = { 'abcdef1' }},\n { query = 'UPDATE `test_table` SET `username` = ? WHERE `id` = LAST_INSERT_ID()', values = { 'bob1' }},\n }\n execQuery('{ query: string, values: string }[] transaction', MySQL.transaction.await, queries)\n -- You can pass an array of arrays.\n queries = {\n { 'INSERT INTO `test_table` (identifier) VALUES (?)', { 'abcdef2' } },\n { 'UPDATE `test_table` SET `username` = ? WHERE `id` = LAST_INSERT_ID()', { 'bob2' } },\n }\n execQuery('[string, any[]][] transaction', MySQL.transaction.await, queries)\n -- You can pass an array of queries.\n queries = {\n 'INSERT INTO `test_table` (identifier) VALUES (\"abcdef3\")',\n 'UPDATE `test_table` SET `username` = \"bob3\" WHERE `id` = LAST_INSERT_ID()',\n }\n execQuery('string[] transaction', MySQL.transaction.await, queries)\n local insertUsers = {}\n for i = 1, 10000 do\n insertUsers[i] = { 'INSERT INTO `test_table` (username, identifier) VALUES (?, ?)',\n { 'Testuser_' .. i, 'abcdef' .. i } }\n end\n execQuery('insert ' .. #insertUsers .. ' test users', MySQL.transaction.await, insertUsers)\n local selectUserIds = {}\n for i = 1, 10000 do\n if i % 4 == 0 then\n selectUserIds[math.tointeger(i / 4)] = { 'abcdef' .. i }\n end\n end\n execQuery('select every 4th userid', MySQL.prepare.await, 'SELECT `id` FROM `test_table` WHERE `identifier` = ? LIMIT 1', selectUserIds)\n local insertid = execQuery('insert', MySQL.insert.await, 'INSERT INTO `test_table` (identifier) VALUES (?)', { 'abcdef' })\n local update = execQuery('update', MySQL.update.await, 'UPDATE `test_table` SET `username` = ? WHERE `id` = ?', { 'bobby', insertid })\n local scalar = execQuery('scalar', MySQL.scalar.await, 'SELECT `username` FROM `test_table` WHERE `id` = ?', { insertid })\n local single = execQuery('single', MySQL.single.await, 'SELECT * FROM `test_table` WHERE `id` = ?', { insertid })\n print(json.encode(execQuery('prepare', MySQL.prepare.await, 'SELECT `username` FROM `test_table` WHERE `id` = ?', { insertid })))\n print(insertid, update, scalar, json.encode(single))\n execQuery('query', MySQL.query.await, 'SELECT `username` FROM `test_table` WHERE `id` = ? LIMIT 1', { 419 })\nend)","results#Results":"[script:test] initialise test_table\n[script:test] Executed 4 queries in 42.7789ms\n[script:test]\n[script:test] { query: string, values: string }[] transaction\n[script:test] Executed 2 queries in 8.0145ms\n[script:test]\n[script:test] [string, any[]][] transaction\n[script:test] Executed 2 queries in 4.0278ms\n[script:test]\n[script:test] string[] transaction\n[script:test] Executed 2 queries in 3.4743ms\n[script:test]\n[script:test] insert 10000 test users\n[script:test] Executed 10000 queries in 2064.211ms\n[script:test]\n[script:test] select every 4th userid\n[script:test] Executed 1 queries in 2803.7134ms\n[script:test]\n[script:test] insert\n[script:test] Executed 1 queries in 2.8743ms\n[script:test]\n[script:test] update\n[script:test] Executed 1 queries in 2.8675ms\n[script:test]\n[script:test] scalar\n[script:test] Executed 1 queries in 1.5387ms\n[script:test]\n[script:test] single\n[script:test] Executed 1 queries in 1.3389ms\n[script:test]\n[script:test] prepare\n[script:test] Executed 1 queries in 1.6577ms\n[script:test] \"bobby\"\n[script:test] 10004 1 bobby {\"identifier\":\"abcdef\",\"username\":\"bobby\",\"id\":10004}\n[script:test]\n[script:test] query\n[script:test] Executed 1 queries in 1.1588ms"}}} \ No newline at end of file diff --git a/_next/static/chunks/pages/_app-14425ade507ff56a.js b/_next/static/chunks/pages/_app-4dcd8df83df5d35d.js similarity index 76% rename from _next/static/chunks/pages/_app-14425ade507ff56a.js rename to _next/static/chunks/pages/_app-4dcd8df83df5d35d.js index 67d855b3a8..b665570a1c 100644 --- a/_next/static/chunks/pages/_app-14425ade507ff56a.js +++ b/_next/static/chunks/pages/_app-4dcd8df83df5d35d.js @@ -20,7 +20,7 @@ --nextra-primary-hue: ${ec}deg; --nextra-primary-saturation: ${ef}%; } - `}),eo]})]})}var sG={link:(0,ej.Z)("nx-flex nx-max-w-[50%] nx-items-center nx-gap-1 nx-py-4 nx-text-base nx-font-medium nx-text-gray-600 nx-transition-colors [word-break:break-word] hover:nx-text-primary-600 dark:nx-text-gray-300 md:nx-text-lg"),icon:(0,ej.Z)("nx-inline nx-h-5 nx-shrink-0")},sU=({flatDirectories:ee,currentIndex:en})=>{let er=sh(),ei=er.navigation,eo="boolean"==typeof ei?{prev:ei,next:ei}:ei,es=eo.prev&&ee[en-1],eu=eo.next&&ee[en+1];return(es&&!es.isUnderCurrentDocsTree&&(es=!1),eu&&!eu.isUnderCurrentDocsTree&&(eu=!1),es||eu)?(0,e_.jsxs)("div",{className:(0,ej.Z)("nx-mb-8 nx-flex nx-items-center nx-border-t nx-pt-8 dark:nx-border-neutral-800","contrast-more:nx-border-neutral-400 dark:contrast-more:nx-border-neutral-400","print:nx-hidden"),children:[es&&(0,e_.jsxs)(sy,{href:es.route,title:es.title,className:(0,ej.Z)(sG.link,"ltr:nx-pr-4 rtl:nx-pl-4"),children:[(0,e_.jsx)(eP.LZ,{className:(0,ej.Z)(sG.icon,"ltr:nx-rotate-180")}),es.title]}),eu&&(0,e_.jsxs)(sy,{href:eu.route,title:eu.title,className:(0,ej.Z)(sG.link,"ltr:nx-ml-auto ltr:nx-pl-4 ltr:nx-text-right rtl:nx-mr-auto rtl:nx-pr-4 rtl:nx-text-left"),children:[eu.title,(0,e_.jsx)(eP.LZ,{className:(0,ej.Z)(sG.icon,"rtl:nx-rotate-180")})]})]}):null},sW={link:(0,ej.Z)("nx-text-sm contrast-more:nx-text-gray-700 contrast-more:dark:nx-text-gray-100"),active:(0,ej.Z)("nx-font-medium nx-subpixel-antialiased"),inactive:(0,ej.Z)("nx-text-gray-600 hover:nx-text-gray-800 dark:nx-text-gray-400 dark:hover:nx-text-gray-200")};function sV({className:ee,menu:en,children:er}){let{items:ei}=en,eo=Object.fromEntries((en.children||[]).map(ee=>[ee.name,ee]));return(0,e_.jsx)("div",{className:"nx-relative nx-inline-block",children:(0,e_.jsxs)(o_,{children:[(0,e_.jsx)(o_.Button,{className:(0,ej.Z)(ee,"-nx-ml-2 nx-hidden nx-items-center nx-whitespace-nowrap nx-rounded nx-p-2 md:nx-inline-flex",sW.inactive),children:er}),(0,e_.jsx)(an,{leave:"nx-transition-opacity",leaveFrom:"nx-opacity-100",leaveTo:"nx-opacity-0",children:(0,e_.jsx)(o_.Items,{className:"nx-absolute nx-right-0 nx-z-20 nx-mt-1 nx-max-h-64 nx-min-w-full nx-overflow-auto nx-rounded-md nx-ring-1 nx-ring-black/5 nx-bg-white nx-py-1 nx-text-sm nx-shadow-lg dark:nx-ring-white/20 dark:nx-bg-neutral-800",tabIndex:0,children:Object.entries(ei||{}).map(([ee,er])=>{var ei;return(0,e_.jsx)(o_.Item,{children:(0,e_.jsx)(sy,{href:er.href||(null==(ei=eo[ee])?void 0:ei.route)||en.route+"/"+ee,className:(0,ej.Z)("nx-relative nx-hidden nx-w-full nx-select-none nx-whitespace-nowrap nx-text-gray-600 hover:nx-text-gray-900 dark:nx-text-gray-400 dark:hover:nx-text-gray-100 md:nx-inline-block","nx-py-1.5 nx-transition-colors ltr:nx-pl-3 ltr:nx-pr-9 rtl:nx-pr-3 rtl:nx-pl-9"),newWindow:er.newWindow,children:er.title||ee})},ee)})})})]})})}function sH({flatDirectories:ee,items:en}){let er=sh(),ei=eT(),{menu:eo,setMenu:es}=sc();return(0,e_.jsxs)("div",{className:"nextra-nav-container nx-sticky nx-top-0 nx-z-20 nx-w-full nx-bg-transparent print:nx-hidden",children:[(0,e_.jsx)("div",{className:(0,ej.Z)("nextra-nav-container-blur","nx-pointer-events-none nx-absolute nx-z-[-1] nx-h-full nx-w-full nx-bg-white dark:nx-bg-dark","nx-shadow-[0_2px_4px_rgba(0,0,0,.02),0_1px_0_rgba(0,0,0,.06)] dark:nx-shadow-[0_-1px_0_rgba(255,255,255,.1)_inset]","contrast-more:nx-shadow-[0_0_0_1px_#000] contrast-more:dark:nx-shadow-[0_0_0_1px_#fff]")}),(0,e_.jsxs)("nav",{className:"nx-mx-auto nx-flex nx-h-[var(--nextra-navbar-height)] nx-max-w-[90rem] nx-items-center nx-justify-end nx-gap-2 nx-pl-[max(env(safe-area-inset-left),1.5rem)] nx-pr-[max(env(safe-area-inset-right),1.5rem)]",children:[er.logoLink?(0,e_.jsx)(sy,{href:"string"==typeof er.logoLink?er.logoLink:"/",className:"nx-flex nx-items-center hover:nx-opacity-75 ltr:nx-mr-auto rtl:nx-ml-auto",children:sk(er.logo)}):(0,e_.jsx)("div",{className:"nx-flex nx-items-center ltr:nx-mr-auto rtl:nx-ml-auto",children:sk(er.logo)}),en.map(ee=>{if("hidden"===ee.display)return null;if("menu"===ee.type){let en=ee;return(0,e_.jsxs)(sV,{className:(0,ej.Z)(sW.link,"nx-flex nx-gap-1",sW.inactive),menu:en,children:[en.title,(0,e_.jsx)(eP.LZ,{className:"nx-h-[18px] nx-min-w-[18px] nx-rounded-sm nx-p-0.5",pathClassName:"nx-origin-center nx-transition-transform nx-rotate-90"})]},en.title)}let en=ee,er=en.href||en.route||"#";en.children&&(er=(en.withIndexPage?en.route:en.firstChildRoute)||er);let eo=en.route===ei||ei.startsWith(en.route+"/");return(0,e_.jsxs)(sy,{href:er,className:(0,ej.Z)(sW.link,"nx-relative -nx-ml-2 nx-hidden nx-whitespace-nowrap nx-p-2 md:nx-inline-block",!eo||en.newWindow?sW.inactive:sW.active),newWindow:en.newWindow,"aria-current":!en.newWindow&&eo,children:[(0,e_.jsx)("span",{className:"nx-absolute nx-inset-x-0 nx-text-center",children:en.title}),(0,e_.jsx)("span",{className:"nx-invisible nx-font-medium",children:en.title})]},er)}),sk(er.search.component,{directories:ee,className:"nx-hidden md:nx-inline-block mx-min-w-[200px]"}),er.project.link?(0,e_.jsx)(sy,{className:"nx-p-2 nx-text-current",href:er.project.link,newWindow:!0,children:sk(er.project.icon)}):null,er.chat.link?(0,e_.jsx)(sy,{className:"nx-p-2 nx-text-current",href:er.chat.link,newWindow:!0,children:sk(er.chat.icon)}):null,sk(er.navbar.extraContent),(0,e_.jsx)("button",{type:"button","aria-label":"Menu",className:"nextra-hamburger -nx-mr-2 nx-rounded nx-p-2 active:nx-bg-gray-400/20 md:nx-hidden",onClick:()=>es(!eo),children:(0,e_.jsx)(eP.Oq,{className:(0,ej.Z)({open:eo})})})]})]})}var sB=Object.create(null),sq=(0,eE.createContext)(null),sK=(0,eE.createContext)(null),sY=(0,eE.createContext)(0),sQ=(0,eE.memo)(function(ee){let en=(0,eE.useContext)(sY);return(0,e_.jsx)(sY.Provider,{value:en+1,children:(0,e_.jsx)(sX,o4({},ee))})}),sJ={link:(0,ej.Z)("nx-flex nx-rounded nx-px-2 nx-py-1.5 nx-text-sm nx-transition-colors [word-break:break-word]","nx-cursor-pointer [-webkit-tap-highlight-color:transparent] [-webkit-touch-callout:none] contrast-more:nx-border"),inactive:(0,ej.Z)("nx-text-gray-500 hover:nx-bg-gray-100 hover:nx-text-gray-900","dark:nx-text-neutral-400 dark:hover:nx-bg-primary-100/5 dark:hover:nx-text-gray-50","contrast-more:nx-text-gray-900 contrast-more:dark:nx-text-gray-50","contrast-more:nx-border-transparent contrast-more:hover:nx-border-gray-900 contrast-more:dark:hover:nx-border-gray-50"),active:(0,ej.Z)("nx-bg-primary-100 nx-font-semibold nx-text-primary-800 dark:nx-bg-primary-400/10 dark:nx-text-primary-600","contrast-more:nx-border-primary-500 contrast-more:dark:nx-border-primary-500"),list:(0,ej.Z)("nx-flex nx-flex-col nx-gap-1"),border:(0,ej.Z)("nx-relative before:nx-absolute before:nx-inset-y-1",'before:nx-w-px before:nx-bg-gray-200 before:nx-content-[""] dark:before:nx-bg-neutral-800',"ltr:nx-pl-3 ltr:before:nx-left-0 rtl:nx-pr-3 rtl:before:nx-right-0")};function sX({item:ee,anchors:en}){let er=eT(),[ei]=er.split("#"),eo=[ei,ei+"/"].includes(ee.route+"/"),es=eo||ei.startsWith(ee.route+"/"),eu=(0,eE.useContext)(sq),ec=!!(null==eu?void 0:eu.startsWith(ee.route+"/")),ed=(0,eE.useContext)(sY),{setMenu:ef}=sc(),eh=sh(),{theme:ep}=ee,em=void 0===sB[ee.route]?eo||es||ec||(ep&&"collapsed"in ep?!ep.collapsed:ed{let en=()=>{(es||ec)&&(sB[ee.route]=!0)},er=()=>{es&&ec?sB[ee.route]=!0:delete sB[ee.route]};eh.sidebar.autoCollapse?er():en()},[es,ec,ee.route,eh.sidebar.autoCollapse]),"menu"===ee.type){let en=ee,er=Object.fromEntries((en.children||[]).map(ee=>[ee.name,ee]));ee.children=Object.entries(en.items||{}).map(([ee,ei])=>{let eo=er[ee]||o5(o4({name:ee},"locale"in en&&{locale:en.locale}),{route:en.route+"/"+ee});return o4(o4({},eo),ei)})}let eg="withIndexPage"in ee&&ee.withIndexPage,ev=eg?sy:"button";return(0,e_.jsxs)("li",{className:(0,ej.Z)({open:em,active:eo}),children:[(0,e_.jsxs)(ev,{href:eg?ee.route:void 0,className:(0,ej.Z)("nx-items-center nx-justify-between nx-gap-2",!eg&&"nx-text-left nx-w-full",sJ.link,eo?sJ.active:sJ.inactive),onClick:en=>{let er=["svg","path"].includes(en.target.tagName.toLowerCase());if(er&&en.preventDefault(),eg){eo||er?sB[ee.route]=!em:(sB[ee.route]=!0,ef(!1)),ex({});return}eo||(sB[ee.route]=!em,ex({}))},children:[sk(eh.sidebar.titleComponent,{title:ee.title,type:ee.type,route:ee.route}),(0,e_.jsx)(eP.LZ,{className:"nx-h-[18px] nx-min-w-[18px] nx-rounded-sm nx-p-0.5 hover:nx-bg-gray-800/5 dark:hover:nx-bg-gray-100/5",pathClassName:(0,ej.Z)("nx-origin-center nx-transition-transform rtl:-nx-rotate-180",em&&"ltr:nx-rotate-90 rtl:nx-rotate-[-270deg]")})]}),(0,e_.jsx)(sS,{className:"ltr:nx-pr-0 rtl:nx-pl-0 nx-pt-1",isOpen:em,children:Array.isArray(ee.children)?(0,e_.jsx)(s2,{className:(0,ej.Z)(sJ.border,"ltr:nx-ml-3 rtl:nx-mr-3"),directories:ee.children,base:ee.route,anchors:en}):null})]})}function s0({title:ee}){let en=sh();return(0,e_.jsx)("li",{className:(0,ej.Z)("[word-break:break-word]",ee?"nx-mt-5 nx-mb-2 nx-px-2 nx-py-1.5 nx-text-sm nx-font-semibold nx-text-gray-900 first:nx-mt-0 dark:nx-text-gray-100":"nx-my-4"),children:ee?sk(en.sidebar.titleComponent,{title:ee,type:"separator",route:""}):(0,e_.jsx)("hr",{className:"nx-mx-2 nx-border-t nx-border-gray-200 dark:nx-border-primary-100/10"})})}function s1({item:ee,anchors:en}){let er=eT(),ei=(0,eE.useContext)(sK),eo=ee.route&&[er,er+"/"].includes(ee.route+"/"),es=sr(),{setMenu:eu}=sc(),ec=sh();return"separator"===ee.type?(0,e_.jsx)(s0,{title:ee.title}):(0,e_.jsxs)("li",{className:(0,ej.Z)(sJ.list,{active:eo}),children:[(0,e_.jsx)(sy,{href:ee.href||ee.route,newWindow:ee.newWindow,className:(0,ej.Z)(sJ.link,eo?sJ.active:sJ.inactive),onClick:()=>{eu(!1)},onFocus:()=>{null==ei||ei(ee.route)},onBlur:()=>{null==ei||ei(null)},children:sk(ec.sidebar.titleComponent,{title:ee.title,type:ee.type,route:ee.route})}),eo&&en.length>0&&(0,e_.jsx)("ul",{className:(0,ej.Z)(sJ.list,sJ.border,"ltr:nx-ml-3 rtl:nx-mr-3"),children:en.map(({id:ee,value:en})=>{var er;return(0,e_.jsx)("li",{children:(0,e_.jsx)("a",{href:`#${ee}`,className:(0,ej.Z)(sJ.link,'nx-flex nx-gap-2 before:nx-opacity-25 before:nx-content-["#"]',(null==(er=es[ee])?void 0:er.isActive)?sJ.active:sJ.inactive),onClick:()=>{eu(!1)},children:en})},ee)})})]})}function s2({directories:ee,anchors:en,className:er,onlyCurrentDocs:ei}){return(0,e_.jsx)("ul",{className:(0,ej.Z)(sJ.list,er),children:ee.map(ee=>!ei||ee.isUnderCurrentDocsTree?"menu"===ee.type||ee.children&&(ee.children.length||!ee.withIndexPage)?(0,e_.jsx)(sQ,{item:ee,anchors:en},ee.name):(0,e_.jsx)(s1,{item:ee,anchors:en},ee.name):null)})}function s4({docsDirectories:ee,flatDirectories:en,fullDirectories:er,asPopover:ei=!1,headings:eo,includePlaceholder:es}){let eu=sh(),{menu:ec,setMenu:ed}=sc(),ef=(0,eC.useRouter)(),[eh,ep]=(0,eE.useState)(null),[em,ex]=(0,eE.useState)(!0),[eg,ev]=(0,eE.useState)(!1),ey=(0,eE.useMemo)(()=>eo.filter(ee=>2===ee.depth),[eo]),eb=(0,eE.useRef)(null),ek=(0,eE.useRef)(null),ew=eS();(0,eE.useEffect)(()=>{ec?document.body.classList.add("nx-overflow-hidden","md:nx-overflow-auto"):document.body.classList.remove("nx-overflow-hidden","md:nx-overflow-auto")},[ec]),(0,eE.useEffect)(()=>{var ee;let en=null==(ee=eb.current)?void 0:ee.querySelector("li.active");if(en&&(window.innerWidth>767||ec)){let ee=()=>{oN(en,{block:"center",inline:"center",scrollMode:"always",boundary:ek.current})};ec?setTimeout(ee,300):ee()}},[ec]),(0,eE.useEffect)(()=>{ed(!1)},[ef.asPath,ed]);let eO=eu.i18n.length>0,eM=eu.darkMode||eO||eu.sidebar.toggleButton;return(0,e_.jsxs)(e_.Fragment,{children:[es&&ei?(0,e_.jsx)("div",{className:"max-xl:nx-hidden nx-h-0 nx-w-64 nx-shrink-0"}):null,(0,e_.jsx)("div",{className:(0,ej.Z)("motion-reduce:nx-transition-none [transition:background-color_1.5s_ease]",ec?"nx-fixed nx-inset-0 nx-z-10 nx-bg-black/80 dark:nx-bg-black/60":"nx-bg-transparent"),onClick:()=>ed(!1)}),(0,e_.jsxs)("aside",{className:(0,ej.Z)("nextra-sidebar-container nx-flex nx-flex-col","md:nx-top-16 md:nx-shrink-0 motion-reduce:nx-transform-none","nx-transform-gpu nx-transition-all nx-ease-in-out","print:nx-hidden",em?"md:nx-w-64":"md:nx-w-20",ei?"md:nx-hidden":"md:nx-sticky md:nx-self-start",ec?"max-md:[transform:translate3d(0,0,0)]":"max-md:[transform:translate3d(0,-100%,0)]"),ref:ek,children:[(0,e_.jsx)("div",{className:"nx-px-4 nx-pt-4 md:nx-hidden",children:sk(eu.search.component,{directories:en})}),(0,e_.jsx)(sq.Provider,{value:eh,children:(0,e_.jsx)(sK.Provider,{value:ee=>{ep(ee)},children:(0,e_.jsxs)("div",{className:(0,ej.Z)("nx-overflow-y-auto nx-overflow-x-hidden","nx-p-4 nx-grow md:nx-h-[calc(100vh-var(--nextra-navbar-height)-var(--nextra-menu-height))]",em?"nextra-scrollbar":"no-scrollbar"),ref:eb,children:[(!ei||!em)&&(0,e_.jsx)(sS,{isOpen:em,horizontal:!0,children:(0,e_.jsx)(s2,{className:"nextra-menu-desktop max-md:nx-hidden",directories:ee,anchors:eu.toc.float?[]:ey,onlyCurrentDocs:!0})}),ew&&window.innerWidth<768&&(0,e_.jsx)(s2,{className:"nextra-menu-mobile md:nx-hidden",directories:er,anchors:ey})]})})}),eM&&(0,e_.jsxs)("div",{className:(0,ej.Z)("nx-sticky nx-bottom-0","nx-bg-white dark:nx-bg-dark","nx-mx-4 nx-py-4 nx-shadow-[0_-12px_16px_#fff]","nx-flex nx-items-center nx-gap-2","dark:nx-border-neutral-800 dark:nx-shadow-[0_-12px_16px_#111]","contrast-more:nx-border-neutral-400 contrast-more:nx-shadow-none contrast-more:dark:nx-shadow-none",em?(0,ej.Z)(eO&&"nx-justify-end","nx-border-t"):"nx-py-4 nx-flex-wrap nx-justify-center"),"data-toggle-animation":eg?em?"show":"hide":"off",children:[(0,e_.jsx)(sD,{lite:!em,className:(0,ej.Z)(em?"nx-grow":"max-md:nx-grow")}),eu.darkMode&&(0,e_.jsx)("div",{className:em&&!eO?"nx-grow nx-flex nx-flex-col":"",children:sk(eu.themeSwitch.component,{lite:!em||eO})}),eu.sidebar.toggleButton&&(0,e_.jsx)("button",{title:em?"Hide sidebar":"Show sidebar",className:"max-md:nx-hidden nx-h-7 nx-rounded-md nx-transition-colors nx-text-gray-600 dark:nx-text-gray-400 nx-px-2 hover:nx-bg-gray-100 hover:nx-text-gray-900 dark:hover:nx-bg-primary-100/5 dark:hover:nx-text-gray-50",onClick:()=>{ex(!em),ev(!0)},children:(0,e_.jsx)(eP.Qq,{isOpen:em})})]})]})]})}var s5="reach-skip-nav",s3="Skip to content";(0,eE.forwardRef)(function(ee,en){var er=ee,{className:ei,id:eo,label:es=s3,styled:eu}=er,ec=o3(er,["className","id","label","styled"]);let ed=void 0===ei?eu?(0,ej.Z)("nx-sr-only","focus:nx-not-sr-only focus:nx-fixed focus:nx-z-50 focus:nx-m-3 focus:nx-ml-4 focus:nx-h-[calc(var(--nextra-navbar-height)-1.5rem)] focus:nx-rounded-lg focus:nx-border focus:nx-px-3 focus:nx-py-2 focus:nx-align-middle focus:nx-text-sm focus:nx-font-bold","focus:nx-text-gray-900 focus:dark:nx-text-gray-100","focus:nx-bg-white focus:dark:nx-bg-neutral-900","focus:nx-border-neutral-400 focus:dark:nx-border-neutral-800"):"":ei;return(0,e_.jsx)("a",o5(o4({},ec),{ref:en,href:`#${eo||s5}`,className:ed,"data-reach-skip-link":"",children:es}))}).displayName="SkipNavLink";var s7=(0,eE.forwardRef)(function(ee,en){var er=ee,{id:ei}=er,eo=o3(er,["id"]);return(0,e_.jsx)("div",o5(o4({},eo),{ref:en,id:ei||s5}))});s7.displayName="SkipNavContent";var s6=nS.strictObject({light:nS.string(),dark:nS.string(),system:nS.string()});function s9({lite:ee,className:en}){let{setTheme:er,resolvedTheme:ei,theme:eo=""}=nL(),es=eS(),eu=sh().themeSwitch,ec=es&&"dark"===ei?eP.kL:eP.NW,ed="function"==typeof eu.useOptions?eu.useOptions():eu.useOptions;return(0,e_.jsx)(sF,{className:en,title:"Change theme",options:[{key:"light",name:ed.light},{key:"dark",name:ed.dark},{key:"system",name:ed.system}],onChange:ee=>{er(ee.key)},selected:{key:eo,name:(0,e_.jsxs)("div",{className:"nx-flex nx-items-center nx-gap-2 nx-capitalize",children:[(0,e_.jsx)(ec,{}),(0,e_.jsx)("span",{className:ee?"md:nx-hidden":"",children:es?ed[eo]:ed.light})]})}})}function s8(){window.scrollTo({top:0,behavior:"smooth"})}function lt({className:ee}){let en=(0,eE.useRef)(null);return(0,eE.useEffect)(()=>{function ee(){var ee;let{scrollTop:er}=document.documentElement;null==(ee=en.current)||ee.classList.toggle("nx-opacity-0",er<300)}return window.addEventListener("scroll",ee),()=>{window.removeEventListener("scroll",ee)}},[]),(0,e_.jsxs)("button",{ref:en,"aria-hidden":"true",onClick:s8,className:(0,ej.Z)("nx-flex nx-items-center nx-gap-1.5 nx-transition nx-opacity-0",ee),children:["Scroll to top",(0,e_.jsx)(eP.LZ,{className:"-nx-rotate-90 nx-w-3.5 nx-h-3.5 nx-border nx-rounded-full nx-border-current"})]})}var ln=(0,ej.Z)("nx-text-xs nx-font-medium nx-text-gray-500 hover:nx-text-gray-900 dark:nx-text-gray-400 dark:hover:nx-text-gray-100","contrast-more:nx-text-gray-800 contrast-more:dark:nx-text-gray-50");function lr({headings:ee,filePath:en}){var er;let ei=sr(),eo=sh(),es=(0,eE.useRef)(null),eu=(0,eE.useMemo)(()=>ee.filter(ee=>ee.depth>1),[ee]),ec=eu.length>0,ed=!!(eo.feedback.content||eo.editLink.component||eo.toc.extraContent),ef=null==(er=Object.entries(ei).find(([,{isActive:ee}])=>ee))?void 0:er[0];return(0,eE.useEffect)(()=>{var ee;if(!ef)return;let en=null==(ee=es.current)?void 0:ee.querySelector(`li > a[href="#${ef}"]`);en&&oN(en,{behavior:"smooth",block:"center",inline:"center",scrollMode:"always",boundary:es.current})},[ef]),(0,e_.jsxs)("div",{ref:es,className:(0,ej.Z)("nextra-scrollbar nx-sticky nx-top-16 nx-overflow-y-auto nx-pr-4 nx-pt-6 nx-text-sm [hyphens:auto]","nx-max-h-[calc(100vh-var(--nextra-navbar-height)-env(safe-area-inset-bottom))] ltr:-nx-mr-4 rtl:-nx-ml-4"),children:[ec&&(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)("p",{className:"nx-mb-4 nx-font-semibold nx-tracking-tight",children:sk(eo.toc.title)}),(0,e_.jsx)("ul",{children:eu.map(({id:ee,value:en,depth:er})=>{var es,eu,ec,ed;return(0,e_.jsx)("li",{className:"nx-my-2 nx-scroll-my-6 nx-scroll-py-6",children:(0,e_.jsx)("a",{href:`#${ee}`,className:(0,ej.Z)({2:"nx-font-semibold",3:"ltr:nx-pl-4 rtl:nx-pr-4",4:"ltr:nx-pl-8 rtl:nx-pr-8",5:"ltr:nx-pl-12 rtl:nx-pr-12",6:"ltr:nx-pl-16 rtl:nx-pr-16"}[er],"nx-inline-block",(null==(es=ei[ee])?void 0:es.isActive)?"nx-text-primary-600 nx-subpixel-antialiased contrast-more:!nx-text-primary-600":"nx-text-gray-500 hover:nx-text-gray-900 dark:nx-text-gray-400 dark:hover:nx-text-gray-300","contrast-more:nx-text-gray-900 contrast-more:nx-underline contrast-more:dark:nx-text-gray-50 nx-w-full nx-break-words"),children:null!=(ed=null==(ec=(eu=eo.toc).headingComponent)?void 0:ec.call(eu,{id:ee,children:en}))?ed:en})},ee)})})]}),ed&&(0,e_.jsxs)("div",{className:(0,ej.Z)(ec&&"nx-mt-8 nx-border-t nx-bg-white nx-pt-8 nx-shadow-[0_-12px_16px_white] dark:nx-bg-dark dark:nx-shadow-[0_-12px_16px_#111]","nx-sticky nx-bottom-0 nx-flex nx-flex-col nx-items-start nx-gap-2 nx-pb-8 dark:nx-border-neutral-800","contrast-more:nx-border-t contrast-more:nx-border-neutral-400 contrast-more:nx-shadow-none contrast-more:dark:nx-border-neutral-400"),children:[eo.feedback.content?(0,e_.jsx)(sy,{className:ln,href:eo.feedback.useLink(),newWindow:!0,children:sk(eo.feedback.content)}):null,sk(eo.editLink.component,{filePath:en,className:ln,children:sk(eo.editLink.text)}),sk(eo.toc.extraContent),eo.toc.backToTop&&(0,e_.jsx)(lt,{className:ln})]})]})}function li({className:ee,directories:en}){let[er,ei]=(0,eE.useState)(""),eo=(0,eE.useMemo)(()=>er?oF(en,er,{keys:["title"]}).map(({route:ee,title:en})=>({id:ee+en,route:ee,children:(0,e_.jsx)(sO,{value:en,match:er})})):[],[er,en]);return(0,e_.jsx)(sN,{value:er,onChange:ei,className:ee,overlayClassName:"nx-w-full",results:eo})}var lo="en-US",ls="undefined"!=typeof window;function ll(ee){return null==ee||"string"==typeof ee||lu(ee)||(0,eE.isValidElement)(ee)}function lu(ee){return"function"==typeof ee}var lc=nS.array(nS.strictObject({direction:nS.enum(["ltr","rtl"]).optional(),locale:nS.string(),text:nS.string()})),ld=[ll,{message:"Must be React.ReactNode or React.FC"}],lf=[lu,{message:"Must be React.FC"}];nS.strictObject({banner:nS.strictObject({dismissible:nS.boolean(),key:nS.string(),text:nS.custom(...ld).optional()}),chat:nS.strictObject({icon:nS.custom(...ld),link:nS.string().startsWith("https://").optional()}),components:nS.record(nS.custom(...lf)).optional(),darkMode:nS.boolean(),direction:nS.enum(["ltr","rtl"]),docsRepositoryBase:nS.string().startsWith("https://"),editLink:nS.strictObject({component:nS.custom(...lf),text:nS.custom(...ld)}),faviconGlyph:nS.string().optional(),feedback:nS.strictObject({content:nS.custom(...ld),labels:nS.string(),useLink:nS.function().returns(nS.string())}),footer:nS.strictObject({component:nS.custom(...ld),text:nS.custom(...ld)}),gitTimestamp:nS.custom(...ld),head:nS.custom(...ld),i18n:lc,logo:nS.custom(...ld),logoLink:nS.boolean().or(nS.string()),main:nS.custom(...lf).optional(),navbar:nS.strictObject({component:nS.custom(...ld),extraContent:nS.custom(...ld).optional()}),navigation:nS.boolean().or(nS.strictObject({next:nS.boolean(),prev:nS.boolean()})),nextThemes:nS.strictObject({defaultTheme:nS.string(),forcedTheme:nS.string().optional(),storageKey:nS.string()}),notFound:nS.strictObject({content:nS.custom(...ld),labels:nS.string()}),primaryHue:nS.number().or(nS.strictObject({dark:nS.number(),light:nS.number()})),primarySaturation:nS.number().or(nS.strictObject({dark:nS.number(),light:nS.number()})),project:nS.strictObject({icon:nS.custom(...ld),link:nS.string().startsWith("https://").optional()}),search:nS.strictObject({component:nS.custom(...ld),emptyResult:nS.custom(...ld),error:nS.string().or(nS.function().returns(nS.string())),loading:nS.custom(...ld),placeholder:nS.string().or(nS.function().returns(nS.string()))}),serverSideError:nS.strictObject({content:nS.custom(...ld),labels:nS.string()}),sidebar:nS.strictObject({autoCollapse:nS.boolean().optional(),defaultMenuCollapseLevel:nS.number().min(1).int(),titleComponent:nS.custom(...ld),toggleButton:nS.boolean()}),themeSwitch:nS.strictObject({component:nS.custom(...ld),useOptions:s6.or(nS.function().returns(s6))}),toc:nS.strictObject({backToTop:nS.boolean(),component:nS.custom(...ld),extraContent:nS.custom(...ld),float:nS.boolean(),headingComponent:nS.custom(...lf).optional(),title:nS.custom(...ld)}),useNextSeoProps:nS.custom(lu)}).deepPartial().extend({i18n:lc.optional()});var lh={"en-US":"Loading",fr:"Сhargement",ru:"Загрузка","zh-CN":"正在加载"},lp={"en-US":"Search documentation",fr:"Rechercher documents",ru:"Поиск документации","zh-CN":"搜索文档"},lm={banner:{dismissible:!0,key:"nextra-banner"},chat:{icon:(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)(eP.D7,{}),(0,e_.jsx)("span",{className:"nx-sr-only",children:"Discord"})]})},darkMode:!0,direction:"ltr",docsRepositoryBase:"https://github.com/shuding/nextra",editLink:{component:function({className:ee,filePath:en,children:er}){let ei=sC(en);return ei?(0,e_.jsx)(sy,{className:ee,href:ei,children:er}):null},text:"Edit this page"},feedback:{content:"Question? Give us feedback →",labels:"feedback",useLink(){let ee=sh();return sb({labels:ee.feedback.labels,repository:ee.docsRepositoryBase,title:`Feedback for \u201C${ee.title}\u201D`})}},footer:{component:sz,text:`MIT ${new Date().getFullYear()} \xa9 Nextra.`},gitTimestamp:function({timestamp:ee}){let{locale:en=lo}=(0,eC.useRouter)();return(0,e_.jsxs)(e_.Fragment,{children:["Last updated on"," ",(0,e_.jsx)("time",{dateTime:ee.toISOString(),children:ee.toLocaleDateString(en,{day:"numeric",month:"long",year:"numeric"})})]})},head:(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)("meta",{name:"msapplication-TileColor",content:"#fff"}),(0,e_.jsx)("meta",{httpEquiv:"Content-Language",content:"en"}),(0,e_.jsx)("meta",{name:"description",content:"Nextra: the next docs builder"}),(0,e_.jsx)("meta",{name:"twitter:card",content:"summary_large_image"}),(0,e_.jsx)("meta",{name:"twitter:site",content:"@shuding_"}),(0,e_.jsx)("meta",{property:"og:title",content:"Nextra: the next docs builder"}),(0,e_.jsx)("meta",{property:"og:description",content:"Nextra: the next docs builder"}),(0,e_.jsx)("meta",{name:"apple-mobile-web-app-title",content:"Nextra"})]}),i18n:[],logo:(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)("span",{className:"nx-font-extrabold",children:"Nextra"}),(0,e_.jsx)("span",{className:"nx-ml-2 nx-hidden nx-font-normal nx-text-gray-600 md:nx-inline",children:"The Next Docs Builder"})]}),logoLink:!0,navbar:{component:sH},navigation:!0,nextThemes:{defaultTheme:"system",storageKey:"theme"},notFound:{content:"Submit an issue about broken link →",labels:"bug"},primaryHue:{dark:204,light:212},primarySaturation:{dark:100,light:100},project:{icon:(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)(eP.fy,{}),(0,e_.jsx)("span",{className:"nx-sr-only",children:"GitHub"})]})},search:{component:function({className:ee,directories:en}){let er=sh();return er.flexsearch?(0,e_.jsx)(sL,{className:ee}):(0,e_.jsx)(li,{className:ee,directories:en})},emptyResult:(0,e_.jsx)("span",{className:"nx-block nx-select-none nx-p-8 nx-text-center nx-text-sm nx-text-gray-400",children:"No results found."}),error:"Failed to load search index.",loading:function(){let{locale:ee,defaultLocale:en=lo}=(0,eC.useRouter)(),er=ee&&lh[ee]||lh[en];return(0,e_.jsxs)(e_.Fragment,{children:[er,"…"]})},placeholder:function(){let{locale:ee,defaultLocale:en=lo}=(0,eC.useRouter)(),er=ee&&lp[ee]||lp[en];return`${er}\u2026`}},serverSideError:{content:"Submit an issue about error in url →",labels:"bug"},sidebar:{defaultMenuCollapseLevel:2,titleComponent:({title:ee})=>(0,e_.jsx)(e_.Fragment,{children:ee}),toggleButton:!1},themeSwitch:{component:s9,useOptions(){let{locale:ee}=(0,eC.useRouter)();return"zh-CN"===ee?{dark:"深色主题",light:"浅色主题",system:"系统默认"}:{dark:"Dark",light:"Light",system:"System"}}},toc:{backToTop:!1,component:lr,float:!0,title:"On This Page"},useNextSeoProps:()=>({titleTemplate:"%s – Nextra"})},lx=Object.entries(lm).map(([ee,en])=>{let er=en&&"object"==typeof en&&!Array.isArray(en)&&!(0,eE.isValidElement)(en);if(er)return ee}).filter(Boolean);if(ls){let ee;let en=()=>{document.body.classList.add("resizing"),clearTimeout(ee),ee=setTimeout(()=>{document.body.classList.remove("resizing")},200)};window.addEventListener("resize",en)}function lg(ee){var en=ee,{tag:er,context:ei,children:eo,id:es,className:eu}=en,ec=o3(en,["tag","context","children","id","className"]);let ed=si(),ef=ss(),eh=so(),ep=(0,eE.useRef)(null);return(0,eE.useEffect)(()=>{if(!es)return;let ee=ep.current;if(ee)return ef.set(ee,[es,ei.index+=1]),null==eh||eh.observe(ee),()=>{null==eh||eh.disconnect(),ef.delete(ee),ed(ee=>{let en=o4({},ee);return delete en[es],en})}},[es,ei,ef,eh,ed]),(0,e_.jsxs)(er,o5(o4({className:"sr-only"===eu?"nx-sr-only":(0,ej.Z)("nx-font-semibold nx-tracking-tight nx-text-slate-900 dark:nx-text-slate-100",{h2:"nx-mt-10 nx-border-b nx-pb-1 nx-text-3xl nx-border-neutral-200/70 contrast-more:nx-border-neutral-400 dark:nx-border-primary-100/10 contrast-more:dark:nx-border-neutral-400",h3:"nx-mt-8 nx-text-2xl",h4:"nx-mt-8 nx-text-xl",h5:"nx-mt-8 nx-text-lg",h6:"nx-mt-8 nx-text-base"}[er])},ec),{children:[eo,es&&(0,e_.jsx)("a",{href:`#${es}`,id:es,className:"subheading-anchor","aria-label":"Permalink for this section",ref:ep})]}))}var lv=ee=>{let en=null,er=[];return eE.Children.forEach(ee,(ee,ei)=>{var eo;if(ee&&ee.type===lb){en||(en=ee);return}let es=ee;if(!en&&ee&&"object"==typeof ee&&ee.type!==ly&&"props"in ee&&ee.props){let er=lv(ee.props.children);en=er[0],es=(0,eE.cloneElement)(ee,o5(o4({},ee.props),{children:(null==(eo=er[1])?void 0:eo.length)?er[1]:void 0,key:ei}))}er.push(es)}),[en,er]},ly=ee=>{var en=ee,{children:er,open:ei}=en,eo=o3(en,["children","open"]);let[es,eu]=(0,eE.useState)(!!ei),[ec,ed]=lv(er),[ef,eh]=(0,eE.useState)(es);return(0,eE.useEffect)(()=>{if(es)eh(!0);else{let ee=setTimeout(()=>eh(es),500);return()=>clearTimeout(ee)}},[es]),(0,e_.jsxs)("details",o5(o4(o5(o4({className:"nx-my-4 nx-rounded nx-border nx-border-gray-200 nx-bg-white nx-p-2 nx-shadow-sm first:nx-mt-0 dark:nx-border-neutral-800 dark:nx-bg-neutral-900"},eo),{open:ef}),es&&{"data-expanded":!0}),{children:[(0,e_.jsx)(sg,{value:eu,children:ec}),(0,e_.jsx)(sS,{isOpen:es,children:ed})]}))},lb=ee=>{let en=sx();return(0,e_.jsx)("summary",o5(o4({className:(0,ej.Z)("nx-flex nx-items-center nx-cursor-pointer nx-list-none nx-p-1 nx-transition-colors hover:nx-bg-gray-100 dark:hover:nx-bg-neutral-800","before:nx-mr-1 before:nx-inline-block before:nx-transition-transform before:nx-content-[''] dark:before:nx-invert before:nx-shrink-0","rtl:before:nx-rotate-180 [[data-expanded]>&]:before:nx-rotate-90")},ee),{onClick:ee=>{ee.preventDefault(),en(ee=>!ee)}}))},lk=/https?:\/\//,lw=ee=>{var en=ee,{href:er="",className:ei}=en,eo=o3(en,["href","className"]);return(0,e_.jsx)(sy,o4({href:er,newWindow:lk.test(er),className:(0,ej.Z)("nx-text-primary-600 nx-underline nx-decoration-from-font [text-underline-position:from-font]",ei)},eo))},l_=ee=>{var en=ee,{href:er=""}=en,ei=o3(en,["href"]);return(0,e_.jsx)(sy,o4({href:er,newWindow:lk.test(er)},ei))},lC=({isRawLayout:ee,components:en})=>{if(ee)return{a:l_};let er={index:0};return o4({h1:ee=>(0,e_.jsx)("h1",o4({className:"nx-mt-2 nx-text-4xl nx-font-bold nx-tracking-tight nx-text-slate-900 dark:nx-text-slate-100"},ee)),h2:ee=>(0,e_.jsx)(lg,o4({tag:"h2",context:er},ee)),h3:ee=>(0,e_.jsx)(lg,o4({tag:"h3",context:er},ee)),h4:ee=>(0,e_.jsx)(lg,o4({tag:"h4",context:er},ee)),h5:ee=>(0,e_.jsx)(lg,o4({tag:"h5",context:er},ee)),h6:ee=>(0,e_.jsx)(lg,o4({tag:"h6",context:er},ee)),ul:ee=>(0,e_.jsx)("ul",o4({className:"nx-mt-6 nx-list-disc first:nx-mt-0 ltr:nx-ml-6 rtl:nx-mr-6"},ee)),ol:ee=>(0,e_.jsx)("ol",o4({className:"nx-mt-6 nx-list-decimal first:nx-mt-0 ltr:nx-ml-6 rtl:nx-mr-6"},ee)),li:ee=>(0,e_.jsx)("li",o4({className:"nx-my-2"},ee)),blockquote:ee=>(0,e_.jsx)("blockquote",o4({className:(0,ej.Z)("nx-mt-6 nx-border-gray-300 nx-italic nx-text-gray-700 dark:nx-border-gray-700 dark:nx-text-gray-400","first:nx-mt-0 ltr:nx-border-l-2 ltr:nx-pl-6 rtl:nx-border-r-2 rtl:nx-pr-6")},ee)),hr:ee=>(0,e_.jsx)("hr",o4({className:"nx-my-8 nx-border-neutral-200/70 contrast-more:nx-border-neutral-400 dark:nx-border-primary-100/10 contrast-more:dark:nx-border-neutral-400"},ee)),a:lw,table:ee=>(0,e_.jsx)(oK.iA,o4({className:"nextra-scrollbar nx-mt-6 nx-p-0 first:nx-mt-0"},ee)),p:ee=>(0,e_.jsx)("p",o4({className:"nx-mt-6 nx-leading-7 first:nx-mt-0"},ee)),tr:oK.Tr,th:oK.Th,td:oK.Td,details:ly,summary:lb,pre:oK.SU,code:oK.EK},en)},lE={toc:(0,ej.Z)("nextra-toc nx-order-last nx-hidden nx-w-64 nx-shrink-0 xl:nx-block print:nx-hidden"),main:(0,ej.Z)("nx-w-full nx-break-words")},lj=({themeContext:ee,breadcrumb:en,timestamp:er,navigation:ei,children:eo})=>{var es;let eu=sh(),ec=eS();if("raw"===ee.layout)return(0,e_.jsx)("div",{className:lE.main,children:eo});let ed=ee.timestamp&&eu.gitTimestamp&&er?new Date(er):null,ef=ec&&ed?(0,e_.jsx)("div",{className:"nx-mt-12 nx-mb-8 nx-block nx-text-xs nx-text-gray-500 ltr:nx-text-right rtl:nx-text-left dark:nx-text-gray-400",children:sk(eu.gitTimestamp,{timestamp:ed})}):(0,e_.jsx)("div",{className:"nx-mt-16"}),eh=(0,e_.jsxs)(e_.Fragment,{children:[eo,ef,ei]}),ep=(null==(es=eu.main)?void 0:es.call(eu,{children:eh}))||eh;return"full"===ee.layout?(0,e_.jsx)("article",{className:(0,ej.Z)(lE.main,"nextra-content nx-min-h-[calc(100vh-var(--nextra-navbar-height))] nx-pl-[max(env(safe-area-inset-left),1.5rem)] nx-pr-[max(env(safe-area-inset-right),1.5rem)]"),children:ep}):(0,e_.jsx)("article",{className:(0,ej.Z)(lE.main,"nextra-content nx-flex nx-min-h-[calc(100vh-var(--nextra-navbar-height))] nx-min-w-0 nx-justify-center nx-pb-8 nx-pr-[calc(env(safe-area-inset-right)-1.5rem)]","article"===ee.typesetting&&"nextra-body-typesetting-article"),children:(0,e_.jsxs)("main",{className:"nx-w-full nx-min-w-0 nx-max-w-6xl nx-px-6 nx-pt-4 md:nx-px-12",children:[en,ep]})})},lS=({filePath:ee,pageMap:en,frontMatter:er,headings:ei,timestamp:eo,children:es})=>{let eu=sh(),{locale:ec=lo,defaultLocale:ed}=(0,eC.useRouter)(),ef=eT(),{activeType:eh,activeIndex:ep,activeThemeContext:em,activePath:ex,topLevelNavbarItems:eg,docsDirectories:ev,flatDirectories:ey,flatDocsDirectories:eb,directories:ek}=(0,eE.useMemo)(()=>n0({list:en,locale:ec,defaultLocale:ed,route:ef}),[en,ec,ed,ef]),ew=o4(o4({},em),er),eS=!ew.sidebar||"raw"===ew.layout||"page"===eh,eO="page"!==eh&&ew.toc&&"default"===ew.layout?(0,e_.jsx)("nav",{className:(0,ej.Z)(lE.toc,"nx-px-4"),"aria-label":"table of contents",children:sk(eu.toc.component,{headings:eu.toc.float?ei:[],filePath:ee})}):"full"!==ew.layout&&"raw"!==ew.layout&&(0,e_.jsx)("nav",{className:lE.toc,"aria-label":"table of contents"}),eM=eu.i18n.find(ee=>ee.locale===ec),eP=eM?"rtl"===eM.direction:"rtl"===eu.direction,eI=eP?"rtl":"ltr";return(0,e_.jsxs)("div",{dir:eI,children:[(0,e_.jsx)("script",{dangerouslySetInnerHTML:{__html:`document.documentElement.setAttribute('dir','${eI}')`}}),(0,e_.jsx)(s$,{}),(0,e_.jsx)(sE,{}),ew.navbar&&sk(eu.navbar.component,{flatDirectories:ey,items:eg}),(0,e_.jsx)("div",{className:(0,ej.Z)("nx-mx-auto nx-flex","raw"!==ew.layout&&"nx-max-w-[90rem]"),children:(0,e_.jsxs)(sl,{children:[(0,e_.jsx)(s4,{docsDirectories:ev,flatDirectories:ey,fullDirectories:ek,headings:ei,asPopover:eS,includePlaceholder:"default"===ew.layout}),eO,(0,e_.jsx)(s7,{}),(0,e_.jsx)(lj,{themeContext:ew,breadcrumb:"page"!==eh&&ew.breadcrumb?(0,e_.jsx)(sj,{activePath:ex}):null,timestamp:eo,navigation:"page"!==eh&&ew.pagination?(0,e_.jsx)(sU,{flatDirectories:eb,currentIndex:ep}):null,children:(0,e_.jsx)(eN.Z,{components:lC({isRawLayout:"raw"===ew.layout,components:eu.components}),children:es})})]})}),ew.footer&&sk(eu.footer.component,{menu:eS})]})};function lO(ee){var en=ee,{children:er}=en,ei=o3(en,["children"]);return(0,e_.jsx)(sp,{value:ei,children:(0,e_.jsx)(lS,o5(o4({},ei.pageOpts),{children:er}))})}function lM(){let{asPath:ee}=(0,eC.useRouter)(),{frontMatter:en,title:er}=sh(),ei="https://overextended.dev".concat(ee),eo=en.description||"Documentation for Overextended's resources for FiveM/RedM";return(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1.0"}),(0,e_.jsx)("link",{rel:"icon",type:"image/x-icon",href:"/static/ox.ico"}),(0,e_.jsx)("meta",{httpEquiv:"Content-Language",content:"en"}),(0,e_.jsx)("meta",{name:"description",content:eo}),(0,e_.jsx)("meta",{name:"og:title",content:er}),(0,e_.jsx)("meta",{name:"og:description",content:eo}),(0,e_.jsx)("meta",{name:"og:url",content:ei})]})}function lT(){let{asPath:ee}=(0,eC.useRouter)(),en=ee.replace(/[-_]/g," ").split("/"),er="#"!==en[1][0]&&en[1]||"Overextended",ei=en[en.length-1],eo=/[a-z]/.test(ei)&&/[A-Z]/.test(ei)?ei:"%s";return{titleTemplate:"".concat(eo," - ").concat(ei===er?"Documentation":er.replace(/(^\w|\s\w)/g,ee=>ee.toUpperCase()))}}let lN={logo:(0,e_.jsx)("div",{style:{paddingLeft:"50px",lineHeight:"38px",background:"url('https://avatars.githubusercontent.com/u/88127058?s=38') no-repeat left",backgroundSize:"38px",fontWeight:550},children:"Overextended"}),project:{link:"https://github.com/overextended/overextended.github.io"},chat:{link:"https://discord.overextended.dev"},docsRepositoryBase:"https://github.com/overextended/overextended.github.io/blob/main",footer:{text:"Overextended"},head:lM,primaryHue:{dark:200,light:200},sidebar:{defaultMenuCollapseLevel:1},useNextSeoProps:lT};var lP=lN;er(7771),er(1803);let lI=function(ee){let{Component:en,pageProps:er}=ee;return(0,e_.jsx)(en,{...er})},lR=[];function lA(ee){return(0,e_.jsx)(e_.Fragment,{})}var lL=function(){let ee=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,e_.jsx)(lI,{...ee,children:(0,e_.jsx)(lA,{...ee})})};let lF=(ek=globalThis)[ew=Symbol.for("__nextra_internal__")]||(ek[ew]=Object.create(null));lF.Layout=lO,lF.pageMap=[{kind:"Meta",data:{index:"Introduction",guides:"Guides",oxmysql:"OxMySQL",ox_lib:"Ox Lib",creator_codes:{title:"Creator codes",type:"page",href:"https://overextended.dev/#creator-codes"},support:{title:"Support us",type:"page",href:"https://overextended.dev/#support-our-team"},ox_core:"Ox Core",ox_doorlock:"Ox Doorlock",ox_fuel:"Ox Fuel",ox_inventory:"Ox Inventory",ox_target:"Ox Target"}},{kind:"Folder",name:"guides",route:"/guides",children:[{kind:"MdxPage",name:"git",route:"/guides/git"},{kind:"MdxPage",name:"nodejs",route:"/guides/nodejs",frontMatter:{title:"Node.js"}},{kind:"MdxPage",name:"pnpm",route:"/guides/pnpm",frontMatter:{title:"pnpm"}},{kind:"MdxPage",name:"types",route:"/guides/types"},{kind:"MdxPage",name:"vscode",route:"/guides/vscode",frontMatter:{title:"VS Code"}},{kind:"Meta",data:{git:"Git",nodejs:"Node.js",pnpm:"pnpm",types:"Types",vscode:"VS Code"}}]},{kind:"MdxPage",name:"index",route:"/",frontMatter:{title:"Introduction"}},{kind:"Folder",name:"ox_core",route:"/ox_core",children:[{kind:"Folder",name:"Client",route:"/ox_core/Client",children:[{kind:"Folder",name:"Player",route:"/ox_core/Client/Player",children:[{kind:"MdxPage",name:"callbacks",route:"/ox_core/Client/Player/callbacks",frontMatter:{title:"Callbacks"}},{kind:"MdxPage",name:"events",route:"/ox_core/Client/Player/events",frontMatter:{title:"Events"}},{kind:"Meta",data:{callbacks:"Callbacks",events:"Events"}}]},{kind:"MdxPage",name:"Player",route:"/ox_core/Client/Player"},{kind:"MdxPage",name:"functions",route:"/ox_core/Client/functions"},{kind:"Meta",data:{functions:"Functions",Player:"Player"}}]},{kind:"Folder",name:"Server",route:"/ox_core/Server",children:[{kind:"Folder",name:"Player",route:"/ox_core/Server/Player",children:[{kind:"MdxPage",name:"events",route:"/ox_core/Server/Player/events",frontMatter:{title:"Events"}},{kind:"MdxPage",name:"methods",route:"/ox_core/Server/Player/methods",frontMatter:{title:"Methods"}},{kind:"Meta",data:{events:"Events",methods:"Methods"}}]},{kind:"MdxPage",name:"Player",route:"/ox_core/Server/Player"},{kind:"Folder",name:"Vehicle",route:"/ox_core/Server/Vehicle",children:[{kind:"MdxPage",name:"callbacks",route:"/ox_core/Server/Vehicle/callbacks",frontMatter:{title:"Callbacks"}},{kind:"MdxPage",name:"methods",route:"/ox_core/Server/Vehicle/methods",frontMatter:{title:"Methods"}},{kind:"Meta",data:{callbacks:"Callbacks",methods:"Methods"}}]},{kind:"MdxPage",name:"Vehicle",route:"/ox_core/Server/Vehicle",frontMatter:{title:"Server",sidebar_position:1}},{kind:"MdxPage",name:"functions",route:"/ox_core/Server/functions"},{kind:"Meta",data:{functions:"Functions",Player:"Player",Vehicle:"Server"}}]},{kind:"MdxPage",name:"concepts",route:"/ox_core/concepts"},{kind:"Meta",data:{concepts:"Concepts"}}]},{kind:"MdxPage",name:"ox_core",route:"/ox_core"},{kind:"Folder",name:"ox_doorlock",route:"/ox_doorlock",children:[{kind:"Folder",name:"Client",route:"/ox_doorlock/Client",children:[{kind:"MdxPage",name:"functions",route:"/ox_doorlock/Client/functions"},{kind:"Meta",data:{functions:"Functions"}}]},{kind:"Folder",name:"Server",route:"/ox_doorlock/Server",children:[{kind:"MdxPage",name:"events",route:"/ox_doorlock/Server/events"},{kind:"MdxPage",name:"functions",route:"/ox_doorlock/Server/functions"},{kind:"Meta",data:{events:"Events",functions:"Functions"}}]},{kind:"MdxPage",name:"settings",route:"/ox_doorlock/settings",frontMatter:{title:"Door Settings"}},{kind:"Meta",data:{settings:"Door Settings"}}]},{kind:"MdxPage",name:"ox_doorlock",route:"/ox_doorlock"},{kind:"Folder",name:"ox_fuel",route:"/ox_fuel",children:[{kind:"Folder",name:"Client",route:"/ox_fuel/Client",children:[{kind:"MdxPage",name:"functions",route:"/ox_fuel/Client/functions"},{kind:"Meta",data:{functions:"Functions"}}]},{kind:"Folder",name:"Server",route:"/ox_fuel/Server",children:[{kind:"MdxPage",name:"functions",route:"/ox_fuel/Server/functions"},{kind:"Meta",data:{functions:"Functions"}}]},{kind:"MdxPage",name:"Shared",route:"/ox_fuel/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"MdxPage",name:"ox_fuel",route:"/ox_fuel"},{kind:"Folder",name:"ox_inventory",route:"/ox_inventory",children:[{kind:"Folder",name:"Events",route:"/ox_inventory/Events",children:[{kind:"MdxPage",name:"Client",route:"/ox_inventory/Events/Client"},{kind:"MdxPage",name:"Server",route:"/ox_inventory/Events/Server"},{kind:"Meta",data:{Client:"Client",Server:"Server"}}]},{kind:"Folder",name:"Frameworks",route:"/ox_inventory/Frameworks",children:[{kind:"MdxPage",name:"esx",route:"/ox_inventory/Frameworks/esx",frontMatter:{title:"ESX"}},{kind:"MdxPage",name:"qb",route:"/ox_inventory/Frameworks/qb",frontMatter:{title:"QBCore"}},{kind:"Meta",data:{esx:"ESX",qb:"QBCore"}}]},{kind:"Folder",name:"Functions",route:"/ox_inventory/Functions",children:[{kind:"MdxPage",name:"Client",route:"/ox_inventory/Functions/Client"},{kind:"Folder",name:"Server",route:"/ox_inventory/Functions/Server",children:[{kind:"MdxPage",name:"Hooks",route:"/ox_inventory/Functions/Server/Hooks"},{kind:"Meta",data:{Hooks:"Hooks"}}]},{kind:"MdxPage",name:"Server",route:"/ox_inventory/Functions/Server"},{kind:"Meta",data:{Client:"Client",Server:"Server"}}]},{kind:"Folder",name:"Guides",route:"/ox_inventory/Guides",children:[{kind:"MdxPage",name:"crafting",route:"/ox_inventory/Guides/crafting",frontMatter:{title:"Crafting"}},{kind:"MdxPage",name:"creatingItems",route:"/ox_inventory/Guides/creatingItems",frontMatter:{title:"Creating Items"}},{kind:"MdxPage",name:"metadata",route:"/ox_inventory/Guides/metadata",frontMatter:{title:"Metadata"}},{kind:"MdxPage",name:"shops",route:"/ox_inventory/Guides/shops",frontMatter:{title:"Creating Shops"}},{kind:"MdxPage",name:"stashes",route:"/ox_inventory/Guides/stashes",frontMatter:{title:"Custom Stashes"}},{kind:"Meta",data:{crafting:"Crafting",creatingItems:"Creating Items",shops:"Creating Shops",stashes:"Custom Stashes",metadata:"Metadata"}}]},{kind:"MdxPage",name:"issues",route:"/ox_inventory/issues",frontMatter:{title:"Common Issues"}},{kind:"Meta",data:{issues:"Common Issues"}}]},{kind:"MdxPage",name:"ox_inventory",route:"/ox_inventory"},{kind:"Folder",name:"ox_lib",route:"/ox_lib",children:[{kind:"Folder",name:"Modules",route:"/ox_lib/Modules",children:[{kind:"Folder",name:"ACL",route:"/ox_lib/Modules/ACL",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/ACL/Server"},{kind:"Meta",data:{Server:"Server"}}]},{kind:"Folder",name:"AddCommand",route:"/ox_lib/Modules/AddCommand",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/AddCommand/Server"},{kind:"Meta",data:{Server:"Server"}}]},{kind:"Folder",name:"AddKeybind",route:"/ox_lib/Modules/AddKeybind",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/AddKeybind/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Cache",route:"/ox_lib/Modules/Cache",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Cache/Client"},{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Cache/Shared"},{kind:"Meta",data:{Client:"Client",Shared:"Shared"}}]},{kind:"Folder",name:"Callback",route:"/ox_lib/Modules/Callback",children:[{kind:"Folder",name:"JavaScript",route:"/ox_lib/Modules/Callback/JavaScript",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Callback/JavaScript/Client"},{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Callback/JavaScript/Server"},{kind:"Meta",data:{Client:"Client",Server:"Server"}}]},{kind:"Folder",name:"Lua",route:"/ox_lib/Modules/Callback/Lua",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Callback/Lua/Client"},{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Callback/Lua/Server"},{kind:"Meta",data:{Client:"Client",Server:"Server"}}]}]},{kind:"Folder",name:"Class",route:"/ox_lib/Modules/Class",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Class/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Cron",route:"/ox_lib/Modules/Cron",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Cron/Server"},{kind:"Meta",data:{Server:"Server"}}]},{kind:"Folder",name:"DisableControls",route:"/ox_lib/Modules/DisableControls",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/DisableControls/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"GetClosestObject",route:"/ox_lib/Modules/GetClosestObject",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetClosestObject/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetClosestPed",route:"/ox_lib/Modules/GetClosestPed",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetClosestPed/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetClosestPlayer",route:"/ox_lib/Modules/GetClosestPlayer",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetClosestPlayer/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetClosestVehicle",route:"/ox_lib/Modules/GetClosestVehicle",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetClosestVehicle/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetNearbyObjects",route:"/ox_lib/Modules/GetNearbyObjects",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetNearbyObjects/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetNearbyPeds",route:"/ox_lib/Modules/GetNearbyPeds",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetNearbyPeds/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetNearbyPlayers",route:"/ox_lib/Modules/GetNearbyPlayers",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetNearbyPlayers/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetNearbyVehicles",route:"/ox_lib/Modules/GetNearbyVehicles",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetNearbyVehicles/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Interface",route:"/ox_lib/Modules/Interface",children:[{kind:"Folder",name:"Client",route:"/ox_lib/Modules/Interface/Client",children:[{kind:"MdxPage",name:"alert",route:"/ox_lib/Modules/Interface/Client/alert",frontMatter:{title:"Alert Dialog"}},{kind:"MdxPage",name:"clipboard",route:"/ox_lib/Modules/Interface/Client/clipboard",frontMatter:{title:"Clipboard"}},{kind:"MdxPage",name:"context",route:"/ox_lib/Modules/Interface/Client/context",frontMatter:{title:"Context Menu"}},{kind:"MdxPage",name:"input",route:"/ox_lib/Modules/Interface/Client/input",frontMatter:{title:"Input Dialog"}},{kind:"MdxPage",name:"menu",route:"/ox_lib/Modules/Interface/Client/menu",frontMatter:{title:"Menu"}},{kind:"MdxPage",name:"notify",route:"/ox_lib/Modules/Interface/Client/notify",frontMatter:{title:"Notifications"}},{kind:"MdxPage",name:"progress",route:"/ox_lib/Modules/Interface/Client/progress",frontMatter:{title:"Progress"}},{kind:"MdxPage",name:"radial",route:"/ox_lib/Modules/Interface/Client/radial",frontMatter:{title:"Radial Menu"}},{kind:"MdxPage",name:"skillcheck",route:"/ox_lib/Modules/Interface/Client/skillcheck",frontMatter:{title:"Skill Check"}},{kind:"MdxPage",name:"textui",route:"/ox_lib/Modules/Interface/Client/textui",frontMatter:{title:"TextUI"}},{kind:"Meta",data:{alert:"Alert Dialog",clipboard:"Clipboard",context:"Context Menu",input:"Input Dialog",menu:"Menu",notify:"Notifications",progress:"Progress",radial:"Radial Menu",skillcheck:"Skill Check",textui:"TextUI"}}]}]},{kind:"MdxPage",name:"Interface",route:"/ox_lib/Modules/Interface",frontMatter:{title:"Interface"}},{kind:"Folder",name:"Locale",route:"/ox_lib/Modules/Locale",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Locale/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Logger",route:"/ox_lib/Modules/Logger",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Logger/Server"},{kind:"Meta",data:{Server:"Server"}}]},{kind:"Folder",name:"Math",route:"/ox_lib/Modules/Math",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Math/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Points",route:"/ox_lib/Modules/Points",children:[{kind:"Folder",name:"JavaScript",route:"/ox_lib/Modules/Points/JavaScript",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Points/JavaScript/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Lua",route:"/ox_lib/Modules/Points/Lua",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Points/Lua/Client"},{kind:"Meta",data:{Client:"Client"}}]}]},{kind:"Folder",name:"Print",route:"/ox_lib/Modules/Print",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Print/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Raycast",route:"/ox_lib/Modules/Raycast",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Raycast/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Require",route:"/ox_lib/Modules/Require",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Require/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Streaming",route:"/ox_lib/Modules/Streaming",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Streaming/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"String",route:"/ox_lib/Modules/String",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/String/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Table",route:"/ox_lib/Modules/Table",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Table/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"VehicleProperties",route:"/ox_lib/Modules/VehicleProperties",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/VehicleProperties/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Version",route:"/ox_lib/Modules/Version",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Version/Server"},{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Version/Shared"},{kind:"Meta",data:{Server:"Server",Shared:"Shared"}}]},{kind:"Folder",name:"WaitFor",route:"/ox_lib/Modules/WaitFor",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/WaitFor/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Zones",route:"/ox_lib/Modules/Zones",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Zones/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Meta",data:{Interface:"Interface"}}]}]},{kind:"MdxPage",name:"ox_lib",route:"/ox_lib"},{kind:"Folder",name:"ox_target",route:"/ox_target",children:[{kind:"Folder",name:"Functions",route:"/ox_target/Functions",children:[{kind:"MdxPage",name:"Client",route:"/ox_target/Functions/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"MdxPage",name:"Options",route:"/ox_target/Options"},{kind:"Meta",data:{Options:"Options"}}]},{kind:"MdxPage",name:"ox_target",route:"/ox_target"},{kind:"Folder",name:"oxmysql",route:"/oxmysql",children:[{kind:"Folder",name:"Functions",route:"/oxmysql/Functions",children:[{kind:"MdxPage",name:"insert",route:"/oxmysql/Functions/insert",frontMatter:{title:"insert"}},{kind:"MdxPage",name:"prepare",route:"/oxmysql/Functions/prepare",frontMatter:{title:"prepare"}},{kind:"MdxPage",name:"query",route:"/oxmysql/Functions/query",frontMatter:{title:"query"}},{kind:"MdxPage",name:"rawExecute",route:"/oxmysql/Functions/rawExecute",frontMatter:{title:"rawExecute"}},{kind:"MdxPage",name:"scalar",route:"/oxmysql/Functions/scalar",frontMatter:{title:"scalar"}},{kind:"MdxPage",name:"single",route:"/oxmysql/Functions/single",frontMatter:{title:"single"}},{kind:"MdxPage",name:"transaction",route:"/oxmysql/Functions/transaction",frontMatter:{title:"transaction"}},{kind:"MdxPage",name:"update",route:"/oxmysql/Functions/update",frontMatter:{title:"update"}},{kind:"Meta",data:{insert:"insert",prepare:"prepare",query:"query",rawExecute:"rawExecute",scalar:"scalar",single:"single",transaction:"transaction",update:"update"}}]},{kind:"MdxPage",name:"benchmark",route:"/oxmysql/benchmark"},{kind:"MdxPage",name:"issues",route:"/oxmysql/issues",frontMatter:{title:"Common Issues"}},{kind:"MdxPage",name:"placeholders",route:"/oxmysql/placeholders"},{kind:"MdxPage",name:"ui",route:"/oxmysql/ui",frontMatter:{title:"Using the Debug UI"}},{kind:"Meta",data:{benchmark:"Benchmark",issues:"Common Issues",placeholders:"Placeholders",ui:"Using the Debug UI"}}]},{kind:"MdxPage",name:"oxmysql",route:"/oxmysql",frontMatter:{title:"OxMySQL"}}],lF.flexsearch={codeblocks:!0},lF.themeConfig=lP},7521:function(ee,en){"use strict";var er;Object.defineProperty(en,"__esModule",{value:!0}),function(ee,en){for(var er in en)Object.defineProperty(ee,er,{enumerable:!0,get:en[er]})}(en,{PrefetchKind:function(){return er},ACTION_REFRESH:function(){return ei},ACTION_NAVIGATE:function(){return eo},ACTION_RESTORE:function(){return es},ACTION_SERVER_PATCH:function(){return eu},ACTION_PREFETCH:function(){return ec},ACTION_FAST_REFRESH:function(){return ed},ACTION_SERVER_ACTION:function(){return ef}});let ei="refresh",eo="navigate",es="restore",eu="server-patch",ec="prefetch",ed="fast-refresh",ef="server-action";!function(ee){ee.AUTO="auto",ee.FULL="full",ee.TEMPORARY="temporary"}(er||(er={})),("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},1726:function(ee,en,er){"use strict";function ei(ee,en,er,ei){return!1}Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"getDomainLocale",{enumerable:!0,get:function(){return ei}}),er(6925),("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},759:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"Image",{enumerable:!0,get:function(){return ek}});let ei=er(1351),eo=er(5815),es=eo._(er(959)),eu=ei._(er(422)),ec=ei._(er(457)),ed=er(8009),ef=er(9327),eh=er(4514);er(5393);let ep=er(4621),em=ei._(er(2685)),ex={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!0};function eg(ee,en,er,ei,eo,es){let eu=null==ee?void 0:ee.src;if(!ee||ee["data-loaded-src"]===eu)return;ee["data-loaded-src"]=eu;let ec="decode"in ee?ee.decode():Promise.resolve();ec.catch(()=>{}).then(()=>{if(ee.parentElement&&ee.isConnected){if("empty"!==en&&eo(!0),null==er?void 0:er.current){let en=new Event("load");Object.defineProperty(en,"target",{writable:!1,value:ee});let ei=!1,eo=!1;er.current({...en,nativeEvent:en,currentTarget:ee,target:ee,isDefaultPrevented:()=>ei,isPropagationStopped:()=>eo,persist:()=>{},preventDefault:()=>{ei=!0,en.preventDefault()},stopPropagation:()=>{eo=!0,en.stopPropagation()}})}(null==ei?void 0:ei.current)&&ei.current(ee)}})}function ev(ee){let[en,er]=es.version.split("."),ei=parseInt(en,10),eo=parseInt(er,10);return ei>18||18===ei&&eo>=3?{fetchPriority:ee}:{fetchpriority:ee}}let ey=(0,es.forwardRef)((ee,en)=>{let{src:er,srcSet:ei,sizes:eo,height:eu,width:ec,decoding:ed,className:ef,style:eh,fetchPriority:ep,placeholder:em,loading:ex,unoptimized:ey,fill:eb,onLoadRef:ek,onLoadingCompleteRef:ew,setBlurComplete:e_,setShowAltText:eC,onLoad:eE,onError:ej,...eS}=ee;return es.default.createElement("img",{...eS,...ev(ep),loading:ex,width:ec,height:eu,decoding:ed,"data-nimg":eb?"fill":"1",className:ef,style:eh,sizes:eo,srcSet:ei,src:er,ref:(0,es.useCallback)(ee=>{en&&("function"==typeof en?en(ee):"object"==typeof en&&(en.current=ee)),ee&&(ej&&(ee.src=ee.src),ee.complete&&eg(ee,em,ek,ew,e_,ey))},[er,em,ek,ew,e_,ej,ey,en]),onLoad:ee=>{let en=ee.currentTarget;eg(en,em,ek,ew,e_,ey)},onError:ee=>{eC(!0),"empty"!==em&&e_(!0),ej&&ej(ee)}})});function eb(ee){let{isAppRouter:en,imgAttributes:er}=ee,ei={as:"image",imageSrcSet:er.srcSet,imageSizes:er.sizes,crossOrigin:er.crossOrigin,referrerPolicy:er.referrerPolicy,...ev(er.fetchPriority)};return en&&eu.default.preload?(eu.default.preload(er.src,ei),null):es.default.createElement(ec.default,null,es.default.createElement("link",{key:"__nimg-"+er.src+er.srcSet+er.sizes,rel:"preload",href:er.srcSet?void 0:er.src,...ei}))}let ek=(0,es.forwardRef)((ee,en)=>{let er=(0,es.useContext)(ep.RouterContext),ei=!er,eo=(0,es.useContext)(eh.ImageConfigContext),eu=(0,es.useMemo)(()=>{let ee=ex||eo||ef.imageConfigDefault,en=[...ee.deviceSizes,...ee.imageSizes].sort((ee,en)=>ee-en),er=ee.deviceSizes.sort((ee,en)=>ee-en);return{...ee,allSizes:en,deviceSizes:er}},[eo]),{onLoad:ec,onLoadingComplete:eg}=ee,ev=(0,es.useRef)(ec);(0,es.useEffect)(()=>{ev.current=ec},[ec]);let ek=(0,es.useRef)(eg);(0,es.useEffect)(()=>{ek.current=eg},[eg]);let[ew,e_]=(0,es.useState)(!1),[eC,eE]=(0,es.useState)(!1),{props:ej,meta:eS}=(0,ed.getImgProps)(ee,{defaultLoader:em.default,imgConf:eu,blurComplete:ew,showAltText:eC});return es.default.createElement(es.default.Fragment,null,es.default.createElement(ey,{...ej,unoptimized:eS.unoptimized,placeholder:eS.placeholder,fill:eS.fill,onLoadRef:ev,onLoadingCompleteRef:ek,setBlurComplete:e_,setShowAltText:eE,ref:en}),eS.priority?es.default.createElement(eb,{isAppRouter:ei,imgAttributes:ej}):null)});("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},7864:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"default",{enumerable:!0,get:function(){return eE}});let ei=er(1351),eo=ei._(er(959)),es=er(3578),eu=er(7462),ec=er(1541),ed=er(9249),ef=er(8565),eh=er(4621),ep=er(5444),em=er(3986),ex=er(1726),eg=er(983),ev=er(7521),ey=new Set;function eb(ee,en,er,ei,eo,es){if(!es&&!(0,eu.isLocalURL)(en))return;if(!ei.bypassPrefetchedCheck){let eo=void 0!==ei.locale?ei.locale:"locale"in ee?ee.locale:void 0,es=en+"%"+er+"%"+eo;if(ey.has(es))return;ey.add(es)}let ec=es?ee.prefetch(en,eo):ee.prefetch(en,er,ei);Promise.resolve(ec).catch(ee=>{})}function ek(ee){let en=ee.currentTarget,er=en.getAttribute("target");return er&&"_self"!==er||ee.metaKey||ee.ctrlKey||ee.shiftKey||ee.altKey||ee.nativeEvent&&2===ee.nativeEvent.which}function ew(ee,en,er,ei,es,ec,ed,ef,eh,ep){let{nodeName:em}=ee.currentTarget,ex="A"===em.toUpperCase();if(ex&&(ek(ee)||!eh&&!(0,eu.isLocalURL)(er)))return;ee.preventDefault();let eg=()=>{let ee=null==ed||ed;"beforePopState"in en?en[es?"replace":"push"](er,ei,{shallow:ec,locale:ef,scroll:ee}):en[es?"replace":"push"](ei||er,{forceOptimisticNavigation:!ep,scroll:ee})};eh?eo.default.startTransition(eg):eg()}function e_(ee){return"string"==typeof ee?ee:(0,ec.formatUrl)(ee)}let eC=eo.default.forwardRef(function(ee,en){let er,ei;let{href:eu,as:ec,children:ey,prefetch:ek=null,passHref:eC,replace:eE,shallow:ej,scroll:eS,locale:eO,onClick:eM,onMouseEnter:eT,onTouchStart:eN,legacyBehavior:eP=!1,...eI}=ee;er=ey,eP&&("string"==typeof er||"number"==typeof er)&&(er=eo.default.createElement("a",null,er));let eR=eo.default.useContext(eh.RouterContext),eA=eo.default.useContext(ep.AppRouterContext),eL=null!=eR?eR:eA,eF=!eR,eZ=!1!==ek,eD=null===ek?ev.PrefetchKind.AUTO:ev.PrefetchKind.FULL,{href:ez,as:e$}=eo.default.useMemo(()=>{if(!eR){let ee=e_(eu);return{href:ee,as:ec?e_(ec):ee}}let[ee,en]=(0,es.resolveHref)(eR,eu,!0);return{href:ee,as:ec?(0,es.resolveHref)(eR,ec):en||ee}},[eR,eu,ec]),eG=eo.default.useRef(ez),eU=eo.default.useRef(e$);eP&&(ei=eo.default.Children.only(er));let eW=eP?ei&&"object"==typeof ei&&ei.ref:en,[eV,eH,eB]=(0,em.useIntersection)({rootMargin:"200px"}),eq=eo.default.useCallback(ee=>{(eU.current!==e$||eG.current!==ez)&&(eB(),eU.current=e$,eG.current=ez),eV(ee),eW&&("function"==typeof eW?eW(ee):"object"==typeof eW&&(eW.current=ee))},[e$,eW,ez,eB,eV]);eo.default.useEffect(()=>{eL&&eH&&eZ&&eb(eL,ez,e$,{locale:eO},{kind:eD},eF)},[e$,ez,eH,eO,eZ,null==eR?void 0:eR.locale,eL,eF,eD]);let eK={ref:eq,onClick(ee){eP||"function"!=typeof eM||eM(ee),eP&&ei.props&&"function"==typeof ei.props.onClick&&ei.props.onClick(ee),eL&&!ee.defaultPrevented&&ew(ee,eL,ez,e$,eE,ej,eS,eO,eF,eZ)},onMouseEnter(ee){eP||"function"!=typeof eT||eT(ee),eP&&ei.props&&"function"==typeof ei.props.onMouseEnter&&ei.props.onMouseEnter(ee),eL&&(eZ||!eF)&&eb(eL,ez,e$,{locale:eO,priority:!0,bypassPrefetchedCheck:!0},{kind:eD},eF)},onTouchStart(ee){eP||"function"!=typeof eN||eN(ee),eP&&ei.props&&"function"==typeof ei.props.onTouchStart&&ei.props.onTouchStart(ee),eL&&(eZ||!eF)&&eb(eL,ez,e$,{locale:eO,priority:!0,bypassPrefetchedCheck:!0},{kind:eD},eF)}};if((0,ed.isAbsoluteUrl)(e$))eK.href=e$;else if(!eP||eC||"a"===ei.type&&!("href"in ei.props)){let ee=void 0!==eO?eO:null==eR?void 0:eR.locale,en=(null==eR?void 0:eR.isLocaleDomain)&&(0,ex.getDomainLocale)(e$,ee,null==eR?void 0:eR.locales,null==eR?void 0:eR.domainLocales);eK.href=en||(0,eg.addBasePath)((0,ef.addLocale)(e$,ee,null==eR?void 0:eR.defaultLocale))}return eP?eo.default.cloneElement(ei,eK):eo.default.createElement("a",{...eI,...eK},er)}),eE=eC;("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},3986:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"useIntersection",{enumerable:!0,get:function(){return eh}});let ei=er(959),eo=er(2097),es="function"==typeof IntersectionObserver,eu=new Map,ec=[];function ed(ee){let en;let er={root:ee.root||null,margin:ee.rootMargin||""},ei=ec.find(ee=>ee.root===er.root&&ee.margin===er.margin);if(ei&&(en=eu.get(ei)))return en;let eo=new Map,es=new IntersectionObserver(ee=>{ee.forEach(ee=>{let en=eo.get(ee.target),er=ee.isIntersecting||ee.intersectionRatio>0;en&&er&&en(er)})},ee);return en={id:er,observer:es,elements:eo},ec.push(er),eu.set(er,en),en}function ef(ee,en,er){let{id:ei,observer:eo,elements:es}=ed(er);return es.set(ee,en),eo.observe(ee),function(){if(es.delete(ee),eo.unobserve(ee),0===es.size){eo.disconnect(),eu.delete(ei);let ee=ec.findIndex(ee=>ee.root===ei.root&&ee.margin===ei.margin);ee>-1&&ec.splice(ee,1)}}}function eh(ee){let{rootRef:en,rootMargin:er,disabled:eu}=ee,ec=eu||!es,[ed,eh]=(0,ei.useState)(!1),ep=(0,ei.useRef)(null),em=(0,ei.useCallback)(ee=>{ep.current=ee},[]);(0,ei.useEffect)(()=>{if(es){if(ec||ed)return;let ee=ep.current;if(ee&&ee.tagName){let ei=ef(ee,ee=>ee&&eh(ee),{root:null==en?void 0:en.current,rootMargin:er});return ei}}else if(!ed){let ee=(0,eo.requestIdleCallback)(()=>eh(!0));return()=>(0,eo.cancelIdleCallback)(ee)}},[ec,er,en,ed,ep.current]);let ex=(0,ei.useCallback)(()=>{eh(!1)},[]);return[em,ed,ex]}("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},8009:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"getImgProps",{enumerable:!0,get:function(){return ep}}),er(5393);let ei=er(8755),eo=er(9327);function es(ee){return void 0!==ee.default}function eu(ee){return void 0!==ee.src}function ec(ee){return"object"==typeof ee&&(es(ee)||eu(ee))}function ed(ee){return void 0===ee?ee:"number"==typeof ee?Number.isFinite(ee)?ee:NaN:"string"==typeof ee&&/^[0-9]+$/.test(ee)?parseInt(ee,10):NaN}function ef(ee,en,er){let{deviceSizes:ei,allSizes:eo}=ee;if(er){let ee=/(^|\s)(1?\d?\d)vw/g,en=[];for(let ei;ei=ee.exec(er);ei)en.push(parseInt(ei[2]));if(en.length){let ee=.01*Math.min(...en);return{widths:eo.filter(en=>en>=ei[0]*ee),kind:"w"}}return{widths:eo,kind:"w"}}if("number"!=typeof en)return{widths:ei,kind:"w"};let es=[...new Set([en,2*en].map(ee=>eo.find(en=>en>=ee)||eo[eo.length-1]))];return{widths:es,kind:"x"}}function eh(ee){let{config:en,src:er,unoptimized:ei,width:eo,quality:es,sizes:eu,loader:ec}=ee;if(ei)return{src:er,srcSet:void 0,sizes:void 0};let{widths:ed,kind:eh}=ef(en,eo,eu),ep=ed.length-1;return{sizes:eu||"w"!==eh?eu:"100vw",srcSet:ed.map((ee,ei)=>ec({config:en,src:er,quality:es,width:ee})+" "+("w"===eh?ee:ei+1)+eh).join(", "),src:ec({config:en,src:er,quality:es,width:ed[ep]})}}function ep(ee,en){let er,eu,ef,{src:ep,sizes:em,unoptimized:ex=!1,priority:eg=!1,loading:ev,className:ey,quality:eb,width:ek,height:ew,fill:e_=!1,style:eC,onLoad:eE,onLoadingComplete:ej,placeholder:eS="empty",blurDataURL:eO,fetchPriority:eM,layout:eT,objectFit:eN,objectPosition:eP,lazyBoundary:eI,lazyRoot:eR,...eA}=ee,{imgConf:eL,showAltText:eF,blurComplete:eZ,defaultLoader:eD}=en,ez=eL||eo.imageConfigDefault;if("allSizes"in ez)er=ez;else{let ee=[...ez.deviceSizes,...ez.imageSizes].sort((ee,en)=>ee-en),en=ez.deviceSizes.sort((ee,en)=>ee-en);er={...ez,allSizes:ee,deviceSizes:en}}let e$=eA.loader||eD;delete eA.loader,delete eA.srcSet;let eG="__next_img_default"in e$;if(eG){if("custom"===er.loader)throw Error('Image with src "'+ep+'" is missing "loader" prop.\nRead more: https://nextjs.org/docs/messages/next-image-missing-loader')}else{let ee=e$;e$=en=>{let{config:er,...ei}=en;return ee(ei)}}if(eT){"fill"===eT&&(e_=!0);let ee={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}},en={responsive:"100vw",fill:"100vw"},er=ee[eT];er&&(eC={...eC,...er});let ei=en[eT];ei&&!em&&(em=ei)}let eU="",eW=ed(ek),eV=ed(ew);if(ec(ep)){let ee=es(ep)?ep.default:ep;if(!ee.src)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received "+JSON.stringify(ee));if(!ee.height||!ee.width)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received "+JSON.stringify(ee));if(eu=ee.blurWidth,ef=ee.blurHeight,eO=eO||ee.blurDataURL,eU=ee.src,!e_){if(eW||eV){if(eW&&!eV){let en=eW/ee.width;eV=Math.round(ee.height*en)}else if(!eW&&eV){let en=eV/ee.height;eW=Math.round(ee.width*en)}}else eW=ee.width,eV=ee.height}}let eH=!eg&&("lazy"===ev||void 0===ev);(!(ep="string"==typeof ep?ep:eU)||ep.startsWith("data:")||ep.startsWith("blob:"))&&(ex=!0,eH=!1),er.unoptimized&&(ex=!0),eG&&ep.endsWith(".svg")&&!er.dangerouslyAllowSVG&&(ex=!0),eg&&(eM="high");let eB=ed(eb),eq=Object.assign(e_?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:eN,objectPosition:eP}:{},eF?{}:{color:"transparent"},eC),eK=eZ||"empty"===eS?null:"blur"===eS?'url("data:image/svg+xml;charset=utf-8,'+(0,ei.getImageBlurSvg)({widthInt:eW,heightInt:eV,blurWidth:eu,blurHeight:ef,blurDataURL:eO||"",objectFit:eq.objectFit})+'")':'url("'+eS+'")',eY=eK?{backgroundSize:eq.objectFit||"cover",backgroundPosition:eq.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:eK}:{},eQ=eh({config:er,src:ep,unoptimized:ex,width:eW,quality:eB,sizes:em,loader:e$}),eJ={...eA,loading:eH?"lazy":ev,fetchPriority:eM,width:eW,height:eV,decoding:"async",className:ey,style:{...eq,...eY},sizes:eQ.sizes,srcSet:eQ.srcSet,src:eQ.src},eX={unoptimized:ex,priority:eg,placeholder:eS,fill:e_};return{props:eJ,meta:eX}}},8755:function(ee,en){"use strict";function er(ee){let{widthInt:en,heightInt:er,blurWidth:ei,blurHeight:eo,blurDataURL:es,objectFit:eu}=ee,ec=20,ed=ei?40*ei:en,ef=eo?40*eo:er,eh=ed&&ef?"viewBox='0 0 "+ed+" "+ef+"'":"",ep=eh?"none":"contain"===eu?"xMidYMid":"cover"===eu?"xMidYMid slice":"none";return"%3Csvg xmlns='http://www.w3.org/2000/svg' "+eh+"%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='"+ec+"'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='"+ec+"'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='"+ep+"' style='filter: url(%23b);' href='"+es+"'/%3E%3C/svg%3E"}Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"getImageBlurSvg",{enumerable:!0,get:function(){return er}})},257:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),function(ee,en){for(var er in en)Object.defineProperty(ee,er,{enumerable:!0,get:en[er]})}(en,{default:function(){return ef},unstable_getImgProps:function(){return ed}});let ei=er(1351),eo=er(8009),es=er(5393),eu=er(759),ec=ei._(er(2685)),ed=ee=>{(0,es.warnOnce)("Warning: unstable_getImgProps() is experimental and may change or be removed at any time. Use at your own risk.");let{props:en}=(0,eo.getImgProps)(ee,{defaultLoader:ec.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!0}});for(let[ee,er]of Object.entries(en))void 0===er&&delete en[ee];return{props:en}},ef=eu.Image},2685:function(ee,en){"use strict";function er(ee){let{config:en,src:er,width:ei,quality:eo}=ee;return en.path+"?url="+encodeURIComponent(er)+"&w="+ei+"&q="+(eo||75)}Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"default",{enumerable:!0,get:function(){return ei}}),er.__next_img_default=!0;let ei=er},7771:function(){},1803:function(){},2084:function(ee){var en="/";!function(){"use strict";var er={114:function(ee){function en(ee){if("string"!=typeof ee)throw TypeError("Path must be a string. Received "+JSON.stringify(ee))}function er(ee,en){for(var er,ei="",eo=0,es=-1,eu=0,ec=0;ec<=ee.length;++ec){if(ec2){var ed=ei.lastIndexOf("/");if(ed!==ei.length-1){-1===ed?(ei="",eo=0):eo=(ei=ei.slice(0,ed)).length-1-ei.lastIndexOf("/"),es=ec,eu=0;continue}}else if(2===ei.length||1===ei.length){ei="",eo=0,es=ec,eu=0;continue}}en&&(ei.length>0?ei+="/..":ei="..",eo=2)}else ei.length>0?ei+="/"+ee.slice(es+1,ec):ei=ee.slice(es+1,ec),eo=ec-es-1;es=ec,eu=0}else 46===er&&-1!==eu?++eu:eu=-1}return ei}function ei(ee,en){var er=en.dir||en.root,ei=en.base||(en.name||"")+(en.ext||"");return er?er===en.root?er+ei:er+ee+ei:ei}var eo={resolve:function(){for(var ee,ei,eo="",es=!1,eu=arguments.length-1;eu>=-1&&!es;eu--)eu>=0?ei=arguments[eu]:(void 0===ee&&(ee=""),ei=ee),en(ei),0!==ei.length&&(eo=ei+"/"+eo,es=47===ei.charCodeAt(0));return(eo=er(eo,!es),es)?eo.length>0?"/"+eo:"/":eo.length>0?eo:"."},normalize:function(ee){if(en(ee),0===ee.length)return".";var ei=47===ee.charCodeAt(0),eo=47===ee.charCodeAt(ee.length-1);return(0!==(ee=er(ee,!ei)).length||ei||(ee="."),ee.length>0&&eo&&(ee+="/"),ei)?"/"+ee:ee},isAbsolute:function(ee){return en(ee),ee.length>0&&47===ee.charCodeAt(0)},join:function(){if(0==arguments.length)return".";for(var ee,er=0;er0&&(void 0===ee?ee=ei:ee+="/"+ei)}return void 0===ee?".":eo.normalize(ee)},relative:function(ee,er){if(en(ee),en(er),ee===er||(ee=eo.resolve(ee))===(er=eo.resolve(er)))return"";for(var ei=1;eief){if(47===er.charCodeAt(ec+ep))return er.slice(ec+ep+1);if(0===ep)return er.slice(ec+ep)}else eu>ef&&(47===ee.charCodeAt(ei+ep)?eh=ep:0===ep&&(eh=0));break}var em=ee.charCodeAt(ei+ep);if(em!==er.charCodeAt(ec+ep))break;47===em&&(eh=ep)}var ex="";for(ep=ei+eh+1;ep<=es;++ep)(ep===es||47===ee.charCodeAt(ep))&&(0===ex.length?ex+="..":ex+="/..");return ex.length>0?ex+er.slice(ec+eh):(ec+=eh,47===er.charCodeAt(ec)&&++ec,er.slice(ec))},_makeLong:function(ee){return ee},dirname:function(ee){if(en(ee),0===ee.length)return".";for(var er=ee.charCodeAt(0),ei=47===er,eo=-1,es=!0,eu=ee.length-1;eu>=1;--eu)if(47===(er=ee.charCodeAt(eu))){if(!es){eo=eu;break}}else es=!1;return -1===eo?ei?"/":".":ei&&1===eo?"//":ee.slice(0,eo)},basename:function(ee,er){if(void 0!==er&&"string"!=typeof er)throw TypeError('"ext" argument must be a string');en(ee);var ei,eo=0,es=-1,eu=!0;if(void 0!==er&&er.length>0&&er.length<=ee.length){if(er.length===ee.length&&er===ee)return"";var ec=er.length-1,ed=-1;for(ei=ee.length-1;ei>=0;--ei){var ef=ee.charCodeAt(ei);if(47===ef){if(!eu){eo=ei+1;break}}else -1===ed&&(eu=!1,ed=ei+1),ec>=0&&(ef===er.charCodeAt(ec)?-1==--ec&&(es=ei):(ec=-1,es=ed))}return eo===es?es=ed:-1===es&&(es=ee.length),ee.slice(eo,es)}for(ei=ee.length-1;ei>=0;--ei)if(47===ee.charCodeAt(ei)){if(!eu){eo=ei+1;break}}else -1===es&&(eu=!1,es=ei+1);return -1===es?"":ee.slice(eo,es)},extname:function(ee){en(ee);for(var er=-1,ei=0,eo=-1,es=!0,eu=0,ec=ee.length-1;ec>=0;--ec){var ed=ee.charCodeAt(ec);if(47===ed){if(!es){ei=ec+1;break}continue}-1===eo&&(es=!1,eo=ec+1),46===ed?-1===er?er=ec:1!==eu&&(eu=1):-1!==er&&(eu=-1)}return -1===er||-1===eo||0===eu||1===eu&&er===eo-1&&er===ei+1?"":ee.slice(er,eo)},format:function(ee){if(null===ee||"object"!=typeof ee)throw TypeError('The "pathObject" argument must be of type Object. Received type '+typeof ee);return ei("/",ee)},parse:function(ee){en(ee);var er,ei={root:"",dir:"",base:"",ext:"",name:""};if(0===ee.length)return ei;var eo=ee.charCodeAt(0),es=47===eo;es?(ei.root="/",er=1):er=0;for(var eu=-1,ec=0,ed=-1,ef=!0,eh=ee.length-1,ep=0;eh>=er;--eh){if(47===(eo=ee.charCodeAt(eh))){if(!ef){ec=eh+1;break}continue}-1===ed&&(ef=!1,ed=eh+1),46===eo?-1===eu?eu=eh:1!==ep&&(ep=1):-1!==eu&&(ep=-1)}return -1===eu||-1===ed||0===ep||1===ep&&eu===ed-1&&eu===ec+1?-1!==ed&&(0===ec&&es?ei.base=ei.name=ee.slice(1,ed):ei.base=ei.name=ee.slice(ec,ed)):(0===ec&&es?(ei.name=ee.slice(1,eu),ei.base=ee.slice(1,ed)):(ei.name=ee.slice(ec,eu),ei.base=ee.slice(ec,ed)),ei.ext=ee.slice(eu,ed)),ec>0?ei.dir=ee.slice(0,ec-1):es&&(ei.dir="/"),ei},sep:"/",delimiter:":",win32:null,posix:null};eo.posix=eo,ee.exports=eo}},ei={};function eo(ee){var en=ei[ee];if(void 0!==en)return en.exports;var es=ei[ee]={exports:{}},eu=!0;try{er[ee](es,es.exports,eo),eu=!1}finally{eu&&delete ei[ee]}return es.exports}eo.ab=en+"/";var es=eo(114);ee.exports=es}()},4529:function(ee){var en="/";!function(){var er={229:function(ee){var en,er,ei,eo=ee.exports={};function es(){throw Error("setTimeout has not been defined")}function eu(){throw Error("clearTimeout has not been defined")}function ec(ee){if(en===setTimeout)return setTimeout(ee,0);if((en===es||!en)&&setTimeout)return en=setTimeout,setTimeout(ee,0);try{return en(ee,0)}catch(er){try{return en.call(null,ee,0)}catch(er){return en.call(this,ee,0)}}}function ed(ee){if(er===clearTimeout)return clearTimeout(ee);if((er===eu||!er)&&clearTimeout)return er=clearTimeout,clearTimeout(ee);try{return er(ee)}catch(en){try{return er.call(null,ee)}catch(en){return er.call(this,ee)}}}!function(){try{en="function"==typeof setTimeout?setTimeout:es}catch(ee){en=es}try{er="function"==typeof clearTimeout?clearTimeout:eu}catch(ee){er=eu}}();var ef=[],eh=!1,ep=-1;function em(){eh&&ei&&(eh=!1,ei.length?ef=ei.concat(ef):ep=-1,ef.length&&ex())}function ex(){if(!eh){var ee=ec(em);eh=!0;for(var en=ef.length;en;){for(ei=ef,ef=[];++ep1)for(var er=1;er(0,ec.jsx)("button",{className:(0,eu.Z)("nextra-button nx-transition-all active:nx-opacity-50","nx-bg-primary-700/5 nx-border nx-border-black/5 nx-text-gray-600 hover:nx-text-gray-900 nx-rounded-md nx-p-1.5","dark:nx-bg-primary-300/10 dark:nx-border-white/10 dark:nx-text-gray-400 dark:hover:nx-text-gray-50",en),...er,children:ee}),ef=er(456),eh={default:"\uD83D\uDCA1",error:"\uD83D\uDEAB",info:(0,ec.jsx)(ef.AV,{className:"nx-mt-1"}),warning:"⚠️"},ep={default:(0,eu.Z)("nx-border-orange-100 nx-bg-orange-50 nx-text-orange-800 dark:nx-border-orange-400/30 dark:nx-bg-orange-400/20 dark:nx-text-orange-300"),error:(0,eu.Z)("nx-border-red-200 nx-bg-red-100 nx-text-red-900 dark:nx-border-red-200/30 dark:nx-bg-red-900/30 dark:nx-text-red-200"),info:(0,eu.Z)("nx-border-blue-200 nx-bg-blue-100 nx-text-blue-900 dark:nx-border-blue-200/30 dark:nx-bg-blue-900/30 dark:nx-text-blue-200"),warning:(0,eu.Z)("nx-border-yellow-100 nx-bg-yellow-50 nx-text-yellow-900 dark:nx-border-yellow-200/30 dark:nx-bg-yellow-700/30 dark:nx-text-yellow-200")};function em({children:ee,type:en="default",emoji:er=eh[en]}){return(0,ec.jsxs)("div",{className:(0,eu.Z)("nextra-callout nx-overflow-x-auto nx-mt-6 nx-flex nx-rounded-lg nx-border nx-py-2 ltr:nx-pr-4 rtl:nx-pl-4","contrast-more:nx-border-current contrast-more:dark:nx-border-current",ep[en]),children:[(0,ec.jsx)("div",{className:"nx-select-none nx-text-xl ltr:nx-pl-3 ltr:nx-pr-2 rtl:nx-pr-3 rtl:nx-pl-2",style:{fontFamily:'"Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"'},children:er}),(0,ec.jsx)("div",{className:"nx-w-full nx-min-w-0 nx-leading-7",children:ee})]})}var ex=er(959),eg=({getValue:ee,...en})=>{let[er,ei]=(0,ex.useState)(!1);(0,ex.useEffect)(()=>{if(!er)return;let ee=setTimeout(()=>{ei(!1)},2e3);return()=>{clearTimeout(ee)}},[er]);let eo=(0,ex.useCallback)(async()=>{ei(!0),navigator?.clipboard||console.error("Access to clipboard rejected!");try{await navigator.clipboard.writeText(ee())}catch{console.error("Failed to copy!")}},[ee]),es=er?ef.nQ:ef.TI;return(0,ec.jsx)(ed,{onClick:eo,title:"Copy code",tabIndex:0,...en,children:(0,ec.jsx)(es,{className:"nextra-copy-icon nx-pointer-events-none nx-h-4 nx-w-4"})})},ev=({children:ee,className:en,...er})=>{let ei="data-line-numbers"in er;return(0,ec.jsx)("code",{className:(0,eu.Z)("nx-border-black nx-border-opacity-[0.04] nx-bg-opacity-[0.03] nx-bg-black nx-break-words nx-rounded-md nx-border nx-py-0.5 nx-px-[.25em] nx-text-[.9em]","dark:nx-border-white/10 dark:nx-bg-white/10",ei&&"[counter-reset:line]",en),dir:"ltr",...er,children:ee})},ey=({children:ee,className:en,hasCopyCode:er,filename:ei,...eo})=>{let es=(0,ex.useRef)(null),eh=(0,ex.useCallback)(()=>{let ee=document.documentElement.dataset,en="nextraWordWrap"in ee;en?delete ee.nextraWordWrap:ee.nextraWordWrap=""},[]);return(0,ec.jsxs)("div",{className:"nextra-code-block nx-relative nx-mt-6 first:nx-mt-0",children:[ei&&(0,ec.jsx)("div",{className:"nx-absolute nx-top-0 nx-z-[1] nx-w-full nx-truncate nx-rounded-t-xl nx-bg-primary-700/5 nx-py-2 nx-px-4 nx-text-xs nx-text-gray-700 dark:nx-bg-primary-300/10 dark:nx-text-gray-200",children:ei}),(0,ec.jsx)("pre",{className:(0,eu.Z)("nx-bg-primary-700/5 nx-mb-4 nx-overflow-x-auto nx-rounded-xl nx-subpixel-antialiased dark:nx-bg-primary-300/10 nx-text-[.9em]","contrast-more:nx-border contrast-more:nx-border-primary-900/20 contrast-more:nx-contrast-150 contrast-more:dark:nx-border-primary-100/40",ei?"nx-pt-12 nx-pb-4":"nx-py-4",en),ref:es,...eo,children:ee}),(0,ec.jsxs)("div",{className:(0,eu.Z)("nx-opacity-0 nx-transition [div:hover>&]:nx-opacity-100 focus-within:nx-opacity-100","nx-flex nx-gap-1 nx-absolute nx-m-[11px] nx-right-0",ei?"nx-top-8":"nx-top-0"),children:[(0,ec.jsx)(ed,{onClick:eh,className:"md:nx-hidden",title:"Toggle word wrap",children:(0,ec.jsx)(ef.NK,{className:"nx-pointer-events-none nx-h-4 nx-w-4"})}),er&&(0,ec.jsx)(eg,{getValue:()=>es.current?.querySelector("code")?.textContent||""})]})]})};function eb({children:ee,className:en,...er}){return(0,ec.jsx)("div",{className:(0,eu.Z)("nextra-steps nx-ml-4 nx-mb-12 nx-border-l nx-border-gray-200 nx-pl-6","dark:nx-border-neutral-800 [counter-reset:step]",en),...er,children:ee})}var ek=er(222),ew=er(9038),e_=er(3011),eC=er(8246),eE=er(7496),ej=er(6260),eS=er(9850),eO=er(8002),eM=er(9691),eT=er(5782),eN=er(1941);function eP({onFocus:ee}){let[en,er]=(0,ex.useState)(!0),ei=(0,eT.t)();return en?ex.createElement(eN._,{as:"button",type:"button",features:eN.A.Focusable,onFocus:en=>{en.preventDefault();let eo,es=50;function eu(){if(es--<=0){eo&&cancelAnimationFrame(eo);return}if(ee()){if(cancelAnimationFrame(eo),!ei.current)return;er(!1);return}eo=requestAnimationFrame(eu)}eo=requestAnimationFrame(eu)}}):null}var eI=er(6510),eR=er(1287),eA=er(9195);let eL=ex.createContext(null);function eF(){return{groups:new Map,get(ee,en){var er;let ei=this.groups.get(ee);ei||(ei=new Map,this.groups.set(ee,ei));let eo=null!=(er=ei.get(en))?er:0;function es(){let ee=ei.get(en);ee>1?ei.set(en,ee-1):ei.delete(en)}return ei.set(en,eo+1),[Array.from(ei.keys()).indexOf(en),es]}}}function eZ({children:ee}){let en=ex.useRef(eF());return ex.createElement(eL.Provider,{value:en},ee)}function eD(ee){let en=ex.useContext(eL);if(!en)throw Error("You must wrap your component in a ");let er=ez(),[ei,eo]=en.current.get(ee,er);return ex.useEffect(()=>eo,[]),ei}function ez(){var ee,en,er;let ei=null!=(er=null==(en=null==(ee=ex.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)?void 0:ee.ReactCurrentOwner)?void 0:en.current)?er:null;if(!ei)return Symbol();let eo=[],es=ei;for(;es;)eo.push(es.index),es=es.return;return"$."+eo.join(".")}var e$=((ei=e$||{})[ei.Forwards=0]="Forwards",ei[ei.Backwards=1]="Backwards",ei),eG=((eo=eG||{})[eo.Less=-1]="Less",eo[eo.Equal=0]="Equal",eo[eo.Greater=1]="Greater",eo),eU=((es=eU||{})[es.SetSelectedIndex=0]="SetSelectedIndex",es[es.RegisterTab=1]="RegisterTab",es[es.UnregisterTab=2]="UnregisterTab",es[es.RegisterPanel=3]="RegisterPanel",es[es.UnregisterPanel=4]="UnregisterPanel",es);let eW={0(ee,en){var er;let ei=(0,eE.z2)(ee.tabs,ee=>ee.current),eo=(0,eE.z2)(ee.panels,ee=>ee.current),es=ei.filter(ee=>{var en;return!(null!=(en=ee.current)&&en.hasAttribute("disabled"))}),eu={...ee,tabs:ei,panels:eo};if(en.index<0||en.index>ei.length-1){let er=(0,e_.E)(Math.sign(en.index-ee.selectedIndex),{[-1]:()=>1,0:()=>(0,e_.E)(Math.sign(en.index),{[-1]:()=>0,0:()=>0,1:()=>1}),1:()=>0});if(0===es.length)return eu;let eo=(0,e_.E)(er,{0:()=>ei.indexOf(es[0]),1:()=>ei.indexOf(es[es.length-1])});return{...eu,selectedIndex:-1===eo?ee.selectedIndex:eo}}let ec=ei.slice(0,en.index),ed=[...ei.slice(en.index),...ec].find(ee=>es.includes(ee));if(!ed)return eu;let ef=null!=(er=ei.indexOf(ed))?er:ee.selectedIndex;return -1===ef&&(ef=ee.selectedIndex),{...eu,selectedIndex:ef}},1(ee,en){var er;if(ee.tabs.includes(en.tab))return ee;let ei=ee.tabs[ee.selectedIndex],eo=(0,eE.z2)([...ee.tabs,en.tab],ee=>ee.current),es=null!=(er=eo.indexOf(ei))?er:ee.selectedIndex;return -1===es&&(es=ee.selectedIndex),{...ee,tabs:eo,selectedIndex:es}},2:(ee,en)=>({...ee,tabs:ee.tabs.filter(ee=>ee!==en.tab)}),3:(ee,en)=>ee.panels.includes(en.panel)?ee:{...ee,panels:(0,eE.z2)([...ee.panels,en.panel],ee=>ee.current)},4:(ee,en)=>({...ee,panels:ee.panels.filter(ee=>ee!==en.panel)})},eV=(0,ex.createContext)(null);function eH(ee){let en=(0,ex.useContext)(eV);if(null===en){let en=Error(`<${ee} /> is missing a parent component.`);throw Error.captureStackTrace&&Error.captureStackTrace(en,eH),en}return en}eV.displayName="TabsDataContext";let eB=(0,ex.createContext)(null);function eq(ee){let en=(0,ex.useContext)(eB);if(null===en){let en=Error(`<${ee} /> is missing a parent component.`);throw Error.captureStackTrace&&Error.captureStackTrace(en,eq),en}return en}function eK(ee,en){return(0,e_.E)(en.type,eW,ee,en)}eB.displayName="TabsActionsContext";let eY=ex.Fragment;function eQ(ee,en){let{defaultIndex:er=0,vertical:ei=!1,manual:eo=!1,onChange:es,selectedIndex:eu=null,...ec}=ee,ed=ei?"vertical":"horizontal",ef=eo?"manual":"auto",eh=null!==eu,ep=(0,eS.T)(en),[em,eg]=(0,ex.useReducer)(eK,{selectedIndex:null!=eu?eu:er,tabs:[],panels:[]}),ev=(0,ex.useMemo)(()=>({selectedIndex:em.selectedIndex}),[em.selectedIndex]),ey=(0,eM.E)(es||(()=>{})),eb=(0,eM.E)(em.tabs),ew=(0,ex.useMemo)(()=>({orientation:ed,activation:ef,...em}),[ed,ef,em]),e_=(0,eI.z)(ee=>(eg({type:1,tab:ee}),()=>eg({type:2,tab:ee}))),eC=(0,eI.z)(ee=>(eg({type:3,panel:ee}),()=>eg({type:4,panel:ee}))),eO=(0,eI.z)(ee=>{eT.current!==ee&&ey.current(ee),eh||eg({type:0,index:ee})}),eT=(0,eM.E)(eh?ee.selectedIndex:em.selectedIndex),eN=(0,ex.useMemo)(()=>({registerTab:e_,registerPanel:eC,change:eO}),[]);(0,ej.e)(()=>{eg({type:0,index:null!=eu?eu:er})},[eu]),(0,ej.e)(()=>{if(void 0===eT.current||em.tabs.length<=0)return;let ee=(0,eE.z2)(em.tabs,ee=>ee.current);ee.some((ee,en)=>em.tabs[en]!==ee)&&eO(ee.indexOf(em.tabs[eT.current]))});let eR={ref:ep};return ex.createElement(eZ,null,ex.createElement(eB.Provider,{value:eN},ex.createElement(eV.Provider,{value:ew},ew.tabs.length<=0&&ex.createElement(eP,{onFocus:()=>{var ee,en;for(let er of eb.current)if((null==(ee=er.current)?void 0:ee.tabIndex)===0)return null==(en=er.current)||en.focus(),!0;return!1}}),(0,ek.sY)({ourProps:eR,theirProps:ec,slot:ev,defaultTag:eY,name:"Tabs"}))))}let eJ="div";function eX(ee,en){let{orientation:er,selectedIndex:ei}=eH("Tab.List"),eo=(0,eS.T)(en);return(0,ek.sY)({ourProps:{ref:eo,role:"tablist","aria-orientation":er},theirProps:ee,slot:{selectedIndex:ei},defaultTag:eJ,name:"Tabs.List"})}let e0="button";function e1(ee,en){var er,ei;let eo=(0,ew.M)(),{id:es=`headlessui-tabs-tab-${eo}`,...eu}=ee,{orientation:ec,activation:ed,selectedIndex:ef,tabs:eh,panels:ep}=eH("Tab"),em=eq("Tab"),eg=eH("Tab"),ev=(0,ex.useRef)(null),ey=(0,eS.T)(ev,en);(0,ej.e)(()=>em.registerTab(ev),[em,ev]);let eb=eD("tabs"),eM=eh.indexOf(ev);-1===eM&&(eM=eb);let eT=eM===ef,eN=(0,eI.z)(ee=>{var en;let er=ee();if(er===eE.fE.Success&&"auto"===ed){let ee=null==(en=(0,eA.r)(ev))?void 0:en.activeElement,er=eg.tabs.findIndex(en=>en.current===ee);-1!==er&&em.change(er)}return er}),eP=(0,eI.z)(ee=>{let en=eh.map(ee=>ee.current).filter(Boolean);if(ee.key===eC.R.Space||ee.key===eC.R.Enter){ee.preventDefault(),ee.stopPropagation(),em.change(eM);return}switch(ee.key){case eC.R.Home:case eC.R.PageUp:return ee.preventDefault(),ee.stopPropagation(),eN(()=>(0,eE.jA)(en,eE.TO.First));case eC.R.End:case eC.R.PageDown:return ee.preventDefault(),ee.stopPropagation(),eN(()=>(0,eE.jA)(en,eE.TO.Last))}if(eN(()=>(0,e_.E)(ec,{vertical:()=>ee.key===eC.R.ArrowUp?(0,eE.jA)(en,eE.TO.Previous|eE.TO.WrapAround):ee.key===eC.R.ArrowDown?(0,eE.jA)(en,eE.TO.Next|eE.TO.WrapAround):eE.fE.Error,horizontal:()=>ee.key===eC.R.ArrowLeft?(0,eE.jA)(en,eE.TO.Previous|eE.TO.WrapAround):ee.key===eC.R.ArrowRight?(0,eE.jA)(en,eE.TO.Next|eE.TO.WrapAround):eE.fE.Error}))===eE.fE.Success)return ee.preventDefault()}),eL=(0,ex.useRef)(!1),eF=(0,eI.z)(()=>{var ee;eL.current||(eL.current=!0,null==(ee=ev.current)||ee.focus({preventScroll:!0}),em.change(eM),(0,eR.Y)(()=>{eL.current=!1}))}),eZ=(0,eI.z)(ee=>{ee.preventDefault()}),ez=(0,ex.useMemo)(()=>({selected:eT}),[eT]),e$={ref:ey,onKeyDown:eP,onMouseDown:eZ,onClick:eF,id:es,role:"tab",type:(0,eO.f)(ee,ev),"aria-controls":null==(ei=null==(er=ep[eM])?void 0:er.current)?void 0:ei.id,"aria-selected":eT,tabIndex:eT?0:-1};return(0,ek.sY)({ourProps:e$,theirProps:eu,slot:ez,defaultTag:e0,name:"Tabs.Tab"})}let e2="div";function e4(ee,en){let{selectedIndex:er}=eH("Tab.Panels"),ei=(0,eS.T)(en),eo=(0,ex.useMemo)(()=>({selectedIndex:er}),[er]);return(0,ek.sY)({ourProps:{ref:ei},theirProps:ee,slot:eo,defaultTag:e2,name:"Tabs.Panels"})}let e5="div",e3=ek.AN.RenderStrategy|ek.AN.Static;function e7(ee,en){var er,ei,eo,es;let eu=(0,ew.M)(),{id:ec=`headlessui-tabs-panel-${eu}`,tabIndex:ed=0,...ef}=ee,{selectedIndex:eh,tabs:ep,panels:em}=eH("Tab.Panel"),eg=eq("Tab.Panel"),ev=(0,ex.useRef)(null),ey=(0,eS.T)(ev,en);(0,ej.e)(()=>eg.registerPanel(ev),[eg,ev]);let eb=eD("panels"),e_=em.indexOf(ev);-1===e_&&(e_=eb);let eC=e_===eh,eE=(0,ex.useMemo)(()=>({selected:eC}),[eC]),eO={ref:ey,id:ec,role:"tabpanel","aria-labelledby":null==(ei=null==(er=ep[e_])?void 0:er.current)?void 0:ei.id,tabIndex:eC?ed:-1};return eC||null!=(eo=ef.unmount)&&!eo||null!=(es=ef.static)&&es?(0,ek.sY)({ourProps:eO,theirProps:ef,slot:eE,defaultTag:e5,features:e3,visible:eC,name:"Tabs.Panel"}):ex.createElement(eN._,{as:"span",...eO})}let e6=Object.assign((0,ek.yV)(e1),{Group:(0,ek.yV)(eQ),List:(0,ek.yV)(eX),Panels:(0,ek.yV)(e4),Panel:(0,ek.yV)(e7)});function e9(ee){return!!ee&&"object"==typeof ee&&"label"in ee}function e8({children:ee,...en}){return(0,ec.jsx)(e6.Panel,{...en,className:"nx-rounded nx-pt-6",children:ee})}var tn=Object.assign(function({items:ee,selectedIndex:en,defaultIndex:er=0,onChange:ei,children:eo,storageKey:es}){let[ed,ef]=(0,ex.useState)(er);(0,ex.useEffect)(()=>{void 0!==en&&ef(en)},[en]),(0,ex.useEffect)(()=>{if(!es)return;function ee(ee){ee.key===es&&ef(Number(ee.newValue))}let en=Number(localStorage.getItem(es));return ef(Number.isNaN(en)?0:en),window.addEventListener("storage",ee),()=>{window.removeEventListener("storage",ee)}},[]);let eh=(0,ex.useCallback)(ee=>{if(es){let en=String(ee);localStorage.setItem(es,en),window.dispatchEvent(new StorageEvent("storage",{key:es,newValue:en}));return}ef(ee),ei?.(ee)},[]);return(0,ec.jsxs)(e6.Group,{selectedIndex:ed,defaultIndex:er,onChange:eh,children:[(0,ec.jsx)("div",{className:"nextra-scrollbar nx-overflow-x-auto nx-overflow-y-hidden nx-overscroll-x-contain",children:(0,ec.jsx)(e6.List,{className:"nx-mt-4 nx-flex nx-w-max nx-min-w-full nx-border-b nx-border-gray-200 nx-pb-px dark:nx-border-neutral-800",children:ee.map((ee,en)=>{let er=e9(ee)&&ee.disabled;return(0,ec.jsx)(e6,{disabled:er,className:({selected:ee})=>(0,eu.Z)("nx-mr-2 nx-rounded-t nx-p-2 nx-font-medium nx-leading-5 nx-transition-colors","-nx-mb-0.5 nx-select-none nx-border-b-2",ee?"nx-border-primary-500 nx-text-primary-600":"nx-border-transparent nx-text-gray-600 hover:nx-border-gray-200 hover:nx-text-black dark:nx-text-gray-200 dark:hover:nx-border-neutral-800 dark:hover:nx-text-white",er&&"nx-pointer-events-none nx-text-gray-400 dark:nx-text-neutral-600"),children:e9(ee)?ee.label:ee},en)})})}),(0,ec.jsx)(e6.Panels,{children:eo})]})},{displayName:"Tabs",Tab:e8}),tr=({className:ee="",...en})=>(0,ec.jsx)("td",{className:(0,eu.Z)("nx-m-0 nx-border nx-border-gray-300 nx-px-4 nx-py-2 dark:nx-border-gray-600",ee),...en}),ti=({className:ee="",...en})=>(0,ec.jsx)("table",{className:(0,eu.Z)("nx-block nx-overflow-x-scroll",ee),...en}),to=({className:ee="",...en})=>(0,ec.jsx)("th",{className:(0,eu.Z)("nx-m-0 nx-border nx-border-gray-300 nx-px-4 nx-py-2 nx-font-semibold dark:nx-border-gray-600",ee),...en}),ts=({className:ee="",...en})=>(0,ec.jsx)("tr",{className:(0,eu.Z)("nx-m-0 nx-border-t nx-border-gray-300 nx-p-0 dark:nx-border-gray-600","even:nx-bg-gray-100 even:dark:nx-bg-gray-600/20",ee),...en}),tl=er(1317),tu=er.n(tl),tc={cards:(0,eu.Z)("nextra-cards nx-mt-4 nx-gap-4 nx-grid","nx-not-prose"),card:(0,eu.Z)("nextra-card nx-group nx-flex nx-flex-col nx-justify-start nx-overflow-hidden nx-rounded-lg nx-border nx-border-gray-200","nx-text-current nx-no-underline dark:nx-shadow-none","hover:nx-shadow-gray-100 dark:hover:nx-shadow-none nx-shadow-gray-100","active:nx-shadow-sm active:nx-shadow-gray-200","nx-transition-all nx-duration-200 hover:nx-border-gray-300"),title:(0,eu.Z)("nx-flex nx-font-semibold nx-items-start nx-gap-2 nx-p-4 nx-text-gray-700 hover:nx-text-gray-900")},td=(0,ec.jsx)("span",{className:"nx-transition-transform nx-duration-75 group-hover:nx-translate-x-[2px]",children:"→"});Object.assign(function({children:ee,num:en=3,className:er,style:ei,...eo}){return(0,ec.jsx)("div",{className:(0,eu.Z)(tc.cards,er),...eo,style:{...ei,"--rows":en},children:ee})},{displayName:"Cards",Card:function({children:ee,title:en,icon:er,image:ei,arrow:eo,href:es,...ed}){let ef=eo?td:null;return ei?(0,ec.jsxs)(tu(),{href:es,className:(0,eu.Z)(tc.card,"nx-bg-gray-100 nx-shadow dark:nx-border-neutral-700 dark:nx-bg-neutral-800 dark:nx-text-gray-50 hover:nx-shadow-lg dark:hover:nx-border-neutral-500 dark:hover:nx-bg-neutral-700"),...ed,children:[ee,(0,ec.jsxs)("span",{className:(0,eu.Z)(tc.title,"dark:nx-text-gray-300 dark:hover:nx-text-gray-100"),children:[er,(0,ec.jsxs)("span",{className:"nx-flex nx-gap-1",children:[en,ef]})]})]}):(0,ec.jsx)(tu(),{href:es,className:(0,eu.Z)(tc.card,"nx-bg-transparent nx-shadow-sm dark:nx-border-neutral-800 hover:nx-bg-slate-50 hover:nx-shadow-md dark:hover:nx-border-neutral-700 dark:hover:nx-bg-neutral-900"),...ed,children:(0,ec.jsxs)("span",{className:(0,eu.Z)(tc.title,"dark:nx-text-neutral-200 dark:hover:nx-text-neutral-50 nx-flex nx-items-center"),children:[er,en,ef]})})}});var tf=(0,ex.createContext)(0);function th(){return(0,ex.useContext)(tf)}function tp({children:ee}){return(0,ec.jsx)("div",{className:(0,eu.Z)("nextra-filetree nx-mt-6 nx-select-none nx-text-sm nx-text-gray-800 dark:nx-text-gray-300","nx-not-prose"),children:(0,ec.jsx)("div",{className:"nx-inline-block nx-rounded-lg nx-border nx-px-4 nx-py-2 dark:nx-border-neutral-800",children:ee})})}function tm(){let ee=th();return(0,ec.jsx)(ec.Fragment,{children:Array.from({length:ee},(ee,en)=>(0,ec.jsx)("span",{className:"nx-w-5"},en))})}var tx=(0,ex.memo)(({label:ee,name:en,open:er,children:ei,defaultOpen:eo=!1,onToggle:es})=>{let eu=th(),[ed,ef]=(0,ex.useState)(eo),eh=(0,ex.useCallback)(()=>{es?.(!ed),ef(!ed)},[ed,es]),ep=void 0===er?ed:er;return(0,ec.jsxs)("li",{className:"nx-flex nx-list-none nx-flex-col",children:[(0,ec.jsxs)("button",{onClick:eh,title:en,className:"nx-inline-flex nx-cursor-pointer nx-items-center nx-py-1 hover:nx-opacity-60",children:[(0,ec.jsx)(tm,{}),(0,ec.jsx)("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",children:(0,ec.jsx)("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:ep?"M5 19a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2h4l2 2h4a2 2 0 0 1 2 2v1M5 19h14a2 2 0 0 0 2-2v-5a2 2 0 0 0-2-2H9a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2Z":"M3 7v10a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-6l-2-2H5a2 2 0 0 0-2 2Z"})}),(0,ec.jsx)("span",{className:"nx-ml-1",children:ee??en})]}),ep&&(0,ec.jsx)("ul",{children:(0,ec.jsx)(tf.Provider,{value:eu+1,children:ei})})]})});tx.displayName="Folder";var tg=(0,ex.memo)(({label:ee,name:en,active:er})=>(0,ec.jsx)("li",{className:(0,eu.Z)("nx-flex nx-list-none",er&&"nx-text-primary-600 contrast-more:nx-underline"),children:(0,ec.jsxs)("span",{className:"nx-inline-flex nx-cursor-default nx-items-center nx-py-1",children:[(0,ec.jsx)(tm,{}),(0,ec.jsx)("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",children:(0,ec.jsx)("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M9 12h6m-6 4h6m2 5H7a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5.586a1 1 0 0 1 .707.293l5.414 5.414a1 1 0 0 1 .293.707V19a2 2 0 0 1-2 2Z"})}),(0,ec.jsx)("span",{className:"nx-ml-1",children:ee??en})]})}));tg.displayName="File",Object.assign(tp,{Folder:tx,File:tg})},456:function(ee,en,er){"use strict";er.d(en,{LZ:function(){return eo},nQ:function(){return es},TI:function(){return eu},D7:function(){return ec},Qq:function(){return ed},fy:function(){return ef},n9:function(){return eh},AV:function(){return ep},Oq:function(){return em},kL:function(){return ex},L4:function(){return eg},NW:function(){return ev},NK:function(){return ey},b0:function(){return eb}});var ei=er(1527);function eo({pathClassName:ee,...en}){return(0,ei.jsx)("svg",{fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",...en,children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M9 5l7 7-7 7",className:ee})})}function es(ee){return(0,ei.jsx)("svg",{viewBox:"0 0 20 20",width:"1em",height:"1em",fill:"currentColor",...ee,children:(0,ei.jsx)("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})})}function eu(ee){return(0,ei.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",stroke:"currentColor",...ee,children:[(0,ei.jsx)("rect",{x:"9",y:"9",width:"13",height:"13",rx:"2",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),(0,ei.jsx)("path",{d:"M5 15H4C2.89543 15 2 14.1046 2 13V4C2 2.89543 2.89543 2 4 2H13C14.1046 2 15 2.89543 15 4V5",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})}function ec(ee){return(0,ei.jsxs)("svg",{width:"24",height:"24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 5 30.67 23.25",...ee,children:[(0,ei.jsx)("title",{children:"Discord"}),(0,ei.jsx)("path",{d:"M26.0015 6.9529C24.0021 6.03845 21.8787 5.37198 19.6623 5C19.3833 5.48048 19.0733 6.13144 18.8563 6.64292C16.4989 6.30193 14.1585 6.30193 11.8336 6.64292C11.6166 6.13144 11.2911 5.48048 11.0276 5C8.79575 5.37198 6.67235 6.03845 4.6869 6.9529C0.672601 12.8736 -0.41235 18.6548 0.130124 24.3585C2.79599 26.2959 5.36889 27.4739 7.89682 28.2489C8.51679 27.4119 9.07477 26.5129 9.55525 25.5675C8.64079 25.2265 7.77283 24.808 6.93587 24.312C7.15286 24.1571 7.36986 23.9866 7.57135 23.8161C12.6241 26.1255 18.0969 26.1255 23.0876 23.8161C23.3046 23.9866 23.5061 24.1571 23.7231 24.312C22.8861 24.808 22.0182 25.2265 21.1037 25.5675C21.5842 26.5129 22.1422 27.4119 22.7621 28.2489C25.2885 27.4739 27.8769 26.2959 30.5288 24.3585C31.1952 17.7559 29.4733 12.0212 26.0015 6.9529ZM10.2527 20.8402C8.73376 20.8402 7.49382 19.4608 7.49382 17.7714C7.49382 16.082 8.70276 14.7025 10.2527 14.7025C11.7871 14.7025 13.0425 16.082 13.0115 17.7714C13.0115 19.4608 11.7871 20.8402 10.2527 20.8402ZM20.4373 20.8402C18.9183 20.8402 17.6768 19.4608 17.6768 17.7714C17.6768 16.082 18.8873 14.7025 20.4373 14.7025C21.9717 14.7025 23.2271 16.082 23.1961 17.7714C23.1961 19.4608 21.9872 20.8402 20.4373 20.8402Z"})]})}function ed({isOpen:ee,...en}){return(0,ei.jsxs)("svg",{height:"12",width:"12",viewBox:"0 0 16 16",fill:"currentColor",...en,children:[(0,ei.jsx)("path",{fillRule:"evenodd",d:"M4.177 7.823l2.396-2.396A.25.25 0 017 5.604v4.792a.25.25 0 01-.427.177L4.177 8.177a.25.25 0 010-.354z",className:ee?"":"nx-origin-[35%] nx-rotate-180"}),(0,ei.jsx)("path",{fillRule:"evenodd",d:"M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0114.25 16H1.75A1.75 1.75 0 010 14.25V1.75zm1.75-.25a.25.25 0 00-.25.25v12.5c0 .138.112.25.25.25H9.5v-13H1.75zm12.5 13H11v-13h3.25a.25.25 0 01.25.25v12.5a.25.25 0 01-.25.25z"})]})}function ef(ee){return(0,ei.jsxs)("svg",{width:"24",height:"24",fill:"currentColor",viewBox:"3 3 18 18",...ee,children:[(0,ei.jsx)("title",{children:"GitHub"}),(0,ei.jsx)("path",{d:"M12 3C7.0275 3 3 7.12937 3 12.2276C3 16.3109 5.57625 19.7597 9.15374 20.9824C9.60374 21.0631 9.77249 20.7863 9.77249 20.5441C9.77249 20.3249 9.76125 19.5982 9.76125 18.8254C7.5 19.2522 6.915 18.2602 6.735 17.7412C6.63375 17.4759 6.19499 16.6569 5.8125 16.4378C5.4975 16.2647 5.0475 15.838 5.80124 15.8264C6.51 15.8149 7.01625 16.4954 7.18499 16.7723C7.99499 18.1679 9.28875 17.7758 9.80625 17.5335C9.885 16.9337 10.1212 16.53 10.38 16.2993C8.3775 16.0687 6.285 15.2728 6.285 11.7432C6.285 10.7397 6.63375 9.9092 7.20749 9.26326C7.1175 9.03257 6.8025 8.08674 7.2975 6.81794C7.2975 6.81794 8.05125 6.57571 9.77249 7.76377C10.4925 7.55615 11.2575 7.45234 12.0225 7.45234C12.7875 7.45234 13.5525 7.55615 14.2725 7.76377C15.9937 6.56418 16.7475 6.81794 16.7475 6.81794C17.2424 8.08674 16.9275 9.03257 16.8375 9.26326C17.4113 9.9092 17.76 10.7281 17.76 11.7432C17.76 15.2843 15.6563 16.0687 13.6537 16.2993C13.98 16.5877 14.2613 17.1414 14.2613 18.0065C14.2613 19.2407 14.25 20.2326 14.25 20.5441C14.25 20.7863 14.4188 21.0746 14.8688 20.9824C16.6554 20.364 18.2079 19.1866 19.3078 17.6162C20.4077 16.0457 20.9995 14.1611 21 12.2276C21 7.12937 16.9725 3 12 3Z"})]})}function eh(ee){return(0,ei.jsx)("svg",{viewBox:"2 2 16 16",width:"12",height:"12",fill:"currentColor",...ee,children:(0,ei.jsx)("path",{fillRule:"evenodd",d:"M4.083 9h1.946c.089-1.546.383-2.97.837-4.118A6.004 6.004 0 004.083 9zM10 2a8 8 0 100 16 8 8 0 000-16zm0 2c-.076 0-.232.032-.465.262-.238.234-.497.623-.737 1.182-.389.907-.673 2.142-.766 3.556h3.936c-.093-1.414-.377-2.649-.766-3.556-.24-.56-.5-.948-.737-1.182C10.232 4.032 10.076 4 10 4zm3.971 5c-.089-1.546-.383-2.97-.837-4.118A6.004 6.004 0 0115.917 9h-1.946zm-2.003 2H8.032c.093 1.414.377 2.649.766 3.556.24.56.5.948.737 1.182.233.23.389.262.465.262.076 0 .232-.032.465-.262.238-.234.498-.623.737-1.182.389-.907.673-2.142.766-3.556zm1.166 4.118c.454-1.147.748-2.572.837-4.118h1.946a6.004 6.004 0 01-2.783 4.118zm-6.268 0C6.412 13.97 6.118 12.546 6.03 11H4.083a6.004 6.004 0 002.783 4.118z",clipRule:"evenodd"})})}function ep(ee){return(0,ei.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",width:"20",height:"20",...ee,children:(0,ei.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z"})})}function em(ee){return(0,ei.jsxs)("svg",{fill:"none",width:"24",height:"24",viewBox:"0 0 24 24",stroke:"currentColor",...ee,children:[(0,ei.jsx)("g",{children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M4 6h16"})}),(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M4 12h16"}),(0,ei.jsx)("g",{children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M4 18h16"})})]})}function ex(ee){return(0,ei.jsx)("svg",{fill:"none",viewBox:"2 2 20 20",width:"12",height:"12",stroke:"currentColor",...ee,children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",fill:"currentColor",d:"M20.354 15.354A9 9 0 018.646 3.646 9.003 9.003 0 0012 21a9.003 9.003 0 008.354-5.646z"})})}function eg(ee){return(0,ei.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",width:"24",height:"24",...ee,children:[(0,ei.jsx)("circle",{className:"nx-opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),(0,ei.jsx)("path",{className:"nx-opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]})}function ev(ee){return(0,ei.jsx)("svg",{fill:"none",viewBox:"3 3 18 18",width:"12",height:"12",stroke:"currentColor",...ee,children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",fill:"currentColor",d:"M12 3v1m0 16v1m9-9h-1M4 12H3m15.364 6.364l-.707-.707M6.343 6.343l-.707-.707m12.728 0l-.707.707M6.343 17.657l-.707.707M16 12a4 4 0 11-8 0 4 4 0 018 0z"})})}function ey(ee){return(0,ei.jsx)("svg",{viewBox:"0 0 24 24",width:"24",height:"24",...ee,children:(0,ei.jsx)("path",{fill:"currentColor",d:"M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3l3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"})})}function eb(ee){return(0,ei.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"currentColor",...ee,children:(0,ei.jsx)("path",{fillRule:"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",clipRule:"evenodd"})})}},3443:function(ee,en,er){"use strict";er.d(en,{Z:function(){return ec},a:function(){return ep}});var ei=er(959);let eo=ei.createContext({});function es(ee){let en=ei.useContext(eo);return ei.useMemo(()=>"function"==typeof ee?ee(en):{...en,...ee},[en,ee])}let eu={};function ec({components:ee,children:en,disableParentContext:er}){let ec;return ec=er?"function"==typeof ee?ee({}):ee||eu:es(ee),ei.createElement(eo.Provider,{value:ec},en)}var ed=er(2389),ef=er.n(ed),eh={img:ee=>(0,ei.createElement)("object"==typeof ee.src?ef():"img",ee)},ep=ee=>es({...eh,...ee})},5182:function(ee,en,er){"use strict";var ei=er(6097);function eo(ee){var en={protocols:[],protocol:null,port:null,resource:"",host:"",user:"",password:"",pathname:"",hash:"",search:"",href:ee,query:{},parse_failed:!1};try{var er=new URL(ee);en.protocols=ei(er),en.protocol=en.protocols[0],en.port=er.port,en.resource=er.hostname,en.host=er.host,en.user=er.username||"",en.password=er.password||"",en.pathname=er.pathname,en.hash=er.hash.slice(1),en.search=er.search.slice(1),en.href=er.href,en.query=Object.fromEntries(er.searchParams)}catch(er){en.protocols=["file"],en.protocol=en.protocols[0],en.port="",en.resource="",en.user="",en.pathname="",en.hash="",en.search="",en.href=ee,en.query={},en.parse_failed=!0}return en}ee.exports=eo},8593:function(ee,en,er){"use strict";var ei=function(ee){return ee&&"object"==typeof ee&&"default"in ee?ee:{default:ee}}(er(5182));let eo="text/plain",es="us-ascii",eu=(ee,en)=>en.some(en=>en instanceof RegExp?en.test(ee):en===ee),ec=(ee,{stripHash:en})=>{let er=/^data:(?[^,]*?),(?[^#]*?)(?:#(?.*))?$/.exec(ee);if(!er)throw Error(`Invalid URL: ${ee}`);let{type:ei,data:eu,hash:ec}=er.groups,ed=ei.split(";");ec=en?"":ec;let ef=!1;"base64"===ed[ed.length-1]&&(ed.pop(),ef=!0);let eh=(ed.shift()||"").toLowerCase(),ep=ed.map(ee=>{let[en,er=""]=ee.split("=").map(ee=>ee.trim());return"charset"===en&&(er=er.toLowerCase())===es?"":`${en}${er?`=${er}`:""}`}).filter(Boolean),em=[...ep];return ef&&em.push("base64"),(em.length>0||eh&&eh!==eo)&&em.unshift(eh),`data:${em.join(";")},${ef?eu.trim():eu}${ec?`#${ec}`:""}`};function ed(ee,en){if(en={defaultProtocol:"http:",normalizeProtocol:!0,forceHttp:!1,forceHttps:!1,stripAuthentication:!0,stripHash:!1,stripTextFragment:!0,stripWWW:!0,removeQueryParameters:[/^utm_\w+/i],removeTrailingSlash:!0,removeSingleSlash:!0,removeDirectoryIndex:!1,sortQueryParameters:!0,...en},ee=ee.trim(),/^data:/i.test(ee))return ec(ee,en);if(/^view-source:/i.test(ee))throw Error("`view-source:` is not supported as it is a non-standard protocol");let er=ee.startsWith("//"),ei=!er&&/^\.*\//.test(ee);ei||(ee=ee.replace(/^(?!(?:\w+:)?\/\/)|^\/\//,en.defaultProtocol));let eo=new URL(ee);if(en.forceHttp&&en.forceHttps)throw Error("The `forceHttp` and `forceHttps` options cannot be used together");if(en.forceHttp&&"https:"===eo.protocol&&(eo.protocol="http:"),en.forceHttps&&"http:"===eo.protocol&&(eo.protocol="https:"),en.stripAuthentication&&(eo.username="",eo.password=""),en.stripHash?eo.hash="":en.stripTextFragment&&(eo.hash=eo.hash.replace(/#?:~:text.*?$/i,"")),eo.pathname){let ee=/\b[a-z][a-z\d+\-.]{1,50}:\/\//g,en=0,er="";for(;;){let ei=ee.exec(eo.pathname);if(!ei)break;let es=ei[0],eu=ei.index,ec=eo.pathname.slice(en,eu);er+=ec.replace(/\/{2,}/g,"/")+es,en=eu+es.length}let ei=eo.pathname.slice(en,eo.pathname.length);er+=ei.replace(/\/{2,}/g,"/"),eo.pathname=er}if(eo.pathname)try{eo.pathname=decodeURI(eo.pathname)}catch{}if(!0===en.removeDirectoryIndex&&(en.removeDirectoryIndex=[/^index\.[a-z]+$/]),Array.isArray(en.removeDirectoryIndex)&&en.removeDirectoryIndex.length>0){let ee=eo.pathname.split("/"),er=ee[ee.length-1];eu(er,en.removeDirectoryIndex)&&(ee=ee.slice(0,-1),eo.pathname=ee.slice(1).join("/")+"/")}if(eo.hostname&&(eo.hostname=eo.hostname.replace(/\.$/,""),en.stripWWW&&/^www\.(?!www\.)[a-z\-\d]{1,63}\.[a-z.\-\d]{2,63}$/.test(eo.hostname)&&(eo.hostname=eo.hostname.replace(/^www\./,""))),Array.isArray(en.removeQueryParameters))for(let ee of[...eo.searchParams.keys()])eu(ee,en.removeQueryParameters)&&eo.searchParams.delete(ee);if(!0===en.removeQueryParameters&&(eo.search=""),en.sortQueryParameters){eo.searchParams.sort();try{eo.search=decodeURIComponent(eo.search)}catch{}}en.removeTrailingSlash&&(eo.pathname=eo.pathname.replace(/\/$/,""));let es=ee;return ee=eo.toString(),en.removeSingleSlash||"/"!==eo.pathname||es.endsWith("/")||""!==eo.hash||(ee=ee.replace(/\/$/,"")),(en.removeTrailingSlash||"/"===eo.pathname)&&""===eo.hash&&en.removeSingleSlash&&(ee=ee.replace(/\/$/,"")),er&&!en.normalizeProtocol&&(ee=ee.replace(/^http:\/\//,"//")),en.stripProtocol&&(ee=ee.replace(/^(?:https?:)?\/\//,"")),ee}let ef=(ee,en=!1)=>{let er=/^(?:([a-z_][a-z0-9_-]{0,31})@|https?:\/\/)([\w\.\-@]+)[\/:]([\~,\.\w,\-,\_,\/]+?(?:\.git|\/)?)$/,eo=en=>{let er=Error(en);throw er.subject_url=ee,er};"string"==typeof ee&&ee.trim()||eo("Invalid url."),ee.length>ef.MAX_INPUT_LENGTH&&eo("Input exceeds maximum length. If needed, change the value of parseUrl.MAX_INPUT_LENGTH."),en&&("object"!=typeof en&&(en={stripHash:!1}),ee=ed(ee,en));let es=ei.default(ee);if(es.parse_failed){let ee=es.href.match(er);ee?(es.protocols=["ssh"],es.protocol="ssh",es.resource=ee[2],es.host=ee[2],es.user=ee[1],es.pathname=`/${ee[3]}`,es.parse_failed=!1):eo("URL parsing failed.")}return es};ef.MAX_INPUT_LENGTH=2048,ee.exports=ef},6097:function(ee){"use strict";ee.exports=function(ee,en){!0===en&&(en=0);var er="";if("string"==typeof ee)try{er=new URL(ee).protocol}catch(ee){}else ee&&ee.constructor===URL&&(er=ee.protocol);var ei=er.split(/\:|\+/).filter(Boolean);return"number"==typeof en?ei[en]:ei}},6593:function(ee){var en={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",Ấ:"A",Ắ:"A",Ẳ:"A",Ẵ:"A",Ặ:"A",Æ:"AE",Ầ:"A",Ằ:"A",Ȃ:"A",Ç:"C",Ḉ:"C",È:"E",É:"E",Ê:"E",Ë:"E",Ế:"E",Ḗ:"E",Ề:"E",Ḕ:"E",Ḝ:"E",Ȇ:"E",Ì:"I",Í:"I",Î:"I",Ï:"I",Ḯ:"I",Ȋ:"I",Ð:"D",Ñ:"N",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",Ố:"O",Ṍ:"O",Ṓ:"O",Ȏ:"O",Ù:"U",Ú:"U",Û:"U",Ü:"U",Ý:"Y",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",ấ:"a",ắ:"a",ẳ:"a",ẵ:"a",ặ:"a",æ:"ae",ầ:"a",ằ:"a",ȃ:"a",ç:"c",ḉ:"c",è:"e",é:"e",ê:"e",ë:"e",ế:"e",ḗ:"e",ề:"e",ḕ:"e",ḝ:"e",ȇ:"e",ì:"i",í:"i",î:"i",ï:"i",ḯ:"i",ȋ:"i",ð:"d",ñ:"n",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",ố:"o",ṍ:"o",ṓ:"o",ȏ:"o",ù:"u",ú:"u",û:"u",ü:"u",ý:"y",ÿ:"y",Ā:"A",ā:"a",Ă:"A",ă:"a",Ą:"A",ą:"a",Ć:"C",ć:"c",Ĉ:"C",ĉ:"c",Ċ:"C",ċ:"c",Č:"C",č:"c",C̆:"C",c̆:"c",Ď:"D",ď:"d",Đ:"D",đ:"d",Ē:"E",ē:"e",Ĕ:"E",ĕ:"e",Ė:"E",ė:"e",Ę:"E",ę:"e",Ě:"E",ě:"e",Ĝ:"G",Ǵ:"G",ĝ:"g",ǵ:"g",Ğ:"G",ğ:"g",Ġ:"G",ġ:"g",Ģ:"G",ģ:"g",Ĥ:"H",ĥ:"h",Ħ:"H",ħ:"h",Ḫ:"H",ḫ:"h",Ĩ:"I",ĩ:"i",Ī:"I",ī:"i",Ĭ:"I",ĭ:"i",Į:"I",į:"i",İ:"I",ı:"i",IJ:"IJ",ij:"ij",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",Ḱ:"K",ḱ:"k",K̆:"K",k̆:"k",Ĺ:"L",ĺ:"l",Ļ:"L",ļ:"l",Ľ:"L",ľ:"l",Ŀ:"L",ŀ:"l",Ł:"l",ł:"l",Ḿ:"M",ḿ:"m",M̆:"M",m̆:"m",Ń:"N",ń:"n",Ņ:"N",ņ:"n",Ň:"N",ň:"n",ʼn:"n",N̆:"N",n̆:"n",Ō:"O",ō:"o",Ŏ:"O",ŏ:"o",Ő:"O",ő:"o",Œ:"OE",œ:"oe",P̆:"P",p̆:"p",Ŕ:"R",ŕ:"r",Ŗ:"R",ŗ:"r",Ř:"R",ř:"r",R̆:"R",r̆:"r",Ȓ:"R",ȓ:"r",Ś:"S",ś:"s",Ŝ:"S",ŝ:"s",Ş:"S",Ș:"S",ș:"s",ş:"s",Š:"S",š:"s",Ţ:"T",ţ:"t",ț:"t",Ț:"T",Ť:"T",ť:"t",Ŧ:"T",ŧ:"t",T̆:"T",t̆:"t",Ũ:"U",ũ:"u",Ū:"U",ū:"u",Ŭ:"U",ŭ:"u",Ů:"U",ů:"u",Ű:"U",ű:"u",Ų:"U",ų:"u",Ȗ:"U",ȗ:"u",V̆:"V",v̆:"v",Ŵ:"W",ŵ:"w",Ẃ:"W",ẃ:"w",X̆:"X",x̆:"x",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Y̆:"Y",y̆:"y",Ź:"Z",ź:"z",Ż:"Z",ż:"z",Ž:"Z",ž:"z",ſ:"s",ƒ:"f",Ơ:"O",ơ:"o",Ư:"U",ư:"u",Ǎ:"A",ǎ:"a",Ǐ:"I",ǐ:"i",Ǒ:"O",ǒ:"o",Ǔ:"U",ǔ:"u",Ǖ:"U",ǖ:"u",Ǘ:"U",ǘ:"u",Ǚ:"U",ǚ:"u",Ǜ:"U",ǜ:"u",Ứ:"U",ứ:"u",Ṹ:"U",ṹ:"u",Ǻ:"A",ǻ:"a",Ǽ:"AE",ǽ:"ae",Ǿ:"O",ǿ:"o",Þ:"TH",þ:"th",Ṕ:"P",ṕ:"p",Ṥ:"S",ṥ:"s",X́:"X",x́:"x",Ѓ:"Г",ѓ:"г",Ќ:"К",ќ:"к",A̋:"A",a̋:"a",E̋:"E",e̋:"e",I̋:"I",i̋:"i",Ǹ:"N",ǹ:"n",Ồ:"O",ồ:"o",Ṑ:"O",ṑ:"o",Ừ:"U",ừ:"u",Ẁ:"W",ẁ:"w",Ỳ:"Y",ỳ:"y",Ȁ:"A",ȁ:"a",Ȅ:"E",ȅ:"e",Ȉ:"I",ȉ:"i",Ȍ:"O",ȍ:"o",Ȑ:"R",ȑ:"r",Ȕ:"U",ȕ:"u",B̌:"B",b̌:"b",Č̣:"C",č̣:"c",Ê̌:"E",ê̌:"e",F̌:"F",f̌:"f",Ǧ:"G",ǧ:"g",Ȟ:"H",ȟ:"h",J̌:"J",ǰ:"j",Ǩ:"K",ǩ:"k",M̌:"M",m̌:"m",P̌:"P",p̌:"p",Q̌:"Q",q̌:"q",Ř̩:"R",ř̩:"r",Ṧ:"S",ṧ:"s",V̌:"V",v̌:"v",W̌:"W",w̌:"w",X̌:"X",x̌:"x",Y̌:"Y",y̌:"y",A̧:"A",a̧:"a",B̧:"B",b̧:"b",Ḑ:"D",ḑ:"d",Ȩ:"E",ȩ:"e",Ɛ̧:"E",ɛ̧:"e",Ḩ:"H",ḩ:"h",I̧:"I",i̧:"i",Ɨ̧:"I",ɨ̧:"i",M̧:"M",m̧:"m",O̧:"O",o̧:"o",Q̧:"Q",q̧:"q",U̧:"U",u̧:"u",X̧:"X",x̧:"x",Z̧:"Z",z̧:"z"},er=Object.keys(en).join("|"),ei=RegExp(er,"g"),eo=RegExp(er,""),es=function(ee){return ee.replace(ei,function(ee){return en[ee]})},eu=function(ee){return!!ee.match(eo)};ee.exports=es,ee.exports.has=eu,ee.exports.remove=es},8246:function(ee,en,er){"use strict";er.d(en,{R:function(){return eo}});var ei,eo=((ei=eo||{}).Space=" ",ei.Enter="Enter",ei.Escape="Escape",ei.Backspace="Backspace",ei.Delete="Delete",ei.ArrowLeft="ArrowLeft",ei.ArrowUp="ArrowUp",ei.ArrowRight="ArrowRight",ei.ArrowDown="ArrowDown",ei.Home="Home",ei.End="End",ei.PageUp="PageUp",ei.PageDown="PageDown",ei.Tab="Tab",ei)},6510:function(ee,en,er){"use strict";er.d(en,{z:function(){return es}});var ei=er(959),eo=er(9691);let es=function(ee){let en=(0,eo.E)(ee);return ei.useCallback((...ee)=>en.current(...ee),[en])}},9038:function(ee,en,er){"use strict";er.d(en,{M:function(){return ed}});var ei,eo=er(959),es=er(6260),eu=er(674),ec=er(6030);let ed=null!=(ei=eo.useId)?ei:function(){let ee=(0,eu.H)(),[en,er]=eo.useState(ee?()=>ec.O.nextId():null);return(0,es.e)(()=>{null===en&&er(ec.O.nextId())},[en]),null!=en?""+en:void 0}},5782:function(ee,en,er){"use strict";er.d(en,{t:function(){return es}});var ei=er(959),eo=er(6260);function es(){let ee=(0,ei.useRef)(!1);return(0,eo.e)(()=>(ee.current=!0,()=>{ee.current=!1}),[]),ee}},6260:function(ee,en,er){"use strict";er.d(en,{e:function(){return es}});var ei=er(959),eo=er(6030);let es=(ee,en)=>{eo.O.isServer?(0,ei.useEffect)(ee,en):(0,ei.useLayoutEffect)(ee,en)}},9691:function(ee,en,er){"use strict";er.d(en,{E:function(){return es}});var ei=er(959),eo=er(6260);function es(ee){let en=(0,ei.useRef)(ee);return(0,eo.e)(()=>{en.current=ee},[ee]),en}},8002:function(ee,en,er){"use strict";er.d(en,{f:function(){return eu}});var ei=er(959),eo=er(6260);function es(ee){var en;if(ee.type)return ee.type;let er=null!=(en=ee.as)?en:"button";if("string"==typeof er&&"button"===er.toLowerCase())return"button"}function eu(ee,en){let[er,eu]=(0,ei.useState)(()=>es(ee));return(0,eo.e)(()=>{eu(es(ee))},[ee.type,ee.as]),(0,eo.e)(()=>{er||en.current&&en.current instanceof HTMLButtonElement&&!en.current.hasAttribute("type")&&eu("button")},[er,en]),er}},674:function(ee,en,er){"use strict";er.d(en,{H:function(){return ec}});var ei,eo=er(959),es=er(6030);function eu(){let ee="undefined"==typeof document;return(0,(ei||(ei=er.t(eo,2))).useSyncExternalStore)(()=>()=>{},()=>!1,()=>!ee)}function ec(){let ee=eu(),[en,er]=eo.useState(es.O.isHandoffComplete);return en&&!1===es.O.isHandoffComplete&&er(!1),eo.useEffect(()=>{!0!==en&&er(!0)},[en]),eo.useEffect(()=>es.O.handoff(),[]),!ee&&en}},9850:function(ee,en,er){"use strict";er.d(en,{T:function(){return eu}});var ei=er(959),eo=er(6510);let es=Symbol();function eu(...ee){let en=(0,ei.useRef)(ee);(0,ei.useEffect)(()=>{en.current=ee},[ee]);let er=(0,eo.z)(ee=>{for(let er of en.current)null!=er&&("function"==typeof er?er(ee):er.current=ee)});return ee.every(ee=>null==ee||(null==ee?void 0:ee[es]))?void 0:er}},1941:function(ee,en,er){"use strict";er.d(en,{A:function(){return eu},_:function(){return ed}});var ei,eo=er(222);let es="div";var eu=((ei=eu||{})[ei.None=1]="None",ei[ei.Focusable=2]="Focusable",ei[ei.Hidden=4]="Hidden",ei);function ec(ee,en){let{features:er=1,...ei}=ee,eu={ref:en,"aria-hidden":(2&er)==2||void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(4&er)==4&&(2&er)!=2&&{display:"none"}}};return(0,eo.sY)({ourProps:eu,theirProps:ei,slot:{},defaultTag:es,name:"Hidden"})}let ed=(0,eo.yV)(ec)},3659:function(ee,en,er){"use strict";function ei(...ee){return Array.from(new Set(ee.flatMap(ee=>"string"==typeof ee?ee.split(" "):[]))).filter(Boolean).join(" ")}er.d(en,{A:function(){return ei}})},5012:function(ee,en,er){"use strict";er.d(en,{k:function(){return eo}});var ei=er(1287);function eo(){let ee=[],en={addEventListener:(ee,er,ei,eo)=>(ee.addEventListener(er,ei,eo),en.add(()=>ee.removeEventListener(er,ei,eo))),requestAnimationFrame(...ee){let er=requestAnimationFrame(...ee);return en.add(()=>cancelAnimationFrame(er))},nextFrame:(...ee)=>en.requestAnimationFrame(()=>en.requestAnimationFrame(...ee)),setTimeout(...ee){let er=setTimeout(...ee);return en.add(()=>clearTimeout(er))},microTask(...ee){let er={current:!0};return(0,ei.Y)(()=>{er.current&&ee[0]()}),en.add(()=>{er.current=!1})},style(ee,en,er){let ei=ee.style.getPropertyValue(en);return Object.assign(ee.style,{[en]:er}),this.add(()=>{Object.assign(ee.style,{[en]:ei})})},group(ee){let en=eo();return ee(en),this.add(()=>en.dispose())},add:en=>(ee.push(en),()=>{let er=ee.indexOf(en);if(er>=0)for(let en of ee.splice(er,1))en()}),dispose(){for(let en of ee.splice(0))en()}};return en}},6030:function(ee,en,er){"use strict";er.d(en,{O:function(){return ec}});var ei=Object.defineProperty,eo=(ee,en,er)=>en in ee?ei(ee,en,{enumerable:!0,configurable:!0,writable:!0,value:er}):ee[en]=er,es=(ee,en,er)=>(eo(ee,"symbol"!=typeof en?en+"":en,er),er);class eu{constructor(){es(this,"current",this.detect()),es(this,"handoffState","pending"),es(this,"currentId",0)}set(ee){this.current!==ee&&(this.handoffState="pending",this.currentId=0,this.current=ee)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return"server"===this.current}get isClient(){return"client"===this.current}detect(){return"undefined"==typeof window||"undefined"==typeof document?"server":"client"}handoff(){"pending"===this.handoffState&&(this.handoffState="complete")}get isHandoffComplete(){return"complete"===this.handoffState}}let ec=new eu},7496:function(ee,en,er){"use strict";er.d(en,{EO:function(){return eS},TO:function(){return em},fE:function(){return ex},jA:function(){return eO},sP:function(){return eb},tJ:function(){return ey},wI:function(){return ek},z2:function(){return ej}});var ei,eo,es,eu,ec,ed=er(5012),ef=er(3011),eh=er(9195);let ep=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(ee=>`${ee}:not([tabindex='-1'])`).join(",");var em=((ei=em||{})[ei.First=1]="First",ei[ei.Previous=2]="Previous",ei[ei.Next=4]="Next",ei[ei.Last=8]="Last",ei[ei.WrapAround=16]="WrapAround",ei[ei.NoScroll=32]="NoScroll",ei),ex=((eo=ex||{})[eo.Error=0]="Error",eo[eo.Overflow=1]="Overflow",eo[eo.Success=2]="Success",eo[eo.Underflow=3]="Underflow",eo),eg=((es=eg||{})[es.Previous=-1]="Previous",es[es.Next=1]="Next",es);function ev(ee=document.body){return null==ee?[]:Array.from(ee.querySelectorAll(ep)).sort((ee,en)=>Math.sign((ee.tabIndex||Number.MAX_SAFE_INTEGER)-(en.tabIndex||Number.MAX_SAFE_INTEGER)))}var ey=((eu=ey||{})[eu.Strict=0]="Strict",eu[eu.Loose=1]="Loose",eu);function eb(ee,en=0){var er;return ee!==(null==(er=(0,eh.r)(ee))?void 0:er.body)&&(0,ef.E)(en,{0:()=>ee.matches(ep),1(){let en=ee;for(;null!==en;){if(en.matches(ep))return!0;en=en.parentElement}return!1}})}function ek(ee){let en=(0,eh.r)(ee);(0,ed.k)().nextFrame(()=>{en&&!eb(en.activeElement,0)&&e_(ee)})}var ew=((ec=ew||{})[ec.Keyboard=0]="Keyboard",ec[ec.Mouse=1]="Mouse",ec);function e_(ee){null==ee||ee.focus({preventScroll:!0})}"undefined"!=typeof window&&"undefined"!=typeof document&&(document.addEventListener("keydown",ee=>{ee.metaKey||ee.altKey||ee.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",ee=>{1===ee.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===ee.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));let eC="textarea,input";function eE(ee){var en,er;return null!=(er=null==(en=null==ee?void 0:ee.matches)?void 0:en.call(ee,eC))&&er}function ej(ee,en=ee=>ee){return ee.slice().sort((ee,er)=>{let ei=en(ee),eo=en(er);if(null===ei||null===eo)return 0;let es=ei.compareDocumentPosition(eo);return es&Node.DOCUMENT_POSITION_FOLLOWING?-1:es&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function eS(ee,en){return eO(ev(),en,{relativeTo:ee})}function eO(ee,en,{sorted:er=!0,relativeTo:ei=null,skipElements:eo=[]}={}){let es=Array.isArray(ee)?ee.length>0?ee[0].ownerDocument:document:ee.ownerDocument,eu=Array.isArray(ee)?er?ej(ee):ee:ev(ee);eo.length>0&&eu.length>1&&(eu=eu.filter(ee=>!eo.includes(ee))),ei=null!=ei?ei:es.activeElement;let ec=(()=>{if(5&en)return 1;if(10&en)return -1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),ed=(()=>{if(1&en)return 0;if(2&en)return Math.max(0,eu.indexOf(ei))-1;if(4&en)return Math.max(0,eu.indexOf(ei))+1;if(8&en)return eu.length-1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),ef=32&en?{preventScroll:!0}:{},eh=0,ep=eu.length,em;do{if(eh>=ep||eh+ep<=0)return 0;let ee=ed+eh;if(16&en)ee=(ee+ep)%ep;else{if(ee<0)return 3;if(ee>=ep)return 1}null==(em=eu[ee])||em.focus(ef),eh+=ec}while(em!==es.activeElement);return 6&en&&eE(em)&&em.select(),2}},3011:function(ee,en,er){"use strict";function ei(ee,en,...er){if(ee in en){let ei=en[ee];return"function"==typeof ei?ei(...er):ei}let eo=Error(`Tried to handle "${ee}" but there is no handler defined. Only defined handlers are: ${Object.keys(en).map(ee=>`"${ee}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(eo,ei),eo}er.d(en,{E:function(){return ei}})},1287:function(ee,en,er){"use strict";function ei(ee){"function"==typeof queueMicrotask?queueMicrotask(ee):Promise.resolve().then(ee).catch(ee=>setTimeout(()=>{throw ee}))}er.d(en,{Y:function(){return ei}})},9195:function(ee,en,er){"use strict";er.d(en,{r:function(){return eo}});var ei=er(6030);function eo(ee){return ei.O.isServer?null:ee instanceof Node?ee.ownerDocument:null!=ee&&ee.hasOwnProperty("current")&&ee.current instanceof Node?ee.current.ownerDocument:document}},222:function(ee,en,er){"use strict";er.d(en,{AN:function(){return ed},l4:function(){return ef},oA:function(){return ev},sY:function(){return eh},yV:function(){return eg}});var ei,eo,es=er(959),eu=er(3659),ec=er(3011),ed=((ei=ed||{})[ei.None=0]="None",ei[ei.RenderStrategy=1]="RenderStrategy",ei[ei.Static=2]="Static",ei),ef=((eo=ef||{})[eo.Unmount=0]="Unmount",eo[eo.Hidden=1]="Hidden",eo);function eh({ourProps:ee,theirProps:en,slot:er,defaultTag:ei,features:eo,visible:es=!0,name:eu}){let ed=ex(en,ee);if(es)return ep(ed,er,ei,eu);let ef=null!=eo?eo:0;if(2&ef){let{static:ee=!1,...en}=ed;if(ee)return ep(en,er,ei,eu)}if(1&ef){let{unmount:ee=!0,...en}=ed;return(0,ec.E)(ee?0:1,{0:()=>null,1:()=>ep({...en,hidden:!0,style:{display:"none"}},er,ei,eu)})}return ep(ed,er,ei,eu)}function ep(ee,en={},er,ei){let{as:eo=er,children:ec,refName:ed="ref",...ef}=ey(ee,["unmount","static"]),eh=void 0!==ee.ref?{[ed]:ee.ref}:{},ep="function"==typeof ec?ec(en):ec;"className"in ef&&ef.className&&"function"==typeof ef.className&&(ef.className=ef.className(en));let eg={};if(en){let ee=!1,er=[];for(let[ei,eo]of Object.entries(en))"boolean"==typeof eo&&(ee=!0),!0===eo&&er.push(ei);ee&&(eg["data-headlessui-state"]=er.join(" "))}if(eo===es.Fragment&&Object.keys(ev(ef)).length>0){if(!(0,es.isValidElement)(ep)||Array.isArray(ep)&&ep.length>1)throw Error(['Passing props on "Fragment"!',"",`The current component <${ei} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(ef).map(ee=>` - ${ee}`).join(` + `}),eo]})]})}var sG={link:(0,ej.Z)("nx-flex nx-max-w-[50%] nx-items-center nx-gap-1 nx-py-4 nx-text-base nx-font-medium nx-text-gray-600 nx-transition-colors [word-break:break-word] hover:nx-text-primary-600 dark:nx-text-gray-300 md:nx-text-lg"),icon:(0,ej.Z)("nx-inline nx-h-5 nx-shrink-0")},sU=({flatDirectories:ee,currentIndex:en})=>{let er=sh(),ei=er.navigation,eo="boolean"==typeof ei?{prev:ei,next:ei}:ei,es=eo.prev&&ee[en-1],eu=eo.next&&ee[en+1];return(es&&!es.isUnderCurrentDocsTree&&(es=!1),eu&&!eu.isUnderCurrentDocsTree&&(eu=!1),es||eu)?(0,e_.jsxs)("div",{className:(0,ej.Z)("nx-mb-8 nx-flex nx-items-center nx-border-t nx-pt-8 dark:nx-border-neutral-800","contrast-more:nx-border-neutral-400 dark:contrast-more:nx-border-neutral-400","print:nx-hidden"),children:[es&&(0,e_.jsxs)(sy,{href:es.route,title:es.title,className:(0,ej.Z)(sG.link,"ltr:nx-pr-4 rtl:nx-pl-4"),children:[(0,e_.jsx)(eP.LZ,{className:(0,ej.Z)(sG.icon,"ltr:nx-rotate-180")}),es.title]}),eu&&(0,e_.jsxs)(sy,{href:eu.route,title:eu.title,className:(0,ej.Z)(sG.link,"ltr:nx-ml-auto ltr:nx-pl-4 ltr:nx-text-right rtl:nx-mr-auto rtl:nx-pr-4 rtl:nx-text-left"),children:[eu.title,(0,e_.jsx)(eP.LZ,{className:(0,ej.Z)(sG.icon,"rtl:nx-rotate-180")})]})]}):null},sW={link:(0,ej.Z)("nx-text-sm contrast-more:nx-text-gray-700 contrast-more:dark:nx-text-gray-100"),active:(0,ej.Z)("nx-font-medium nx-subpixel-antialiased"),inactive:(0,ej.Z)("nx-text-gray-600 hover:nx-text-gray-800 dark:nx-text-gray-400 dark:hover:nx-text-gray-200")};function sV({className:ee,menu:en,children:er}){let{items:ei}=en,eo=Object.fromEntries((en.children||[]).map(ee=>[ee.name,ee]));return(0,e_.jsx)("div",{className:"nx-relative nx-inline-block",children:(0,e_.jsxs)(o_,{children:[(0,e_.jsx)(o_.Button,{className:(0,ej.Z)(ee,"-nx-ml-2 nx-hidden nx-items-center nx-whitespace-nowrap nx-rounded nx-p-2 md:nx-inline-flex",sW.inactive),children:er}),(0,e_.jsx)(an,{leave:"nx-transition-opacity",leaveFrom:"nx-opacity-100",leaveTo:"nx-opacity-0",children:(0,e_.jsx)(o_.Items,{className:"nx-absolute nx-right-0 nx-z-20 nx-mt-1 nx-max-h-64 nx-min-w-full nx-overflow-auto nx-rounded-md nx-ring-1 nx-ring-black/5 nx-bg-white nx-py-1 nx-text-sm nx-shadow-lg dark:nx-ring-white/20 dark:nx-bg-neutral-800",tabIndex:0,children:Object.entries(ei||{}).map(([ee,er])=>{var ei;return(0,e_.jsx)(o_.Item,{children:(0,e_.jsx)(sy,{href:er.href||(null==(ei=eo[ee])?void 0:ei.route)||en.route+"/"+ee,className:(0,ej.Z)("nx-relative nx-hidden nx-w-full nx-select-none nx-whitespace-nowrap nx-text-gray-600 hover:nx-text-gray-900 dark:nx-text-gray-400 dark:hover:nx-text-gray-100 md:nx-inline-block","nx-py-1.5 nx-transition-colors ltr:nx-pl-3 ltr:nx-pr-9 rtl:nx-pr-3 rtl:nx-pl-9"),newWindow:er.newWindow,children:er.title||ee})},ee)})})})]})})}function sH({flatDirectories:ee,items:en}){let er=sh(),ei=eT(),{menu:eo,setMenu:es}=sc();return(0,e_.jsxs)("div",{className:"nextra-nav-container nx-sticky nx-top-0 nx-z-20 nx-w-full nx-bg-transparent print:nx-hidden",children:[(0,e_.jsx)("div",{className:(0,ej.Z)("nextra-nav-container-blur","nx-pointer-events-none nx-absolute nx-z-[-1] nx-h-full nx-w-full nx-bg-white dark:nx-bg-dark","nx-shadow-[0_2px_4px_rgba(0,0,0,.02),0_1px_0_rgba(0,0,0,.06)] dark:nx-shadow-[0_-1px_0_rgba(255,255,255,.1)_inset]","contrast-more:nx-shadow-[0_0_0_1px_#000] contrast-more:dark:nx-shadow-[0_0_0_1px_#fff]")}),(0,e_.jsxs)("nav",{className:"nx-mx-auto nx-flex nx-h-[var(--nextra-navbar-height)] nx-max-w-[90rem] nx-items-center nx-justify-end nx-gap-2 nx-pl-[max(env(safe-area-inset-left),1.5rem)] nx-pr-[max(env(safe-area-inset-right),1.5rem)]",children:[er.logoLink?(0,e_.jsx)(sy,{href:"string"==typeof er.logoLink?er.logoLink:"/",className:"nx-flex nx-items-center hover:nx-opacity-75 ltr:nx-mr-auto rtl:nx-ml-auto",children:sk(er.logo)}):(0,e_.jsx)("div",{className:"nx-flex nx-items-center ltr:nx-mr-auto rtl:nx-ml-auto",children:sk(er.logo)}),en.map(ee=>{if("hidden"===ee.display)return null;if("menu"===ee.type){let en=ee;return(0,e_.jsxs)(sV,{className:(0,ej.Z)(sW.link,"nx-flex nx-gap-1",sW.inactive),menu:en,children:[en.title,(0,e_.jsx)(eP.LZ,{className:"nx-h-[18px] nx-min-w-[18px] nx-rounded-sm nx-p-0.5",pathClassName:"nx-origin-center nx-transition-transform nx-rotate-90"})]},en.title)}let en=ee,er=en.href||en.route||"#";en.children&&(er=(en.withIndexPage?en.route:en.firstChildRoute)||er);let eo=en.route===ei||ei.startsWith(en.route+"/");return(0,e_.jsxs)(sy,{href:er,className:(0,ej.Z)(sW.link,"nx-relative -nx-ml-2 nx-hidden nx-whitespace-nowrap nx-p-2 md:nx-inline-block",!eo||en.newWindow?sW.inactive:sW.active),newWindow:en.newWindow,"aria-current":!en.newWindow&&eo,children:[(0,e_.jsx)("span",{className:"nx-absolute nx-inset-x-0 nx-text-center",children:en.title}),(0,e_.jsx)("span",{className:"nx-invisible nx-font-medium",children:en.title})]},er)}),sk(er.search.component,{directories:ee,className:"nx-hidden md:nx-inline-block mx-min-w-[200px]"}),er.project.link?(0,e_.jsx)(sy,{className:"nx-p-2 nx-text-current",href:er.project.link,newWindow:!0,children:sk(er.project.icon)}):null,er.chat.link?(0,e_.jsx)(sy,{className:"nx-p-2 nx-text-current",href:er.chat.link,newWindow:!0,children:sk(er.chat.icon)}):null,sk(er.navbar.extraContent),(0,e_.jsx)("button",{type:"button","aria-label":"Menu",className:"nextra-hamburger -nx-mr-2 nx-rounded nx-p-2 active:nx-bg-gray-400/20 md:nx-hidden",onClick:()=>es(!eo),children:(0,e_.jsx)(eP.Oq,{className:(0,ej.Z)({open:eo})})})]})]})}var sB=Object.create(null),sq=(0,eE.createContext)(null),sK=(0,eE.createContext)(null),sY=(0,eE.createContext)(0),sQ=(0,eE.memo)(function(ee){let en=(0,eE.useContext)(sY);return(0,e_.jsx)(sY.Provider,{value:en+1,children:(0,e_.jsx)(sX,o4({},ee))})}),sJ={link:(0,ej.Z)("nx-flex nx-rounded nx-px-2 nx-py-1.5 nx-text-sm nx-transition-colors [word-break:break-word]","nx-cursor-pointer [-webkit-tap-highlight-color:transparent] [-webkit-touch-callout:none] contrast-more:nx-border"),inactive:(0,ej.Z)("nx-text-gray-500 hover:nx-bg-gray-100 hover:nx-text-gray-900","dark:nx-text-neutral-400 dark:hover:nx-bg-primary-100/5 dark:hover:nx-text-gray-50","contrast-more:nx-text-gray-900 contrast-more:dark:nx-text-gray-50","contrast-more:nx-border-transparent contrast-more:hover:nx-border-gray-900 contrast-more:dark:hover:nx-border-gray-50"),active:(0,ej.Z)("nx-bg-primary-100 nx-font-semibold nx-text-primary-800 dark:nx-bg-primary-400/10 dark:nx-text-primary-600","contrast-more:nx-border-primary-500 contrast-more:dark:nx-border-primary-500"),list:(0,ej.Z)("nx-flex nx-flex-col nx-gap-1"),border:(0,ej.Z)("nx-relative before:nx-absolute before:nx-inset-y-1",'before:nx-w-px before:nx-bg-gray-200 before:nx-content-[""] dark:before:nx-bg-neutral-800',"ltr:nx-pl-3 ltr:before:nx-left-0 rtl:nx-pr-3 rtl:before:nx-right-0")};function sX({item:ee,anchors:en}){let er=eT(),[ei]=er.split("#"),eo=[ei,ei+"/"].includes(ee.route+"/"),es=eo||ei.startsWith(ee.route+"/"),eu=(0,eE.useContext)(sq),ec=!!(null==eu?void 0:eu.startsWith(ee.route+"/")),ed=(0,eE.useContext)(sY),{setMenu:ef}=sc(),eh=sh(),{theme:ep}=ee,em=void 0===sB[ee.route]?eo||es||ec||(ep&&"collapsed"in ep?!ep.collapsed:ed{let en=()=>{(es||ec)&&(sB[ee.route]=!0)},er=()=>{es&&ec?sB[ee.route]=!0:delete sB[ee.route]};eh.sidebar.autoCollapse?er():en()},[es,ec,ee.route,eh.sidebar.autoCollapse]),"menu"===ee.type){let en=ee,er=Object.fromEntries((en.children||[]).map(ee=>[ee.name,ee]));ee.children=Object.entries(en.items||{}).map(([ee,ei])=>{let eo=er[ee]||o5(o4({name:ee},"locale"in en&&{locale:en.locale}),{route:en.route+"/"+ee});return o4(o4({},eo),ei)})}let eg="withIndexPage"in ee&&ee.withIndexPage,ev=eg?sy:"button";return(0,e_.jsxs)("li",{className:(0,ej.Z)({open:em,active:eo}),children:[(0,e_.jsxs)(ev,{href:eg?ee.route:void 0,className:(0,ej.Z)("nx-items-center nx-justify-between nx-gap-2",!eg&&"nx-text-left nx-w-full",sJ.link,eo?sJ.active:sJ.inactive),onClick:en=>{let er=["svg","path"].includes(en.target.tagName.toLowerCase());if(er&&en.preventDefault(),eg){eo||er?sB[ee.route]=!em:(sB[ee.route]=!0,ef(!1)),ex({});return}eo||(sB[ee.route]=!em,ex({}))},children:[sk(eh.sidebar.titleComponent,{title:ee.title,type:ee.type,route:ee.route}),(0,e_.jsx)(eP.LZ,{className:"nx-h-[18px] nx-min-w-[18px] nx-rounded-sm nx-p-0.5 hover:nx-bg-gray-800/5 dark:hover:nx-bg-gray-100/5",pathClassName:(0,ej.Z)("nx-origin-center nx-transition-transform rtl:-nx-rotate-180",em&&"ltr:nx-rotate-90 rtl:nx-rotate-[-270deg]")})]}),(0,e_.jsx)(sS,{className:"ltr:nx-pr-0 rtl:nx-pl-0 nx-pt-1",isOpen:em,children:Array.isArray(ee.children)?(0,e_.jsx)(s2,{className:(0,ej.Z)(sJ.border,"ltr:nx-ml-3 rtl:nx-mr-3"),directories:ee.children,base:ee.route,anchors:en}):null})]})}function s0({title:ee}){let en=sh();return(0,e_.jsx)("li",{className:(0,ej.Z)("[word-break:break-word]",ee?"nx-mt-5 nx-mb-2 nx-px-2 nx-py-1.5 nx-text-sm nx-font-semibold nx-text-gray-900 first:nx-mt-0 dark:nx-text-gray-100":"nx-my-4"),children:ee?sk(en.sidebar.titleComponent,{title:ee,type:"separator",route:""}):(0,e_.jsx)("hr",{className:"nx-mx-2 nx-border-t nx-border-gray-200 dark:nx-border-primary-100/10"})})}function s1({item:ee,anchors:en}){let er=eT(),ei=(0,eE.useContext)(sK),eo=ee.route&&[er,er+"/"].includes(ee.route+"/"),es=sr(),{setMenu:eu}=sc(),ec=sh();return"separator"===ee.type?(0,e_.jsx)(s0,{title:ee.title}):(0,e_.jsxs)("li",{className:(0,ej.Z)(sJ.list,{active:eo}),children:[(0,e_.jsx)(sy,{href:ee.href||ee.route,newWindow:ee.newWindow,className:(0,ej.Z)(sJ.link,eo?sJ.active:sJ.inactive),onClick:()=>{eu(!1)},onFocus:()=>{null==ei||ei(ee.route)},onBlur:()=>{null==ei||ei(null)},children:sk(ec.sidebar.titleComponent,{title:ee.title,type:ee.type,route:ee.route})}),eo&&en.length>0&&(0,e_.jsx)("ul",{className:(0,ej.Z)(sJ.list,sJ.border,"ltr:nx-ml-3 rtl:nx-mr-3"),children:en.map(({id:ee,value:en})=>{var er;return(0,e_.jsx)("li",{children:(0,e_.jsx)("a",{href:`#${ee}`,className:(0,ej.Z)(sJ.link,'nx-flex nx-gap-2 before:nx-opacity-25 before:nx-content-["#"]',(null==(er=es[ee])?void 0:er.isActive)?sJ.active:sJ.inactive),onClick:()=>{eu(!1)},children:en})},ee)})})]})}function s2({directories:ee,anchors:en,className:er,onlyCurrentDocs:ei}){return(0,e_.jsx)("ul",{className:(0,ej.Z)(sJ.list,er),children:ee.map(ee=>!ei||ee.isUnderCurrentDocsTree?"menu"===ee.type||ee.children&&(ee.children.length||!ee.withIndexPage)?(0,e_.jsx)(sQ,{item:ee,anchors:en},ee.name):(0,e_.jsx)(s1,{item:ee,anchors:en},ee.name):null)})}function s4({docsDirectories:ee,flatDirectories:en,fullDirectories:er,asPopover:ei=!1,headings:eo,includePlaceholder:es}){let eu=sh(),{menu:ec,setMenu:ed}=sc(),ef=(0,eC.useRouter)(),[eh,ep]=(0,eE.useState)(null),[em,ex]=(0,eE.useState)(!0),[eg,ev]=(0,eE.useState)(!1),ey=(0,eE.useMemo)(()=>eo.filter(ee=>2===ee.depth),[eo]),eb=(0,eE.useRef)(null),ek=(0,eE.useRef)(null),ew=eS();(0,eE.useEffect)(()=>{ec?document.body.classList.add("nx-overflow-hidden","md:nx-overflow-auto"):document.body.classList.remove("nx-overflow-hidden","md:nx-overflow-auto")},[ec]),(0,eE.useEffect)(()=>{var ee;let en=null==(ee=eb.current)?void 0:ee.querySelector("li.active");if(en&&(window.innerWidth>767||ec)){let ee=()=>{oN(en,{block:"center",inline:"center",scrollMode:"always",boundary:ek.current})};ec?setTimeout(ee,300):ee()}},[ec]),(0,eE.useEffect)(()=>{ed(!1)},[ef.asPath,ed]);let eO=eu.i18n.length>0,eM=eu.darkMode||eO||eu.sidebar.toggleButton;return(0,e_.jsxs)(e_.Fragment,{children:[es&&ei?(0,e_.jsx)("div",{className:"max-xl:nx-hidden nx-h-0 nx-w-64 nx-shrink-0"}):null,(0,e_.jsx)("div",{className:(0,ej.Z)("motion-reduce:nx-transition-none [transition:background-color_1.5s_ease]",ec?"nx-fixed nx-inset-0 nx-z-10 nx-bg-black/80 dark:nx-bg-black/60":"nx-bg-transparent"),onClick:()=>ed(!1)}),(0,e_.jsxs)("aside",{className:(0,ej.Z)("nextra-sidebar-container nx-flex nx-flex-col","md:nx-top-16 md:nx-shrink-0 motion-reduce:nx-transform-none","nx-transform-gpu nx-transition-all nx-ease-in-out","print:nx-hidden",em?"md:nx-w-64":"md:nx-w-20",ei?"md:nx-hidden":"md:nx-sticky md:nx-self-start",ec?"max-md:[transform:translate3d(0,0,0)]":"max-md:[transform:translate3d(0,-100%,0)]"),ref:ek,children:[(0,e_.jsx)("div",{className:"nx-px-4 nx-pt-4 md:nx-hidden",children:sk(eu.search.component,{directories:en})}),(0,e_.jsx)(sq.Provider,{value:eh,children:(0,e_.jsx)(sK.Provider,{value:ee=>{ep(ee)},children:(0,e_.jsxs)("div",{className:(0,ej.Z)("nx-overflow-y-auto nx-overflow-x-hidden","nx-p-4 nx-grow md:nx-h-[calc(100vh-var(--nextra-navbar-height)-var(--nextra-menu-height))]",em?"nextra-scrollbar":"no-scrollbar"),ref:eb,children:[(!ei||!em)&&(0,e_.jsx)(sS,{isOpen:em,horizontal:!0,children:(0,e_.jsx)(s2,{className:"nextra-menu-desktop max-md:nx-hidden",directories:ee,anchors:eu.toc.float?[]:ey,onlyCurrentDocs:!0})}),ew&&window.innerWidth<768&&(0,e_.jsx)(s2,{className:"nextra-menu-mobile md:nx-hidden",directories:er,anchors:ey})]})})}),eM&&(0,e_.jsxs)("div",{className:(0,ej.Z)("nx-sticky nx-bottom-0","nx-bg-white dark:nx-bg-dark","nx-mx-4 nx-py-4 nx-shadow-[0_-12px_16px_#fff]","nx-flex nx-items-center nx-gap-2","dark:nx-border-neutral-800 dark:nx-shadow-[0_-12px_16px_#111]","contrast-more:nx-border-neutral-400 contrast-more:nx-shadow-none contrast-more:dark:nx-shadow-none",em?(0,ej.Z)(eO&&"nx-justify-end","nx-border-t"):"nx-py-4 nx-flex-wrap nx-justify-center"),"data-toggle-animation":eg?em?"show":"hide":"off",children:[(0,e_.jsx)(sD,{lite:!em,className:(0,ej.Z)(em?"nx-grow":"max-md:nx-grow")}),eu.darkMode&&(0,e_.jsx)("div",{className:em&&!eO?"nx-grow nx-flex nx-flex-col":"",children:sk(eu.themeSwitch.component,{lite:!em||eO})}),eu.sidebar.toggleButton&&(0,e_.jsx)("button",{title:em?"Hide sidebar":"Show sidebar",className:"max-md:nx-hidden nx-h-7 nx-rounded-md nx-transition-colors nx-text-gray-600 dark:nx-text-gray-400 nx-px-2 hover:nx-bg-gray-100 hover:nx-text-gray-900 dark:hover:nx-bg-primary-100/5 dark:hover:nx-text-gray-50",onClick:()=>{ex(!em),ev(!0)},children:(0,e_.jsx)(eP.Qq,{isOpen:em})})]})]})]})}var s5="reach-skip-nav",s3="Skip to content";(0,eE.forwardRef)(function(ee,en){var er=ee,{className:ei,id:eo,label:es=s3,styled:eu}=er,ec=o3(er,["className","id","label","styled"]);let ed=void 0===ei?eu?(0,ej.Z)("nx-sr-only","focus:nx-not-sr-only focus:nx-fixed focus:nx-z-50 focus:nx-m-3 focus:nx-ml-4 focus:nx-h-[calc(var(--nextra-navbar-height)-1.5rem)] focus:nx-rounded-lg focus:nx-border focus:nx-px-3 focus:nx-py-2 focus:nx-align-middle focus:nx-text-sm focus:nx-font-bold","focus:nx-text-gray-900 focus:dark:nx-text-gray-100","focus:nx-bg-white focus:dark:nx-bg-neutral-900","focus:nx-border-neutral-400 focus:dark:nx-border-neutral-800"):"":ei;return(0,e_.jsx)("a",o5(o4({},ec),{ref:en,href:`#${eo||s5}`,className:ed,"data-reach-skip-link":"",children:es}))}).displayName="SkipNavLink";var s7=(0,eE.forwardRef)(function(ee,en){var er=ee,{id:ei}=er,eo=o3(er,["id"]);return(0,e_.jsx)("div",o5(o4({},eo),{ref:en,id:ei||s5}))});s7.displayName="SkipNavContent";var s6=nS.strictObject({light:nS.string(),dark:nS.string(),system:nS.string()});function s9({lite:ee,className:en}){let{setTheme:er,resolvedTheme:ei,theme:eo=""}=nL(),es=eS(),eu=sh().themeSwitch,ec=es&&"dark"===ei?eP.kL:eP.NW,ed="function"==typeof eu.useOptions?eu.useOptions():eu.useOptions;return(0,e_.jsx)(sF,{className:en,title:"Change theme",options:[{key:"light",name:ed.light},{key:"dark",name:ed.dark},{key:"system",name:ed.system}],onChange:ee=>{er(ee.key)},selected:{key:eo,name:(0,e_.jsxs)("div",{className:"nx-flex nx-items-center nx-gap-2 nx-capitalize",children:[(0,e_.jsx)(ec,{}),(0,e_.jsx)("span",{className:ee?"md:nx-hidden":"",children:es?ed[eo]:ed.light})]})}})}function s8(){window.scrollTo({top:0,behavior:"smooth"})}function lt({className:ee}){let en=(0,eE.useRef)(null);return(0,eE.useEffect)(()=>{function ee(){var ee;let{scrollTop:er}=document.documentElement;null==(ee=en.current)||ee.classList.toggle("nx-opacity-0",er<300)}return window.addEventListener("scroll",ee),()=>{window.removeEventListener("scroll",ee)}},[]),(0,e_.jsxs)("button",{ref:en,"aria-hidden":"true",onClick:s8,className:(0,ej.Z)("nx-flex nx-items-center nx-gap-1.5 nx-transition nx-opacity-0",ee),children:["Scroll to top",(0,e_.jsx)(eP.LZ,{className:"-nx-rotate-90 nx-w-3.5 nx-h-3.5 nx-border nx-rounded-full nx-border-current"})]})}var ln=(0,ej.Z)("nx-text-xs nx-font-medium nx-text-gray-500 hover:nx-text-gray-900 dark:nx-text-gray-400 dark:hover:nx-text-gray-100","contrast-more:nx-text-gray-800 contrast-more:dark:nx-text-gray-50");function lr({headings:ee,filePath:en}){var er;let ei=sr(),eo=sh(),es=(0,eE.useRef)(null),eu=(0,eE.useMemo)(()=>ee.filter(ee=>ee.depth>1),[ee]),ec=eu.length>0,ed=!!(eo.feedback.content||eo.editLink.component||eo.toc.extraContent),ef=null==(er=Object.entries(ei).find(([,{isActive:ee}])=>ee))?void 0:er[0];return(0,eE.useEffect)(()=>{var ee;if(!ef)return;let en=null==(ee=es.current)?void 0:ee.querySelector(`li > a[href="#${ef}"]`);en&&oN(en,{behavior:"smooth",block:"center",inline:"center",scrollMode:"always",boundary:es.current})},[ef]),(0,e_.jsxs)("div",{ref:es,className:(0,ej.Z)("nextra-scrollbar nx-sticky nx-top-16 nx-overflow-y-auto nx-pr-4 nx-pt-6 nx-text-sm [hyphens:auto]","nx-max-h-[calc(100vh-var(--nextra-navbar-height)-env(safe-area-inset-bottom))] ltr:-nx-mr-4 rtl:-nx-ml-4"),children:[ec&&(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)("p",{className:"nx-mb-4 nx-font-semibold nx-tracking-tight",children:sk(eo.toc.title)}),(0,e_.jsx)("ul",{children:eu.map(({id:ee,value:en,depth:er})=>{var es,eu,ec,ed;return(0,e_.jsx)("li",{className:"nx-my-2 nx-scroll-my-6 nx-scroll-py-6",children:(0,e_.jsx)("a",{href:`#${ee}`,className:(0,ej.Z)({2:"nx-font-semibold",3:"ltr:nx-pl-4 rtl:nx-pr-4",4:"ltr:nx-pl-8 rtl:nx-pr-8",5:"ltr:nx-pl-12 rtl:nx-pr-12",6:"ltr:nx-pl-16 rtl:nx-pr-16"}[er],"nx-inline-block",(null==(es=ei[ee])?void 0:es.isActive)?"nx-text-primary-600 nx-subpixel-antialiased contrast-more:!nx-text-primary-600":"nx-text-gray-500 hover:nx-text-gray-900 dark:nx-text-gray-400 dark:hover:nx-text-gray-300","contrast-more:nx-text-gray-900 contrast-more:nx-underline contrast-more:dark:nx-text-gray-50 nx-w-full nx-break-words"),children:null!=(ed=null==(ec=(eu=eo.toc).headingComponent)?void 0:ec.call(eu,{id:ee,children:en}))?ed:en})},ee)})})]}),ed&&(0,e_.jsxs)("div",{className:(0,ej.Z)(ec&&"nx-mt-8 nx-border-t nx-bg-white nx-pt-8 nx-shadow-[0_-12px_16px_white] dark:nx-bg-dark dark:nx-shadow-[0_-12px_16px_#111]","nx-sticky nx-bottom-0 nx-flex nx-flex-col nx-items-start nx-gap-2 nx-pb-8 dark:nx-border-neutral-800","contrast-more:nx-border-t contrast-more:nx-border-neutral-400 contrast-more:nx-shadow-none contrast-more:dark:nx-border-neutral-400"),children:[eo.feedback.content?(0,e_.jsx)(sy,{className:ln,href:eo.feedback.useLink(),newWindow:!0,children:sk(eo.feedback.content)}):null,sk(eo.editLink.component,{filePath:en,className:ln,children:sk(eo.editLink.text)}),sk(eo.toc.extraContent),eo.toc.backToTop&&(0,e_.jsx)(lt,{className:ln})]})]})}function li({className:ee,directories:en}){let[er,ei]=(0,eE.useState)(""),eo=(0,eE.useMemo)(()=>er?oF(en,er,{keys:["title"]}).map(({route:ee,title:en})=>({id:ee+en,route:ee,children:(0,e_.jsx)(sO,{value:en,match:er})})):[],[er,en]);return(0,e_.jsx)(sN,{value:er,onChange:ei,className:ee,overlayClassName:"nx-w-full",results:eo})}var lo="en-US",ls="undefined"!=typeof window;function ll(ee){return null==ee||"string"==typeof ee||lu(ee)||(0,eE.isValidElement)(ee)}function lu(ee){return"function"==typeof ee}var lc=nS.array(nS.strictObject({direction:nS.enum(["ltr","rtl"]).optional(),locale:nS.string(),text:nS.string()})),ld=[ll,{message:"Must be React.ReactNode or React.FC"}],lf=[lu,{message:"Must be React.FC"}];nS.strictObject({banner:nS.strictObject({dismissible:nS.boolean(),key:nS.string(),text:nS.custom(...ld).optional()}),chat:nS.strictObject({icon:nS.custom(...ld),link:nS.string().startsWith("https://").optional()}),components:nS.record(nS.custom(...lf)).optional(),darkMode:nS.boolean(),direction:nS.enum(["ltr","rtl"]),docsRepositoryBase:nS.string().startsWith("https://"),editLink:nS.strictObject({component:nS.custom(...lf),text:nS.custom(...ld)}),faviconGlyph:nS.string().optional(),feedback:nS.strictObject({content:nS.custom(...ld),labels:nS.string(),useLink:nS.function().returns(nS.string())}),footer:nS.strictObject({component:nS.custom(...ld),text:nS.custom(...ld)}),gitTimestamp:nS.custom(...ld),head:nS.custom(...ld),i18n:lc,logo:nS.custom(...ld),logoLink:nS.boolean().or(nS.string()),main:nS.custom(...lf).optional(),navbar:nS.strictObject({component:nS.custom(...ld),extraContent:nS.custom(...ld).optional()}),navigation:nS.boolean().or(nS.strictObject({next:nS.boolean(),prev:nS.boolean()})),nextThemes:nS.strictObject({defaultTheme:nS.string(),forcedTheme:nS.string().optional(),storageKey:nS.string()}),notFound:nS.strictObject({content:nS.custom(...ld),labels:nS.string()}),primaryHue:nS.number().or(nS.strictObject({dark:nS.number(),light:nS.number()})),primarySaturation:nS.number().or(nS.strictObject({dark:nS.number(),light:nS.number()})),project:nS.strictObject({icon:nS.custom(...ld),link:nS.string().startsWith("https://").optional()}),search:nS.strictObject({component:nS.custom(...ld),emptyResult:nS.custom(...ld),error:nS.string().or(nS.function().returns(nS.string())),loading:nS.custom(...ld),placeholder:nS.string().or(nS.function().returns(nS.string()))}),serverSideError:nS.strictObject({content:nS.custom(...ld),labels:nS.string()}),sidebar:nS.strictObject({autoCollapse:nS.boolean().optional(),defaultMenuCollapseLevel:nS.number().min(1).int(),titleComponent:nS.custom(...ld),toggleButton:nS.boolean()}),themeSwitch:nS.strictObject({component:nS.custom(...ld),useOptions:s6.or(nS.function().returns(s6))}),toc:nS.strictObject({backToTop:nS.boolean(),component:nS.custom(...ld),extraContent:nS.custom(...ld),float:nS.boolean(),headingComponent:nS.custom(...lf).optional(),title:nS.custom(...ld)}),useNextSeoProps:nS.custom(lu)}).deepPartial().extend({i18n:lc.optional()});var lh={"en-US":"Loading",fr:"Сhargement",ru:"Загрузка","zh-CN":"正在加载"},lp={"en-US":"Search documentation",fr:"Rechercher documents",ru:"Поиск документации","zh-CN":"搜索文档"},lm={banner:{dismissible:!0,key:"nextra-banner"},chat:{icon:(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)(eP.D7,{}),(0,e_.jsx)("span",{className:"nx-sr-only",children:"Discord"})]})},darkMode:!0,direction:"ltr",docsRepositoryBase:"https://github.com/shuding/nextra",editLink:{component:function({className:ee,filePath:en,children:er}){let ei=sC(en);return ei?(0,e_.jsx)(sy,{className:ee,href:ei,children:er}):null},text:"Edit this page"},feedback:{content:"Question? Give us feedback →",labels:"feedback",useLink(){let ee=sh();return sb({labels:ee.feedback.labels,repository:ee.docsRepositoryBase,title:`Feedback for \u201C${ee.title}\u201D`})}},footer:{component:sz,text:`MIT ${new Date().getFullYear()} \xa9 Nextra.`},gitTimestamp:function({timestamp:ee}){let{locale:en=lo}=(0,eC.useRouter)();return(0,e_.jsxs)(e_.Fragment,{children:["Last updated on"," ",(0,e_.jsx)("time",{dateTime:ee.toISOString(),children:ee.toLocaleDateString(en,{day:"numeric",month:"long",year:"numeric"})})]})},head:(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)("meta",{name:"msapplication-TileColor",content:"#fff"}),(0,e_.jsx)("meta",{httpEquiv:"Content-Language",content:"en"}),(0,e_.jsx)("meta",{name:"description",content:"Nextra: the next docs builder"}),(0,e_.jsx)("meta",{name:"twitter:card",content:"summary_large_image"}),(0,e_.jsx)("meta",{name:"twitter:site",content:"@shuding_"}),(0,e_.jsx)("meta",{property:"og:title",content:"Nextra: the next docs builder"}),(0,e_.jsx)("meta",{property:"og:description",content:"Nextra: the next docs builder"}),(0,e_.jsx)("meta",{name:"apple-mobile-web-app-title",content:"Nextra"})]}),i18n:[],logo:(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)("span",{className:"nx-font-extrabold",children:"Nextra"}),(0,e_.jsx)("span",{className:"nx-ml-2 nx-hidden nx-font-normal nx-text-gray-600 md:nx-inline",children:"The Next Docs Builder"})]}),logoLink:!0,navbar:{component:sH},navigation:!0,nextThemes:{defaultTheme:"system",storageKey:"theme"},notFound:{content:"Submit an issue about broken link →",labels:"bug"},primaryHue:{dark:204,light:212},primarySaturation:{dark:100,light:100},project:{icon:(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)(eP.fy,{}),(0,e_.jsx)("span",{className:"nx-sr-only",children:"GitHub"})]})},search:{component:function({className:ee,directories:en}){let er=sh();return er.flexsearch?(0,e_.jsx)(sL,{className:ee}):(0,e_.jsx)(li,{className:ee,directories:en})},emptyResult:(0,e_.jsx)("span",{className:"nx-block nx-select-none nx-p-8 nx-text-center nx-text-sm nx-text-gray-400",children:"No results found."}),error:"Failed to load search index.",loading:function(){let{locale:ee,defaultLocale:en=lo}=(0,eC.useRouter)(),er=ee&&lh[ee]||lh[en];return(0,e_.jsxs)(e_.Fragment,{children:[er,"…"]})},placeholder:function(){let{locale:ee,defaultLocale:en=lo}=(0,eC.useRouter)(),er=ee&&lp[ee]||lp[en];return`${er}\u2026`}},serverSideError:{content:"Submit an issue about error in url →",labels:"bug"},sidebar:{defaultMenuCollapseLevel:2,titleComponent:({title:ee})=>(0,e_.jsx)(e_.Fragment,{children:ee}),toggleButton:!1},themeSwitch:{component:s9,useOptions(){let{locale:ee}=(0,eC.useRouter)();return"zh-CN"===ee?{dark:"深色主题",light:"浅色主题",system:"系统默认"}:{dark:"Dark",light:"Light",system:"System"}}},toc:{backToTop:!1,component:lr,float:!0,title:"On This Page"},useNextSeoProps:()=>({titleTemplate:"%s – Nextra"})},lx=Object.entries(lm).map(([ee,en])=>{let er=en&&"object"==typeof en&&!Array.isArray(en)&&!(0,eE.isValidElement)(en);if(er)return ee}).filter(Boolean);if(ls){let ee;let en=()=>{document.body.classList.add("resizing"),clearTimeout(ee),ee=setTimeout(()=>{document.body.classList.remove("resizing")},200)};window.addEventListener("resize",en)}function lg(ee){var en=ee,{tag:er,context:ei,children:eo,id:es,className:eu}=en,ec=o3(en,["tag","context","children","id","className"]);let ed=si(),ef=ss(),eh=so(),ep=(0,eE.useRef)(null);return(0,eE.useEffect)(()=>{if(!es)return;let ee=ep.current;if(ee)return ef.set(ee,[es,ei.index+=1]),null==eh||eh.observe(ee),()=>{null==eh||eh.disconnect(),ef.delete(ee),ed(ee=>{let en=o4({},ee);return delete en[es],en})}},[es,ei,ef,eh,ed]),(0,e_.jsxs)(er,o5(o4({className:"sr-only"===eu?"nx-sr-only":(0,ej.Z)("nx-font-semibold nx-tracking-tight nx-text-slate-900 dark:nx-text-slate-100",{h2:"nx-mt-10 nx-border-b nx-pb-1 nx-text-3xl nx-border-neutral-200/70 contrast-more:nx-border-neutral-400 dark:nx-border-primary-100/10 contrast-more:dark:nx-border-neutral-400",h3:"nx-mt-8 nx-text-2xl",h4:"nx-mt-8 nx-text-xl",h5:"nx-mt-8 nx-text-lg",h6:"nx-mt-8 nx-text-base"}[er])},ec),{children:[eo,es&&(0,e_.jsx)("a",{href:`#${es}`,id:es,className:"subheading-anchor","aria-label":"Permalink for this section",ref:ep})]}))}var lv=ee=>{let en=null,er=[];return eE.Children.forEach(ee,(ee,ei)=>{var eo;if(ee&&ee.type===lb){en||(en=ee);return}let es=ee;if(!en&&ee&&"object"==typeof ee&&ee.type!==ly&&"props"in ee&&ee.props){let er=lv(ee.props.children);en=er[0],es=(0,eE.cloneElement)(ee,o5(o4({},ee.props),{children:(null==(eo=er[1])?void 0:eo.length)?er[1]:void 0,key:ei}))}er.push(es)}),[en,er]},ly=ee=>{var en=ee,{children:er,open:ei}=en,eo=o3(en,["children","open"]);let[es,eu]=(0,eE.useState)(!!ei),[ec,ed]=lv(er),[ef,eh]=(0,eE.useState)(es);return(0,eE.useEffect)(()=>{if(es)eh(!0);else{let ee=setTimeout(()=>eh(es),500);return()=>clearTimeout(ee)}},[es]),(0,e_.jsxs)("details",o5(o4(o5(o4({className:"nx-my-4 nx-rounded nx-border nx-border-gray-200 nx-bg-white nx-p-2 nx-shadow-sm first:nx-mt-0 dark:nx-border-neutral-800 dark:nx-bg-neutral-900"},eo),{open:ef}),es&&{"data-expanded":!0}),{children:[(0,e_.jsx)(sg,{value:eu,children:ec}),(0,e_.jsx)(sS,{isOpen:es,children:ed})]}))},lb=ee=>{let en=sx();return(0,e_.jsx)("summary",o5(o4({className:(0,ej.Z)("nx-flex nx-items-center nx-cursor-pointer nx-list-none nx-p-1 nx-transition-colors hover:nx-bg-gray-100 dark:hover:nx-bg-neutral-800","before:nx-mr-1 before:nx-inline-block before:nx-transition-transform before:nx-content-[''] dark:before:nx-invert before:nx-shrink-0","rtl:before:nx-rotate-180 [[data-expanded]>&]:before:nx-rotate-90")},ee),{onClick:ee=>{ee.preventDefault(),en(ee=>!ee)}}))},lk=/https?:\/\//,lw=ee=>{var en=ee,{href:er="",className:ei}=en,eo=o3(en,["href","className"]);return(0,e_.jsx)(sy,o4({href:er,newWindow:lk.test(er),className:(0,ej.Z)("nx-text-primary-600 nx-underline nx-decoration-from-font [text-underline-position:from-font]",ei)},eo))},l_=ee=>{var en=ee,{href:er=""}=en,ei=o3(en,["href"]);return(0,e_.jsx)(sy,o4({href:er,newWindow:lk.test(er)},ei))},lC=({isRawLayout:ee,components:en})=>{if(ee)return{a:l_};let er={index:0};return o4({h1:ee=>(0,e_.jsx)("h1",o4({className:"nx-mt-2 nx-text-4xl nx-font-bold nx-tracking-tight nx-text-slate-900 dark:nx-text-slate-100"},ee)),h2:ee=>(0,e_.jsx)(lg,o4({tag:"h2",context:er},ee)),h3:ee=>(0,e_.jsx)(lg,o4({tag:"h3",context:er},ee)),h4:ee=>(0,e_.jsx)(lg,o4({tag:"h4",context:er},ee)),h5:ee=>(0,e_.jsx)(lg,o4({tag:"h5",context:er},ee)),h6:ee=>(0,e_.jsx)(lg,o4({tag:"h6",context:er},ee)),ul:ee=>(0,e_.jsx)("ul",o4({className:"nx-mt-6 nx-list-disc first:nx-mt-0 ltr:nx-ml-6 rtl:nx-mr-6"},ee)),ol:ee=>(0,e_.jsx)("ol",o4({className:"nx-mt-6 nx-list-decimal first:nx-mt-0 ltr:nx-ml-6 rtl:nx-mr-6"},ee)),li:ee=>(0,e_.jsx)("li",o4({className:"nx-my-2"},ee)),blockquote:ee=>(0,e_.jsx)("blockquote",o4({className:(0,ej.Z)("nx-mt-6 nx-border-gray-300 nx-italic nx-text-gray-700 dark:nx-border-gray-700 dark:nx-text-gray-400","first:nx-mt-0 ltr:nx-border-l-2 ltr:nx-pl-6 rtl:nx-border-r-2 rtl:nx-pr-6")},ee)),hr:ee=>(0,e_.jsx)("hr",o4({className:"nx-my-8 nx-border-neutral-200/70 contrast-more:nx-border-neutral-400 dark:nx-border-primary-100/10 contrast-more:dark:nx-border-neutral-400"},ee)),a:lw,table:ee=>(0,e_.jsx)(oK.iA,o4({className:"nextra-scrollbar nx-mt-6 nx-p-0 first:nx-mt-0"},ee)),p:ee=>(0,e_.jsx)("p",o4({className:"nx-mt-6 nx-leading-7 first:nx-mt-0"},ee)),tr:oK.Tr,th:oK.Th,td:oK.Td,details:ly,summary:lb,pre:oK.SU,code:oK.EK},en)},lE={toc:(0,ej.Z)("nextra-toc nx-order-last nx-hidden nx-w-64 nx-shrink-0 xl:nx-block print:nx-hidden"),main:(0,ej.Z)("nx-w-full nx-break-words")},lj=({themeContext:ee,breadcrumb:en,timestamp:er,navigation:ei,children:eo})=>{var es;let eu=sh(),ec=eS();if("raw"===ee.layout)return(0,e_.jsx)("div",{className:lE.main,children:eo});let ed=ee.timestamp&&eu.gitTimestamp&&er?new Date(er):null,ef=ec&&ed?(0,e_.jsx)("div",{className:"nx-mt-12 nx-mb-8 nx-block nx-text-xs nx-text-gray-500 ltr:nx-text-right rtl:nx-text-left dark:nx-text-gray-400",children:sk(eu.gitTimestamp,{timestamp:ed})}):(0,e_.jsx)("div",{className:"nx-mt-16"}),eh=(0,e_.jsxs)(e_.Fragment,{children:[eo,ef,ei]}),ep=(null==(es=eu.main)?void 0:es.call(eu,{children:eh}))||eh;return"full"===ee.layout?(0,e_.jsx)("article",{className:(0,ej.Z)(lE.main,"nextra-content nx-min-h-[calc(100vh-var(--nextra-navbar-height))] nx-pl-[max(env(safe-area-inset-left),1.5rem)] nx-pr-[max(env(safe-area-inset-right),1.5rem)]"),children:ep}):(0,e_.jsx)("article",{className:(0,ej.Z)(lE.main,"nextra-content nx-flex nx-min-h-[calc(100vh-var(--nextra-navbar-height))] nx-min-w-0 nx-justify-center nx-pb-8 nx-pr-[calc(env(safe-area-inset-right)-1.5rem)]","article"===ee.typesetting&&"nextra-body-typesetting-article"),children:(0,e_.jsxs)("main",{className:"nx-w-full nx-min-w-0 nx-max-w-6xl nx-px-6 nx-pt-4 md:nx-px-12",children:[en,ep]})})},lS=({filePath:ee,pageMap:en,frontMatter:er,headings:ei,timestamp:eo,children:es})=>{let eu=sh(),{locale:ec=lo,defaultLocale:ed}=(0,eC.useRouter)(),ef=eT(),{activeType:eh,activeIndex:ep,activeThemeContext:em,activePath:ex,topLevelNavbarItems:eg,docsDirectories:ev,flatDirectories:ey,flatDocsDirectories:eb,directories:ek}=(0,eE.useMemo)(()=>n0({list:en,locale:ec,defaultLocale:ed,route:ef}),[en,ec,ed,ef]),ew=o4(o4({},em),er),eS=!ew.sidebar||"raw"===ew.layout||"page"===eh,eO="page"!==eh&&ew.toc&&"default"===ew.layout?(0,e_.jsx)("nav",{className:(0,ej.Z)(lE.toc,"nx-px-4"),"aria-label":"table of contents",children:sk(eu.toc.component,{headings:eu.toc.float?ei:[],filePath:ee})}):"full"!==ew.layout&&"raw"!==ew.layout&&(0,e_.jsx)("nav",{className:lE.toc,"aria-label":"table of contents"}),eM=eu.i18n.find(ee=>ee.locale===ec),eP=eM?"rtl"===eM.direction:"rtl"===eu.direction,eI=eP?"rtl":"ltr";return(0,e_.jsxs)("div",{dir:eI,children:[(0,e_.jsx)("script",{dangerouslySetInnerHTML:{__html:`document.documentElement.setAttribute('dir','${eI}')`}}),(0,e_.jsx)(s$,{}),(0,e_.jsx)(sE,{}),ew.navbar&&sk(eu.navbar.component,{flatDirectories:ey,items:eg}),(0,e_.jsx)("div",{className:(0,ej.Z)("nx-mx-auto nx-flex","raw"!==ew.layout&&"nx-max-w-[90rem]"),children:(0,e_.jsxs)(sl,{children:[(0,e_.jsx)(s4,{docsDirectories:ev,flatDirectories:ey,fullDirectories:ek,headings:ei,asPopover:eS,includePlaceholder:"default"===ew.layout}),eO,(0,e_.jsx)(s7,{}),(0,e_.jsx)(lj,{themeContext:ew,breadcrumb:"page"!==eh&&ew.breadcrumb?(0,e_.jsx)(sj,{activePath:ex}):null,timestamp:eo,navigation:"page"!==eh&&ew.pagination?(0,e_.jsx)(sU,{flatDirectories:eb,currentIndex:ep}):null,children:(0,e_.jsx)(eN.Z,{components:lC({isRawLayout:"raw"===ew.layout,components:eu.components}),children:es})})]})}),ew.footer&&sk(eu.footer.component,{menu:eS})]})};function lO(ee){var en=ee,{children:er}=en,ei=o3(en,["children"]);return(0,e_.jsx)(sp,{value:ei,children:(0,e_.jsx)(lS,o5(o4({},ei.pageOpts),{children:er}))})}function lM(){let{asPath:ee}=(0,eC.useRouter)(),{frontMatter:en,title:er}=sh(),ei="https://overextended.dev".concat(ee),eo=en.description||"Documentation for Overextended's resources for FiveM/RedM";return(0,e_.jsxs)(e_.Fragment,{children:[(0,e_.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1.0"}),(0,e_.jsx)("link",{rel:"icon",type:"image/x-icon",href:"/static/ox.ico"}),(0,e_.jsx)("meta",{httpEquiv:"Content-Language",content:"en"}),(0,e_.jsx)("meta",{name:"description",content:eo}),(0,e_.jsx)("meta",{name:"og:title",content:er}),(0,e_.jsx)("meta",{name:"og:description",content:eo}),(0,e_.jsx)("meta",{name:"og:url",content:ei})]})}function lT(){let{asPath:ee}=(0,eC.useRouter)(),en=ee.replace(/[-_]/g," ").split("/"),er="#"!==en[1][0]&&en[1]||"Overextended",ei=en[en.length-1],eo=/[a-z]/.test(ei)&&/[A-Z]/.test(ei)?ei:"%s";return{titleTemplate:"".concat(eo," - ").concat(ei===er?"Documentation":er.replace(/(^\w|\s\w)/g,ee=>ee.toUpperCase()))}}let lN={logo:(0,e_.jsx)("div",{style:{paddingLeft:"50px",lineHeight:"38px",background:"url('https://avatars.githubusercontent.com/u/88127058?s=38') no-repeat left",backgroundSize:"38px",fontWeight:550},children:"Overextended"}),project:{link:"https://github.com/overextended/overextended.github.io"},chat:{link:"https://discord.overextended.dev"},docsRepositoryBase:"https://github.com/overextended/overextended.github.io/blob/main",footer:{text:"Overextended"},head:lM,primaryHue:{dark:200,light:200},sidebar:{defaultMenuCollapseLevel:1},useNextSeoProps:lT};var lP=lN;er(7771),er(1803);let lI=function(ee){let{Component:en,pageProps:er}=ee;return(0,e_.jsx)(en,{...er})},lR=[];function lA(ee){return(0,e_.jsx)(e_.Fragment,{})}var lL=function(){let ee=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,e_.jsx)(lI,{...ee,children:(0,e_.jsx)(lA,{...ee})})};let lF=(ek=globalThis)[ew=Symbol.for("__nextra_internal__")]||(ek[ew]=Object.create(null));lF.Layout=lO,lF.pageMap=[{kind:"Meta",data:{index:"Introduction",guides:"Guides",oxmysql:"OxMySQL",ox_lib:"Ox Lib",creator_codes:{title:"Creator codes",type:"page",href:"https://overextended.dev/#creator-codes"},support:{title:"Support us",type:"page",href:"https://overextended.dev/#support-our-team"},ox_core:"Ox Core",ox_doorlock:"Ox Doorlock",ox_fuel:"Ox Fuel",ox_inventory:"Ox Inventory",ox_target:"Ox Target"}},{kind:"Folder",name:"guides",route:"/guides",children:[{kind:"MdxPage",name:"git",route:"/guides/git"},{kind:"MdxPage",name:"nodejs",route:"/guides/nodejs",frontMatter:{title:"Node.js"}},{kind:"MdxPage",name:"pnpm",route:"/guides/pnpm",frontMatter:{title:"pnpm"}},{kind:"MdxPage",name:"types",route:"/guides/types"},{kind:"MdxPage",name:"vscode",route:"/guides/vscode",frontMatter:{title:"VS Code"}},{kind:"Meta",data:{git:"Git",nodejs:"Node.js",pnpm:"pnpm",types:"Types",vscode:"VS Code"}}]},{kind:"MdxPage",name:"index",route:"/",frontMatter:{title:"Introduction"}},{kind:"Folder",name:"ox_core",route:"/ox_core",children:[{kind:"Folder",name:"Client",route:"/ox_core/Client",children:[{kind:"Folder",name:"Player",route:"/ox_core/Client/Player",children:[{kind:"MdxPage",name:"callbacks",route:"/ox_core/Client/Player/callbacks",frontMatter:{title:"Callbacks"}},{kind:"MdxPage",name:"events",route:"/ox_core/Client/Player/events",frontMatter:{title:"Events"}},{kind:"Meta",data:{callbacks:"Callbacks",events:"Events"}}]},{kind:"MdxPage",name:"Player",route:"/ox_core/Client/Player"},{kind:"MdxPage",name:"functions",route:"/ox_core/Client/functions"},{kind:"Meta",data:{functions:"Functions",Player:"Player"}}]},{kind:"Folder",name:"Server",route:"/ox_core/Server",children:[{kind:"Folder",name:"Player",route:"/ox_core/Server/Player",children:[{kind:"MdxPage",name:"events",route:"/ox_core/Server/Player/events",frontMatter:{title:"Events"}},{kind:"MdxPage",name:"methods",route:"/ox_core/Server/Player/methods",frontMatter:{title:"Methods"}},{kind:"Meta",data:{events:"Events",methods:"Methods"}}]},{kind:"MdxPage",name:"Player",route:"/ox_core/Server/Player"},{kind:"Folder",name:"Vehicle",route:"/ox_core/Server/Vehicle",children:[{kind:"MdxPage",name:"callbacks",route:"/ox_core/Server/Vehicle/callbacks",frontMatter:{title:"Callbacks"}},{kind:"MdxPage",name:"methods",route:"/ox_core/Server/Vehicle/methods",frontMatter:{title:"Methods"}},{kind:"Meta",data:{callbacks:"Callbacks",methods:"Methods"}}]},{kind:"MdxPage",name:"Vehicle",route:"/ox_core/Server/Vehicle",frontMatter:{title:"Server",sidebar_position:1}},{kind:"MdxPage",name:"functions",route:"/ox_core/Server/functions"},{kind:"Meta",data:{functions:"Functions",Player:"Player",Vehicle:"Server"}}]},{kind:"MdxPage",name:"concepts",route:"/ox_core/concepts"},{kind:"Meta",data:{concepts:"Concepts"}}]},{kind:"MdxPage",name:"ox_core",route:"/ox_core"},{kind:"Folder",name:"ox_doorlock",route:"/ox_doorlock",children:[{kind:"Folder",name:"Client",route:"/ox_doorlock/Client",children:[{kind:"MdxPage",name:"functions",route:"/ox_doorlock/Client/functions"},{kind:"Meta",data:{functions:"Functions"}}]},{kind:"Folder",name:"Server",route:"/ox_doorlock/Server",children:[{kind:"MdxPage",name:"events",route:"/ox_doorlock/Server/events"},{kind:"MdxPage",name:"functions",route:"/ox_doorlock/Server/functions"},{kind:"Meta",data:{events:"Events",functions:"Functions"}}]},{kind:"MdxPage",name:"settings",route:"/ox_doorlock/settings",frontMatter:{title:"Door Settings"}},{kind:"Meta",data:{settings:"Door Settings"}}]},{kind:"MdxPage",name:"ox_doorlock",route:"/ox_doorlock"},{kind:"Folder",name:"ox_fuel",route:"/ox_fuel",children:[{kind:"Folder",name:"Client",route:"/ox_fuel/Client",children:[{kind:"MdxPage",name:"functions",route:"/ox_fuel/Client/functions"},{kind:"Meta",data:{functions:"Functions"}}]},{kind:"Folder",name:"Server",route:"/ox_fuel/Server",children:[{kind:"MdxPage",name:"functions",route:"/ox_fuel/Server/functions"},{kind:"Meta",data:{functions:"Functions"}}]},{kind:"MdxPage",name:"Shared",route:"/ox_fuel/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"MdxPage",name:"ox_fuel",route:"/ox_fuel"},{kind:"Folder",name:"ox_inventory",route:"/ox_inventory",children:[{kind:"Folder",name:"Events",route:"/ox_inventory/Events",children:[{kind:"MdxPage",name:"Client",route:"/ox_inventory/Events/Client"},{kind:"MdxPage",name:"Server",route:"/ox_inventory/Events/Server"},{kind:"Meta",data:{Client:"Client",Server:"Server"}}]},{kind:"Folder",name:"Frameworks",route:"/ox_inventory/Frameworks",children:[{kind:"MdxPage",name:"esx",route:"/ox_inventory/Frameworks/esx",frontMatter:{title:"ESX"}},{kind:"MdxPage",name:"qb",route:"/ox_inventory/Frameworks/qb",frontMatter:{title:"QBCore"}},{kind:"Meta",data:{esx:"ESX",qb:"QBCore"}}]},{kind:"Folder",name:"Functions",route:"/ox_inventory/Functions",children:[{kind:"MdxPage",name:"Client",route:"/ox_inventory/Functions/Client"},{kind:"Folder",name:"Server",route:"/ox_inventory/Functions/Server",children:[{kind:"MdxPage",name:"Hooks",route:"/ox_inventory/Functions/Server/Hooks"},{kind:"Meta",data:{Hooks:"Hooks"}}]},{kind:"MdxPage",name:"Server",route:"/ox_inventory/Functions/Server"},{kind:"Meta",data:{Client:"Client",Server:"Server"}}]},{kind:"Folder",name:"Guides",route:"/ox_inventory/Guides",children:[{kind:"MdxPage",name:"crafting",route:"/ox_inventory/Guides/crafting",frontMatter:{title:"Crafting"}},{kind:"MdxPage",name:"creatingItems",route:"/ox_inventory/Guides/creatingItems",frontMatter:{title:"Creating Items"}},{kind:"MdxPage",name:"metadata",route:"/ox_inventory/Guides/metadata",frontMatter:{title:"Metadata"}},{kind:"MdxPage",name:"shops",route:"/ox_inventory/Guides/shops",frontMatter:{title:"Creating Shops"}},{kind:"MdxPage",name:"stashes",route:"/ox_inventory/Guides/stashes",frontMatter:{title:"Custom Stashes"}},{kind:"Meta",data:{crafting:"Crafting",creatingItems:"Creating Items",shops:"Creating Shops",stashes:"Custom Stashes",metadata:"Metadata"}}]},{kind:"MdxPage",name:"issues",route:"/ox_inventory/issues",frontMatter:{title:"Common Issues"}},{kind:"Meta",data:{issues:"Common Issues"}}]},{kind:"MdxPage",name:"ox_inventory",route:"/ox_inventory"},{kind:"Folder",name:"ox_lib",route:"/ox_lib",children:[{kind:"Folder",name:"Modules",route:"/ox_lib/Modules",children:[{kind:"Folder",name:"ACL",route:"/ox_lib/Modules/ACL",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/ACL/Server"},{kind:"Meta",data:{Server:"Server"}}]},{kind:"Folder",name:"AddCommand",route:"/ox_lib/Modules/AddCommand",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/AddCommand/Server"},{kind:"Meta",data:{Server:"Server"}}]},{kind:"Folder",name:"AddKeybind",route:"/ox_lib/Modules/AddKeybind",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/AddKeybind/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Cache",route:"/ox_lib/Modules/Cache",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Cache/Client"},{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Cache/Shared"},{kind:"Meta",data:{Client:"Client",Shared:"Shared"}}]},{kind:"Folder",name:"Callback",route:"/ox_lib/Modules/Callback",children:[{kind:"Folder",name:"JavaScript",route:"/ox_lib/Modules/Callback/JavaScript",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Callback/JavaScript/Client"},{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Callback/JavaScript/Server"},{kind:"Meta",data:{Client:"Client",Server:"Server"}}]},{kind:"Folder",name:"Lua",route:"/ox_lib/Modules/Callback/Lua",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Callback/Lua/Client"},{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Callback/Lua/Server"},{kind:"Meta",data:{Client:"Client",Server:"Server"}}]}]},{kind:"Folder",name:"Class",route:"/ox_lib/Modules/Class",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Class/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Cron",route:"/ox_lib/Modules/Cron",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Cron/Server"},{kind:"Meta",data:{Server:"Server"}}]},{kind:"Folder",name:"DisableControls",route:"/ox_lib/Modules/DisableControls",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/DisableControls/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"GetClosestObject",route:"/ox_lib/Modules/GetClosestObject",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetClosestObject/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetClosestPed",route:"/ox_lib/Modules/GetClosestPed",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetClosestPed/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetClosestPlayer",route:"/ox_lib/Modules/GetClosestPlayer",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetClosestPlayer/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetClosestVehicle",route:"/ox_lib/Modules/GetClosestVehicle",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetClosestVehicle/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetNearbyObjects",route:"/ox_lib/Modules/GetNearbyObjects",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetNearbyObjects/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetNearbyPeds",route:"/ox_lib/Modules/GetNearbyPeds",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetNearbyPeds/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetNearbyPlayers",route:"/ox_lib/Modules/GetNearbyPlayers",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetNearbyPlayers/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"GetNearbyVehicles",route:"/ox_lib/Modules/GetNearbyVehicles",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/GetNearbyVehicles/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Interface",route:"/ox_lib/Modules/Interface",children:[{kind:"Folder",name:"Client",route:"/ox_lib/Modules/Interface/Client",children:[{kind:"MdxPage",name:"alert",route:"/ox_lib/Modules/Interface/Client/alert",frontMatter:{title:"Alert Dialog"}},{kind:"MdxPage",name:"clipboard",route:"/ox_lib/Modules/Interface/Client/clipboard",frontMatter:{title:"Clipboard"}},{kind:"MdxPage",name:"context",route:"/ox_lib/Modules/Interface/Client/context",frontMatter:{title:"Context Menu"}},{kind:"MdxPage",name:"input",route:"/ox_lib/Modules/Interface/Client/input",frontMatter:{title:"Input Dialog"}},{kind:"MdxPage",name:"menu",route:"/ox_lib/Modules/Interface/Client/menu",frontMatter:{title:"Menu"}},{kind:"MdxPage",name:"notify",route:"/ox_lib/Modules/Interface/Client/notify",frontMatter:{title:"Notifications"}},{kind:"MdxPage",name:"progress",route:"/ox_lib/Modules/Interface/Client/progress",frontMatter:{title:"Progress"}},{kind:"MdxPage",name:"radial",route:"/ox_lib/Modules/Interface/Client/radial",frontMatter:{title:"Radial Menu"}},{kind:"MdxPage",name:"skillcheck",route:"/ox_lib/Modules/Interface/Client/skillcheck",frontMatter:{title:"Skill Check"}},{kind:"MdxPage",name:"textui",route:"/ox_lib/Modules/Interface/Client/textui",frontMatter:{title:"TextUI"}},{kind:"Meta",data:{alert:"Alert Dialog",clipboard:"Clipboard",context:"Context Menu",input:"Input Dialog",menu:"Menu",notify:"Notifications",progress:"Progress",radial:"Radial Menu",skillcheck:"Skill Check",textui:"TextUI"}}]}]},{kind:"MdxPage",name:"Interface",route:"/ox_lib/Modules/Interface",frontMatter:{title:"Interface"}},{kind:"Folder",name:"Locale",route:"/ox_lib/Modules/Locale",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Locale/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Logger",route:"/ox_lib/Modules/Logger",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Logger/Server"},{kind:"Meta",data:{Server:"Server"}}]},{kind:"Folder",name:"Marker",route:"/ox_lib/Modules/Marker",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Marker/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Math",route:"/ox_lib/Modules/Math",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Math/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Points",route:"/ox_lib/Modules/Points",children:[{kind:"Folder",name:"JavaScript",route:"/ox_lib/Modules/Points/JavaScript",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Points/JavaScript/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Lua",route:"/ox_lib/Modules/Points/Lua",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Points/Lua/Client"},{kind:"Meta",data:{Client:"Client"}}]}]},{kind:"Folder",name:"Print",route:"/ox_lib/Modules/Print",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Print/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Raycast",route:"/ox_lib/Modules/Raycast",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Raycast/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Require",route:"/ox_lib/Modules/Require",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Require/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Streaming",route:"/ox_lib/Modules/Streaming",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/Streaming/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"String",route:"/ox_lib/Modules/String",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/String/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Table",route:"/ox_lib/Modules/Table",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Table/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"VehicleProperties",route:"/ox_lib/Modules/VehicleProperties",children:[{kind:"MdxPage",name:"Client",route:"/ox_lib/Modules/VehicleProperties/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"Folder",name:"Version",route:"/ox_lib/Modules/Version",children:[{kind:"MdxPage",name:"Server",route:"/ox_lib/Modules/Version/Server"},{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Version/Shared"},{kind:"Meta",data:{Server:"Server",Shared:"Shared"}}]},{kind:"Folder",name:"WaitFor",route:"/ox_lib/Modules/WaitFor",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/WaitFor/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Folder",name:"Zones",route:"/ox_lib/Modules/Zones",children:[{kind:"MdxPage",name:"Shared",route:"/ox_lib/Modules/Zones/Shared"},{kind:"Meta",data:{Shared:"Shared"}}]},{kind:"Meta",data:{Interface:"Interface"}}]}]},{kind:"MdxPage",name:"ox_lib",route:"/ox_lib"},{kind:"Folder",name:"ox_target",route:"/ox_target",children:[{kind:"Folder",name:"Functions",route:"/ox_target/Functions",children:[{kind:"MdxPage",name:"Client",route:"/ox_target/Functions/Client"},{kind:"Meta",data:{Client:"Client"}}]},{kind:"MdxPage",name:"Options",route:"/ox_target/Options"},{kind:"Meta",data:{Options:"Options"}}]},{kind:"MdxPage",name:"ox_target",route:"/ox_target"},{kind:"Folder",name:"oxmysql",route:"/oxmysql",children:[{kind:"Folder",name:"Functions",route:"/oxmysql/Functions",children:[{kind:"MdxPage",name:"insert",route:"/oxmysql/Functions/insert",frontMatter:{title:"insert"}},{kind:"MdxPage",name:"prepare",route:"/oxmysql/Functions/prepare",frontMatter:{title:"prepare"}},{kind:"MdxPage",name:"query",route:"/oxmysql/Functions/query",frontMatter:{title:"query"}},{kind:"MdxPage",name:"rawExecute",route:"/oxmysql/Functions/rawExecute",frontMatter:{title:"rawExecute"}},{kind:"MdxPage",name:"scalar",route:"/oxmysql/Functions/scalar",frontMatter:{title:"scalar"}},{kind:"MdxPage",name:"single",route:"/oxmysql/Functions/single",frontMatter:{title:"single"}},{kind:"MdxPage",name:"transaction",route:"/oxmysql/Functions/transaction",frontMatter:{title:"transaction"}},{kind:"MdxPage",name:"update",route:"/oxmysql/Functions/update",frontMatter:{title:"update"}},{kind:"Meta",data:{insert:"insert",prepare:"prepare",query:"query",rawExecute:"rawExecute",scalar:"scalar",single:"single",transaction:"transaction",update:"update"}}]},{kind:"MdxPage",name:"benchmark",route:"/oxmysql/benchmark"},{kind:"MdxPage",name:"issues",route:"/oxmysql/issues",frontMatter:{title:"Common Issues"}},{kind:"MdxPage",name:"placeholders",route:"/oxmysql/placeholders"},{kind:"MdxPage",name:"ui",route:"/oxmysql/ui",frontMatter:{title:"Using the Debug UI"}},{kind:"Meta",data:{benchmark:"Benchmark",issues:"Common Issues",placeholders:"Placeholders",ui:"Using the Debug UI"}}]},{kind:"MdxPage",name:"oxmysql",route:"/oxmysql",frontMatter:{title:"OxMySQL"}}],lF.flexsearch={codeblocks:!0},lF.themeConfig=lP},7521:function(ee,en){"use strict";var er;Object.defineProperty(en,"__esModule",{value:!0}),function(ee,en){for(var er in en)Object.defineProperty(ee,er,{enumerable:!0,get:en[er]})}(en,{PrefetchKind:function(){return er},ACTION_REFRESH:function(){return ei},ACTION_NAVIGATE:function(){return eo},ACTION_RESTORE:function(){return es},ACTION_SERVER_PATCH:function(){return eu},ACTION_PREFETCH:function(){return ec},ACTION_FAST_REFRESH:function(){return ed},ACTION_SERVER_ACTION:function(){return ef}});let ei="refresh",eo="navigate",es="restore",eu="server-patch",ec="prefetch",ed="fast-refresh",ef="server-action";!function(ee){ee.AUTO="auto",ee.FULL="full",ee.TEMPORARY="temporary"}(er||(er={})),("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},1726:function(ee,en,er){"use strict";function ei(ee,en,er,ei){return!1}Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"getDomainLocale",{enumerable:!0,get:function(){return ei}}),er(6925),("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},759:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"Image",{enumerable:!0,get:function(){return ek}});let ei=er(1351),eo=er(5815),es=eo._(er(959)),eu=ei._(er(422)),ec=ei._(er(457)),ed=er(8009),ef=er(9327),eh=er(4514);er(5393);let ep=er(4621),em=ei._(er(2685)),ex={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!0};function eg(ee,en,er,ei,eo,es){let eu=null==ee?void 0:ee.src;if(!ee||ee["data-loaded-src"]===eu)return;ee["data-loaded-src"]=eu;let ec="decode"in ee?ee.decode():Promise.resolve();ec.catch(()=>{}).then(()=>{if(ee.parentElement&&ee.isConnected){if("empty"!==en&&eo(!0),null==er?void 0:er.current){let en=new Event("load");Object.defineProperty(en,"target",{writable:!1,value:ee});let ei=!1,eo=!1;er.current({...en,nativeEvent:en,currentTarget:ee,target:ee,isDefaultPrevented:()=>ei,isPropagationStopped:()=>eo,persist:()=>{},preventDefault:()=>{ei=!0,en.preventDefault()},stopPropagation:()=>{eo=!0,en.stopPropagation()}})}(null==ei?void 0:ei.current)&&ei.current(ee)}})}function ev(ee){let[en,er]=es.version.split("."),ei=parseInt(en,10),eo=parseInt(er,10);return ei>18||18===ei&&eo>=3?{fetchPriority:ee}:{fetchpriority:ee}}let ey=(0,es.forwardRef)((ee,en)=>{let{src:er,srcSet:ei,sizes:eo,height:eu,width:ec,decoding:ed,className:ef,style:eh,fetchPriority:ep,placeholder:em,loading:ex,unoptimized:ey,fill:eb,onLoadRef:ek,onLoadingCompleteRef:ew,setBlurComplete:e_,setShowAltText:eC,onLoad:eE,onError:ej,...eS}=ee;return es.default.createElement("img",{...eS,...ev(ep),loading:ex,width:ec,height:eu,decoding:ed,"data-nimg":eb?"fill":"1",className:ef,style:eh,sizes:eo,srcSet:ei,src:er,ref:(0,es.useCallback)(ee=>{en&&("function"==typeof en?en(ee):"object"==typeof en&&(en.current=ee)),ee&&(ej&&(ee.src=ee.src),ee.complete&&eg(ee,em,ek,ew,e_,ey))},[er,em,ek,ew,e_,ej,ey,en]),onLoad:ee=>{let en=ee.currentTarget;eg(en,em,ek,ew,e_,ey)},onError:ee=>{eC(!0),"empty"!==em&&e_(!0),ej&&ej(ee)}})});function eb(ee){let{isAppRouter:en,imgAttributes:er}=ee,ei={as:"image",imageSrcSet:er.srcSet,imageSizes:er.sizes,crossOrigin:er.crossOrigin,referrerPolicy:er.referrerPolicy,...ev(er.fetchPriority)};return en&&eu.default.preload?(eu.default.preload(er.src,ei),null):es.default.createElement(ec.default,null,es.default.createElement("link",{key:"__nimg-"+er.src+er.srcSet+er.sizes,rel:"preload",href:er.srcSet?void 0:er.src,...ei}))}let ek=(0,es.forwardRef)((ee,en)=>{let er=(0,es.useContext)(ep.RouterContext),ei=!er,eo=(0,es.useContext)(eh.ImageConfigContext),eu=(0,es.useMemo)(()=>{let ee=ex||eo||ef.imageConfigDefault,en=[...ee.deviceSizes,...ee.imageSizes].sort((ee,en)=>ee-en),er=ee.deviceSizes.sort((ee,en)=>ee-en);return{...ee,allSizes:en,deviceSizes:er}},[eo]),{onLoad:ec,onLoadingComplete:eg}=ee,ev=(0,es.useRef)(ec);(0,es.useEffect)(()=>{ev.current=ec},[ec]);let ek=(0,es.useRef)(eg);(0,es.useEffect)(()=>{ek.current=eg},[eg]);let[ew,e_]=(0,es.useState)(!1),[eC,eE]=(0,es.useState)(!1),{props:ej,meta:eS}=(0,ed.getImgProps)(ee,{defaultLoader:em.default,imgConf:eu,blurComplete:ew,showAltText:eC});return es.default.createElement(es.default.Fragment,null,es.default.createElement(ey,{...ej,unoptimized:eS.unoptimized,placeholder:eS.placeholder,fill:eS.fill,onLoadRef:ev,onLoadingCompleteRef:ek,setBlurComplete:e_,setShowAltText:eE,ref:en}),eS.priority?es.default.createElement(eb,{isAppRouter:ei,imgAttributes:ej}):null)});("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},7864:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"default",{enumerable:!0,get:function(){return eE}});let ei=er(1351),eo=ei._(er(959)),es=er(3578),eu=er(7462),ec=er(1541),ed=er(9249),ef=er(8565),eh=er(4621),ep=er(5444),em=er(3986),ex=er(1726),eg=er(983),ev=er(7521),ey=new Set;function eb(ee,en,er,ei,eo,es){if(!es&&!(0,eu.isLocalURL)(en))return;if(!ei.bypassPrefetchedCheck){let eo=void 0!==ei.locale?ei.locale:"locale"in ee?ee.locale:void 0,es=en+"%"+er+"%"+eo;if(ey.has(es))return;ey.add(es)}let ec=es?ee.prefetch(en,eo):ee.prefetch(en,er,ei);Promise.resolve(ec).catch(ee=>{})}function ek(ee){let en=ee.currentTarget,er=en.getAttribute("target");return er&&"_self"!==er||ee.metaKey||ee.ctrlKey||ee.shiftKey||ee.altKey||ee.nativeEvent&&2===ee.nativeEvent.which}function ew(ee,en,er,ei,es,ec,ed,ef,eh,ep){let{nodeName:em}=ee.currentTarget,ex="A"===em.toUpperCase();if(ex&&(ek(ee)||!eh&&!(0,eu.isLocalURL)(er)))return;ee.preventDefault();let eg=()=>{let ee=null==ed||ed;"beforePopState"in en?en[es?"replace":"push"](er,ei,{shallow:ec,locale:ef,scroll:ee}):en[es?"replace":"push"](ei||er,{forceOptimisticNavigation:!ep,scroll:ee})};eh?eo.default.startTransition(eg):eg()}function e_(ee){return"string"==typeof ee?ee:(0,ec.formatUrl)(ee)}let eC=eo.default.forwardRef(function(ee,en){let er,ei;let{href:eu,as:ec,children:ey,prefetch:ek=null,passHref:eC,replace:eE,shallow:ej,scroll:eS,locale:eO,onClick:eM,onMouseEnter:eT,onTouchStart:eN,legacyBehavior:eP=!1,...eI}=ee;er=ey,eP&&("string"==typeof er||"number"==typeof er)&&(er=eo.default.createElement("a",null,er));let eR=eo.default.useContext(eh.RouterContext),eA=eo.default.useContext(ep.AppRouterContext),eL=null!=eR?eR:eA,eF=!eR,eZ=!1!==ek,eD=null===ek?ev.PrefetchKind.AUTO:ev.PrefetchKind.FULL,{href:ez,as:e$}=eo.default.useMemo(()=>{if(!eR){let ee=e_(eu);return{href:ee,as:ec?e_(ec):ee}}let[ee,en]=(0,es.resolveHref)(eR,eu,!0);return{href:ee,as:ec?(0,es.resolveHref)(eR,ec):en||ee}},[eR,eu,ec]),eG=eo.default.useRef(ez),eU=eo.default.useRef(e$);eP&&(ei=eo.default.Children.only(er));let eW=eP?ei&&"object"==typeof ei&&ei.ref:en,[eV,eH,eB]=(0,em.useIntersection)({rootMargin:"200px"}),eq=eo.default.useCallback(ee=>{(eU.current!==e$||eG.current!==ez)&&(eB(),eU.current=e$,eG.current=ez),eV(ee),eW&&("function"==typeof eW?eW(ee):"object"==typeof eW&&(eW.current=ee))},[e$,eW,ez,eB,eV]);eo.default.useEffect(()=>{eL&&eH&&eZ&&eb(eL,ez,e$,{locale:eO},{kind:eD},eF)},[e$,ez,eH,eO,eZ,null==eR?void 0:eR.locale,eL,eF,eD]);let eK={ref:eq,onClick(ee){eP||"function"!=typeof eM||eM(ee),eP&&ei.props&&"function"==typeof ei.props.onClick&&ei.props.onClick(ee),eL&&!ee.defaultPrevented&&ew(ee,eL,ez,e$,eE,ej,eS,eO,eF,eZ)},onMouseEnter(ee){eP||"function"!=typeof eT||eT(ee),eP&&ei.props&&"function"==typeof ei.props.onMouseEnter&&ei.props.onMouseEnter(ee),eL&&(eZ||!eF)&&eb(eL,ez,e$,{locale:eO,priority:!0,bypassPrefetchedCheck:!0},{kind:eD},eF)},onTouchStart(ee){eP||"function"!=typeof eN||eN(ee),eP&&ei.props&&"function"==typeof ei.props.onTouchStart&&ei.props.onTouchStart(ee),eL&&(eZ||!eF)&&eb(eL,ez,e$,{locale:eO,priority:!0,bypassPrefetchedCheck:!0},{kind:eD},eF)}};if((0,ed.isAbsoluteUrl)(e$))eK.href=e$;else if(!eP||eC||"a"===ei.type&&!("href"in ei.props)){let ee=void 0!==eO?eO:null==eR?void 0:eR.locale,en=(null==eR?void 0:eR.isLocaleDomain)&&(0,ex.getDomainLocale)(e$,ee,null==eR?void 0:eR.locales,null==eR?void 0:eR.domainLocales);eK.href=en||(0,eg.addBasePath)((0,ef.addLocale)(e$,ee,null==eR?void 0:eR.defaultLocale))}return eP?eo.default.cloneElement(ei,eK):eo.default.createElement("a",{...eI,...eK},er)}),eE=eC;("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},3986:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"useIntersection",{enumerable:!0,get:function(){return eh}});let ei=er(959),eo=er(2097),es="function"==typeof IntersectionObserver,eu=new Map,ec=[];function ed(ee){let en;let er={root:ee.root||null,margin:ee.rootMargin||""},ei=ec.find(ee=>ee.root===er.root&&ee.margin===er.margin);if(ei&&(en=eu.get(ei)))return en;let eo=new Map,es=new IntersectionObserver(ee=>{ee.forEach(ee=>{let en=eo.get(ee.target),er=ee.isIntersecting||ee.intersectionRatio>0;en&&er&&en(er)})},ee);return en={id:er,observer:es,elements:eo},ec.push(er),eu.set(er,en),en}function ef(ee,en,er){let{id:ei,observer:eo,elements:es}=ed(er);return es.set(ee,en),eo.observe(ee),function(){if(es.delete(ee),eo.unobserve(ee),0===es.size){eo.disconnect(),eu.delete(ei);let ee=ec.findIndex(ee=>ee.root===ei.root&&ee.margin===ei.margin);ee>-1&&ec.splice(ee,1)}}}function eh(ee){let{rootRef:en,rootMargin:er,disabled:eu}=ee,ec=eu||!es,[ed,eh]=(0,ei.useState)(!1),ep=(0,ei.useRef)(null),em=(0,ei.useCallback)(ee=>{ep.current=ee},[]);(0,ei.useEffect)(()=>{if(es){if(ec||ed)return;let ee=ep.current;if(ee&&ee.tagName){let ei=ef(ee,ee=>ee&&eh(ee),{root:null==en?void 0:en.current,rootMargin:er});return ei}}else if(!ed){let ee=(0,eo.requestIdleCallback)(()=>eh(!0));return()=>(0,eo.cancelIdleCallback)(ee)}},[ec,er,en,ed,ep.current]);let ex=(0,ei.useCallback)(()=>{eh(!1)},[]);return[em,ed,ex]}("function"==typeof en.default||"object"==typeof en.default&&null!==en.default)&&void 0===en.default.__esModule&&(Object.defineProperty(en.default,"__esModule",{value:!0}),Object.assign(en.default,en),ee.exports=en.default)},8009:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"getImgProps",{enumerable:!0,get:function(){return ep}}),er(5393);let ei=er(8755),eo=er(9327);function es(ee){return void 0!==ee.default}function eu(ee){return void 0!==ee.src}function ec(ee){return"object"==typeof ee&&(es(ee)||eu(ee))}function ed(ee){return void 0===ee?ee:"number"==typeof ee?Number.isFinite(ee)?ee:NaN:"string"==typeof ee&&/^[0-9]+$/.test(ee)?parseInt(ee,10):NaN}function ef(ee,en,er){let{deviceSizes:ei,allSizes:eo}=ee;if(er){let ee=/(^|\s)(1?\d?\d)vw/g,en=[];for(let ei;ei=ee.exec(er);ei)en.push(parseInt(ei[2]));if(en.length){let ee=.01*Math.min(...en);return{widths:eo.filter(en=>en>=ei[0]*ee),kind:"w"}}return{widths:eo,kind:"w"}}if("number"!=typeof en)return{widths:ei,kind:"w"};let es=[...new Set([en,2*en].map(ee=>eo.find(en=>en>=ee)||eo[eo.length-1]))];return{widths:es,kind:"x"}}function eh(ee){let{config:en,src:er,unoptimized:ei,width:eo,quality:es,sizes:eu,loader:ec}=ee;if(ei)return{src:er,srcSet:void 0,sizes:void 0};let{widths:ed,kind:eh}=ef(en,eo,eu),ep=ed.length-1;return{sizes:eu||"w"!==eh?eu:"100vw",srcSet:ed.map((ee,ei)=>ec({config:en,src:er,quality:es,width:ee})+" "+("w"===eh?ee:ei+1)+eh).join(", "),src:ec({config:en,src:er,quality:es,width:ed[ep]})}}function ep(ee,en){let er,eu,ef,{src:ep,sizes:em,unoptimized:ex=!1,priority:eg=!1,loading:ev,className:ey,quality:eb,width:ek,height:ew,fill:e_=!1,style:eC,onLoad:eE,onLoadingComplete:ej,placeholder:eS="empty",blurDataURL:eO,fetchPriority:eM,layout:eT,objectFit:eN,objectPosition:eP,lazyBoundary:eI,lazyRoot:eR,...eA}=ee,{imgConf:eL,showAltText:eF,blurComplete:eZ,defaultLoader:eD}=en,ez=eL||eo.imageConfigDefault;if("allSizes"in ez)er=ez;else{let ee=[...ez.deviceSizes,...ez.imageSizes].sort((ee,en)=>ee-en),en=ez.deviceSizes.sort((ee,en)=>ee-en);er={...ez,allSizes:ee,deviceSizes:en}}let e$=eA.loader||eD;delete eA.loader,delete eA.srcSet;let eG="__next_img_default"in e$;if(eG){if("custom"===er.loader)throw Error('Image with src "'+ep+'" is missing "loader" prop.\nRead more: https://nextjs.org/docs/messages/next-image-missing-loader')}else{let ee=e$;e$=en=>{let{config:er,...ei}=en;return ee(ei)}}if(eT){"fill"===eT&&(e_=!0);let ee={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}},en={responsive:"100vw",fill:"100vw"},er=ee[eT];er&&(eC={...eC,...er});let ei=en[eT];ei&&!em&&(em=ei)}let eU="",eW=ed(ek),eV=ed(ew);if(ec(ep)){let ee=es(ep)?ep.default:ep;if(!ee.src)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received "+JSON.stringify(ee));if(!ee.height||!ee.width)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received "+JSON.stringify(ee));if(eu=ee.blurWidth,ef=ee.blurHeight,eO=eO||ee.blurDataURL,eU=ee.src,!e_){if(eW||eV){if(eW&&!eV){let en=eW/ee.width;eV=Math.round(ee.height*en)}else if(!eW&&eV){let en=eV/ee.height;eW=Math.round(ee.width*en)}}else eW=ee.width,eV=ee.height}}let eH=!eg&&("lazy"===ev||void 0===ev);(!(ep="string"==typeof ep?ep:eU)||ep.startsWith("data:")||ep.startsWith("blob:"))&&(ex=!0,eH=!1),er.unoptimized&&(ex=!0),eG&&ep.endsWith(".svg")&&!er.dangerouslyAllowSVG&&(ex=!0),eg&&(eM="high");let eB=ed(eb),eq=Object.assign(e_?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:eN,objectPosition:eP}:{},eF?{}:{color:"transparent"},eC),eK=eZ||"empty"===eS?null:"blur"===eS?'url("data:image/svg+xml;charset=utf-8,'+(0,ei.getImageBlurSvg)({widthInt:eW,heightInt:eV,blurWidth:eu,blurHeight:ef,blurDataURL:eO||"",objectFit:eq.objectFit})+'")':'url("'+eS+'")',eY=eK?{backgroundSize:eq.objectFit||"cover",backgroundPosition:eq.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:eK}:{},eQ=eh({config:er,src:ep,unoptimized:ex,width:eW,quality:eB,sizes:em,loader:e$}),eJ={...eA,loading:eH?"lazy":ev,fetchPriority:eM,width:eW,height:eV,decoding:"async",className:ey,style:{...eq,...eY},sizes:eQ.sizes,srcSet:eQ.srcSet,src:eQ.src},eX={unoptimized:ex,priority:eg,placeholder:eS,fill:e_};return{props:eJ,meta:eX}}},8755:function(ee,en){"use strict";function er(ee){let{widthInt:en,heightInt:er,blurWidth:ei,blurHeight:eo,blurDataURL:es,objectFit:eu}=ee,ec=20,ed=ei?40*ei:en,ef=eo?40*eo:er,eh=ed&&ef?"viewBox='0 0 "+ed+" "+ef+"'":"",ep=eh?"none":"contain"===eu?"xMidYMid":"cover"===eu?"xMidYMid slice":"none";return"%3Csvg xmlns='http://www.w3.org/2000/svg' "+eh+"%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='"+ec+"'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='"+ec+"'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='"+ep+"' style='filter: url(%23b);' href='"+es+"'/%3E%3C/svg%3E"}Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"getImageBlurSvg",{enumerable:!0,get:function(){return er}})},257:function(ee,en,er){"use strict";Object.defineProperty(en,"__esModule",{value:!0}),function(ee,en){for(var er in en)Object.defineProperty(ee,er,{enumerable:!0,get:en[er]})}(en,{default:function(){return ef},unstable_getImgProps:function(){return ed}});let ei=er(1351),eo=er(8009),es=er(5393),eu=er(759),ec=ei._(er(2685)),ed=ee=>{(0,es.warnOnce)("Warning: unstable_getImgProps() is experimental and may change or be removed at any time. Use at your own risk.");let{props:en}=(0,eo.getImgProps)(ee,{defaultLoader:ec.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!0}});for(let[ee,er]of Object.entries(en))void 0===er&&delete en[ee];return{props:en}},ef=eu.Image},2685:function(ee,en){"use strict";function er(ee){let{config:en,src:er,width:ei,quality:eo}=ee;return en.path+"?url="+encodeURIComponent(er)+"&w="+ei+"&q="+(eo||75)}Object.defineProperty(en,"__esModule",{value:!0}),Object.defineProperty(en,"default",{enumerable:!0,get:function(){return ei}}),er.__next_img_default=!0;let ei=er},7771:function(){},1803:function(){},2084:function(ee){var en="/";!function(){"use strict";var er={114:function(ee){function en(ee){if("string"!=typeof ee)throw TypeError("Path must be a string. Received "+JSON.stringify(ee))}function er(ee,en){for(var er,ei="",eo=0,es=-1,eu=0,ec=0;ec<=ee.length;++ec){if(ec2){var ed=ei.lastIndexOf("/");if(ed!==ei.length-1){-1===ed?(ei="",eo=0):eo=(ei=ei.slice(0,ed)).length-1-ei.lastIndexOf("/"),es=ec,eu=0;continue}}else if(2===ei.length||1===ei.length){ei="",eo=0,es=ec,eu=0;continue}}en&&(ei.length>0?ei+="/..":ei="..",eo=2)}else ei.length>0?ei+="/"+ee.slice(es+1,ec):ei=ee.slice(es+1,ec),eo=ec-es-1;es=ec,eu=0}else 46===er&&-1!==eu?++eu:eu=-1}return ei}function ei(ee,en){var er=en.dir||en.root,ei=en.base||(en.name||"")+(en.ext||"");return er?er===en.root?er+ei:er+ee+ei:ei}var eo={resolve:function(){for(var ee,ei,eo="",es=!1,eu=arguments.length-1;eu>=-1&&!es;eu--)eu>=0?ei=arguments[eu]:(void 0===ee&&(ee=""),ei=ee),en(ei),0!==ei.length&&(eo=ei+"/"+eo,es=47===ei.charCodeAt(0));return(eo=er(eo,!es),es)?eo.length>0?"/"+eo:"/":eo.length>0?eo:"."},normalize:function(ee){if(en(ee),0===ee.length)return".";var ei=47===ee.charCodeAt(0),eo=47===ee.charCodeAt(ee.length-1);return(0!==(ee=er(ee,!ei)).length||ei||(ee="."),ee.length>0&&eo&&(ee+="/"),ei)?"/"+ee:ee},isAbsolute:function(ee){return en(ee),ee.length>0&&47===ee.charCodeAt(0)},join:function(){if(0==arguments.length)return".";for(var ee,er=0;er0&&(void 0===ee?ee=ei:ee+="/"+ei)}return void 0===ee?".":eo.normalize(ee)},relative:function(ee,er){if(en(ee),en(er),ee===er||(ee=eo.resolve(ee))===(er=eo.resolve(er)))return"";for(var ei=1;eief){if(47===er.charCodeAt(ec+ep))return er.slice(ec+ep+1);if(0===ep)return er.slice(ec+ep)}else eu>ef&&(47===ee.charCodeAt(ei+ep)?eh=ep:0===ep&&(eh=0));break}var em=ee.charCodeAt(ei+ep);if(em!==er.charCodeAt(ec+ep))break;47===em&&(eh=ep)}var ex="";for(ep=ei+eh+1;ep<=es;++ep)(ep===es||47===ee.charCodeAt(ep))&&(0===ex.length?ex+="..":ex+="/..");return ex.length>0?ex+er.slice(ec+eh):(ec+=eh,47===er.charCodeAt(ec)&&++ec,er.slice(ec))},_makeLong:function(ee){return ee},dirname:function(ee){if(en(ee),0===ee.length)return".";for(var er=ee.charCodeAt(0),ei=47===er,eo=-1,es=!0,eu=ee.length-1;eu>=1;--eu)if(47===(er=ee.charCodeAt(eu))){if(!es){eo=eu;break}}else es=!1;return -1===eo?ei?"/":".":ei&&1===eo?"//":ee.slice(0,eo)},basename:function(ee,er){if(void 0!==er&&"string"!=typeof er)throw TypeError('"ext" argument must be a string');en(ee);var ei,eo=0,es=-1,eu=!0;if(void 0!==er&&er.length>0&&er.length<=ee.length){if(er.length===ee.length&&er===ee)return"";var ec=er.length-1,ed=-1;for(ei=ee.length-1;ei>=0;--ei){var ef=ee.charCodeAt(ei);if(47===ef){if(!eu){eo=ei+1;break}}else -1===ed&&(eu=!1,ed=ei+1),ec>=0&&(ef===er.charCodeAt(ec)?-1==--ec&&(es=ei):(ec=-1,es=ed))}return eo===es?es=ed:-1===es&&(es=ee.length),ee.slice(eo,es)}for(ei=ee.length-1;ei>=0;--ei)if(47===ee.charCodeAt(ei)){if(!eu){eo=ei+1;break}}else -1===es&&(eu=!1,es=ei+1);return -1===es?"":ee.slice(eo,es)},extname:function(ee){en(ee);for(var er=-1,ei=0,eo=-1,es=!0,eu=0,ec=ee.length-1;ec>=0;--ec){var ed=ee.charCodeAt(ec);if(47===ed){if(!es){ei=ec+1;break}continue}-1===eo&&(es=!1,eo=ec+1),46===ed?-1===er?er=ec:1!==eu&&(eu=1):-1!==er&&(eu=-1)}return -1===er||-1===eo||0===eu||1===eu&&er===eo-1&&er===ei+1?"":ee.slice(er,eo)},format:function(ee){if(null===ee||"object"!=typeof ee)throw TypeError('The "pathObject" argument must be of type Object. Received type '+typeof ee);return ei("/",ee)},parse:function(ee){en(ee);var er,ei={root:"",dir:"",base:"",ext:"",name:""};if(0===ee.length)return ei;var eo=ee.charCodeAt(0),es=47===eo;es?(ei.root="/",er=1):er=0;for(var eu=-1,ec=0,ed=-1,ef=!0,eh=ee.length-1,ep=0;eh>=er;--eh){if(47===(eo=ee.charCodeAt(eh))){if(!ef){ec=eh+1;break}continue}-1===ed&&(ef=!1,ed=eh+1),46===eo?-1===eu?eu=eh:1!==ep&&(ep=1):-1!==eu&&(ep=-1)}return -1===eu||-1===ed||0===ep||1===ep&&eu===ed-1&&eu===ec+1?-1!==ed&&(0===ec&&es?ei.base=ei.name=ee.slice(1,ed):ei.base=ei.name=ee.slice(ec,ed)):(0===ec&&es?(ei.name=ee.slice(1,eu),ei.base=ee.slice(1,ed)):(ei.name=ee.slice(ec,eu),ei.base=ee.slice(ec,ed)),ei.ext=ee.slice(eu,ed)),ec>0?ei.dir=ee.slice(0,ec-1):es&&(ei.dir="/"),ei},sep:"/",delimiter:":",win32:null,posix:null};eo.posix=eo,ee.exports=eo}},ei={};function eo(ee){var en=ei[ee];if(void 0!==en)return en.exports;var es=ei[ee]={exports:{}},eu=!0;try{er[ee](es,es.exports,eo),eu=!1}finally{eu&&delete ei[ee]}return es.exports}eo.ab=en+"/";var es=eo(114);ee.exports=es}()},4529:function(ee){var en="/";!function(){var er={229:function(ee){var en,er,ei,eo=ee.exports={};function es(){throw Error("setTimeout has not been defined")}function eu(){throw Error("clearTimeout has not been defined")}function ec(ee){if(en===setTimeout)return setTimeout(ee,0);if((en===es||!en)&&setTimeout)return en=setTimeout,setTimeout(ee,0);try{return en(ee,0)}catch(er){try{return en.call(null,ee,0)}catch(er){return en.call(this,ee,0)}}}function ed(ee){if(er===clearTimeout)return clearTimeout(ee);if((er===eu||!er)&&clearTimeout)return er=clearTimeout,clearTimeout(ee);try{return er(ee)}catch(en){try{return er.call(null,ee)}catch(en){return er.call(this,ee)}}}!function(){try{en="function"==typeof setTimeout?setTimeout:es}catch(ee){en=es}try{er="function"==typeof clearTimeout?clearTimeout:eu}catch(ee){er=eu}}();var ef=[],eh=!1,ep=-1;function em(){eh&&ei&&(eh=!1,ei.length?ef=ei.concat(ef):ep=-1,ef.length&&ex())}function ex(){if(!eh){var ee=ec(em);eh=!0;for(var en=ef.length;en;){for(ei=ef,ef=[];++ep1)for(var er=1;er(0,ec.jsx)("button",{className:(0,eu.Z)("nextra-button nx-transition-all active:nx-opacity-50","nx-bg-primary-700/5 nx-border nx-border-black/5 nx-text-gray-600 hover:nx-text-gray-900 nx-rounded-md nx-p-1.5","dark:nx-bg-primary-300/10 dark:nx-border-white/10 dark:nx-text-gray-400 dark:hover:nx-text-gray-50",en),...er,children:ee}),ef=er(456),eh={default:"\uD83D\uDCA1",error:"\uD83D\uDEAB",info:(0,ec.jsx)(ef.AV,{className:"nx-mt-1"}),warning:"⚠️"},ep={default:(0,eu.Z)("nx-border-orange-100 nx-bg-orange-50 nx-text-orange-800 dark:nx-border-orange-400/30 dark:nx-bg-orange-400/20 dark:nx-text-orange-300"),error:(0,eu.Z)("nx-border-red-200 nx-bg-red-100 nx-text-red-900 dark:nx-border-red-200/30 dark:nx-bg-red-900/30 dark:nx-text-red-200"),info:(0,eu.Z)("nx-border-blue-200 nx-bg-blue-100 nx-text-blue-900 dark:nx-border-blue-200/30 dark:nx-bg-blue-900/30 dark:nx-text-blue-200"),warning:(0,eu.Z)("nx-border-yellow-100 nx-bg-yellow-50 nx-text-yellow-900 dark:nx-border-yellow-200/30 dark:nx-bg-yellow-700/30 dark:nx-text-yellow-200")};function em({children:ee,type:en="default",emoji:er=eh[en]}){return(0,ec.jsxs)("div",{className:(0,eu.Z)("nextra-callout nx-overflow-x-auto nx-mt-6 nx-flex nx-rounded-lg nx-border nx-py-2 ltr:nx-pr-4 rtl:nx-pl-4","contrast-more:nx-border-current contrast-more:dark:nx-border-current",ep[en]),children:[(0,ec.jsx)("div",{className:"nx-select-none nx-text-xl ltr:nx-pl-3 ltr:nx-pr-2 rtl:nx-pr-3 rtl:nx-pl-2",style:{fontFamily:'"Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"'},children:er}),(0,ec.jsx)("div",{className:"nx-w-full nx-min-w-0 nx-leading-7",children:ee})]})}var ex=er(959),eg=({getValue:ee,...en})=>{let[er,ei]=(0,ex.useState)(!1);(0,ex.useEffect)(()=>{if(!er)return;let ee=setTimeout(()=>{ei(!1)},2e3);return()=>{clearTimeout(ee)}},[er]);let eo=(0,ex.useCallback)(async()=>{ei(!0),navigator?.clipboard||console.error("Access to clipboard rejected!");try{await navigator.clipboard.writeText(ee())}catch{console.error("Failed to copy!")}},[ee]),es=er?ef.nQ:ef.TI;return(0,ec.jsx)(ed,{onClick:eo,title:"Copy code",tabIndex:0,...en,children:(0,ec.jsx)(es,{className:"nextra-copy-icon nx-pointer-events-none nx-h-4 nx-w-4"})})},ev=({children:ee,className:en,...er})=>{let ei="data-line-numbers"in er;return(0,ec.jsx)("code",{className:(0,eu.Z)("nx-border-black nx-border-opacity-[0.04] nx-bg-opacity-[0.03] nx-bg-black nx-break-words nx-rounded-md nx-border nx-py-0.5 nx-px-[.25em] nx-text-[.9em]","dark:nx-border-white/10 dark:nx-bg-white/10",ei&&"[counter-reset:line]",en),dir:"ltr",...er,children:ee})},ey=({children:ee,className:en,hasCopyCode:er,filename:ei,...eo})=>{let es=(0,ex.useRef)(null),eh=(0,ex.useCallback)(()=>{let ee=document.documentElement.dataset,en="nextraWordWrap"in ee;en?delete ee.nextraWordWrap:ee.nextraWordWrap=""},[]);return(0,ec.jsxs)("div",{className:"nextra-code-block nx-relative nx-mt-6 first:nx-mt-0",children:[ei&&(0,ec.jsx)("div",{className:"nx-absolute nx-top-0 nx-z-[1] nx-w-full nx-truncate nx-rounded-t-xl nx-bg-primary-700/5 nx-py-2 nx-px-4 nx-text-xs nx-text-gray-700 dark:nx-bg-primary-300/10 dark:nx-text-gray-200",children:ei}),(0,ec.jsx)("pre",{className:(0,eu.Z)("nx-bg-primary-700/5 nx-mb-4 nx-overflow-x-auto nx-rounded-xl nx-subpixel-antialiased dark:nx-bg-primary-300/10 nx-text-[.9em]","contrast-more:nx-border contrast-more:nx-border-primary-900/20 contrast-more:nx-contrast-150 contrast-more:dark:nx-border-primary-100/40",ei?"nx-pt-12 nx-pb-4":"nx-py-4",en),ref:es,...eo,children:ee}),(0,ec.jsxs)("div",{className:(0,eu.Z)("nx-opacity-0 nx-transition [div:hover>&]:nx-opacity-100 focus-within:nx-opacity-100","nx-flex nx-gap-1 nx-absolute nx-m-[11px] nx-right-0",ei?"nx-top-8":"nx-top-0"),children:[(0,ec.jsx)(ed,{onClick:eh,className:"md:nx-hidden",title:"Toggle word wrap",children:(0,ec.jsx)(ef.NK,{className:"nx-pointer-events-none nx-h-4 nx-w-4"})}),er&&(0,ec.jsx)(eg,{getValue:()=>es.current?.querySelector("code")?.textContent||""})]})]})};function eb({children:ee,className:en,...er}){return(0,ec.jsx)("div",{className:(0,eu.Z)("nextra-steps nx-ml-4 nx-mb-12 nx-border-l nx-border-gray-200 nx-pl-6","dark:nx-border-neutral-800 [counter-reset:step]",en),...er,children:ee})}var ek=er(222),ew=er(9038),e_=er(3011),eC=er(8246),eE=er(7496),ej=er(6260),eS=er(9850),eO=er(8002),eM=er(9691),eT=er(5782),eN=er(1941);function eP({onFocus:ee}){let[en,er]=(0,ex.useState)(!0),ei=(0,eT.t)();return en?ex.createElement(eN._,{as:"button",type:"button",features:eN.A.Focusable,onFocus:en=>{en.preventDefault();let eo,es=50;function eu(){if(es--<=0){eo&&cancelAnimationFrame(eo);return}if(ee()){if(cancelAnimationFrame(eo),!ei.current)return;er(!1);return}eo=requestAnimationFrame(eu)}eo=requestAnimationFrame(eu)}}):null}var eI=er(6510),eR=er(1287),eA=er(9195);let eL=ex.createContext(null);function eF(){return{groups:new Map,get(ee,en){var er;let ei=this.groups.get(ee);ei||(ei=new Map,this.groups.set(ee,ei));let eo=null!=(er=ei.get(en))?er:0;function es(){let ee=ei.get(en);ee>1?ei.set(en,ee-1):ei.delete(en)}return ei.set(en,eo+1),[Array.from(ei.keys()).indexOf(en),es]}}}function eZ({children:ee}){let en=ex.useRef(eF());return ex.createElement(eL.Provider,{value:en},ee)}function eD(ee){let en=ex.useContext(eL);if(!en)throw Error("You must wrap your component in a ");let er=ez(),[ei,eo]=en.current.get(ee,er);return ex.useEffect(()=>eo,[]),ei}function ez(){var ee,en,er;let ei=null!=(er=null==(en=null==(ee=ex.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED)?void 0:ee.ReactCurrentOwner)?void 0:en.current)?er:null;if(!ei)return Symbol();let eo=[],es=ei;for(;es;)eo.push(es.index),es=es.return;return"$."+eo.join(".")}var e$=((ei=e$||{})[ei.Forwards=0]="Forwards",ei[ei.Backwards=1]="Backwards",ei),eG=((eo=eG||{})[eo.Less=-1]="Less",eo[eo.Equal=0]="Equal",eo[eo.Greater=1]="Greater",eo),eU=((es=eU||{})[es.SetSelectedIndex=0]="SetSelectedIndex",es[es.RegisterTab=1]="RegisterTab",es[es.UnregisterTab=2]="UnregisterTab",es[es.RegisterPanel=3]="RegisterPanel",es[es.UnregisterPanel=4]="UnregisterPanel",es);let eW={0(ee,en){var er;let ei=(0,eE.z2)(ee.tabs,ee=>ee.current),eo=(0,eE.z2)(ee.panels,ee=>ee.current),es=ei.filter(ee=>{var en;return!(null!=(en=ee.current)&&en.hasAttribute("disabled"))}),eu={...ee,tabs:ei,panels:eo};if(en.index<0||en.index>ei.length-1){let er=(0,e_.E)(Math.sign(en.index-ee.selectedIndex),{[-1]:()=>1,0:()=>(0,e_.E)(Math.sign(en.index),{[-1]:()=>0,0:()=>0,1:()=>1}),1:()=>0});if(0===es.length)return eu;let eo=(0,e_.E)(er,{0:()=>ei.indexOf(es[0]),1:()=>ei.indexOf(es[es.length-1])});return{...eu,selectedIndex:-1===eo?ee.selectedIndex:eo}}let ec=ei.slice(0,en.index),ed=[...ei.slice(en.index),...ec].find(ee=>es.includes(ee));if(!ed)return eu;let ef=null!=(er=ei.indexOf(ed))?er:ee.selectedIndex;return -1===ef&&(ef=ee.selectedIndex),{...eu,selectedIndex:ef}},1(ee,en){var er;if(ee.tabs.includes(en.tab))return ee;let ei=ee.tabs[ee.selectedIndex],eo=(0,eE.z2)([...ee.tabs,en.tab],ee=>ee.current),es=null!=(er=eo.indexOf(ei))?er:ee.selectedIndex;return -1===es&&(es=ee.selectedIndex),{...ee,tabs:eo,selectedIndex:es}},2:(ee,en)=>({...ee,tabs:ee.tabs.filter(ee=>ee!==en.tab)}),3:(ee,en)=>ee.panels.includes(en.panel)?ee:{...ee,panels:(0,eE.z2)([...ee.panels,en.panel],ee=>ee.current)},4:(ee,en)=>({...ee,panels:ee.panels.filter(ee=>ee!==en.panel)})},eV=(0,ex.createContext)(null);function eH(ee){let en=(0,ex.useContext)(eV);if(null===en){let en=Error(`<${ee} /> is missing a parent component.`);throw Error.captureStackTrace&&Error.captureStackTrace(en,eH),en}return en}eV.displayName="TabsDataContext";let eB=(0,ex.createContext)(null);function eq(ee){let en=(0,ex.useContext)(eB);if(null===en){let en=Error(`<${ee} /> is missing a parent component.`);throw Error.captureStackTrace&&Error.captureStackTrace(en,eq),en}return en}function eK(ee,en){return(0,e_.E)(en.type,eW,ee,en)}eB.displayName="TabsActionsContext";let eY=ex.Fragment;function eQ(ee,en){let{defaultIndex:er=0,vertical:ei=!1,manual:eo=!1,onChange:es,selectedIndex:eu=null,...ec}=ee,ed=ei?"vertical":"horizontal",ef=eo?"manual":"auto",eh=null!==eu,ep=(0,eS.T)(en),[em,eg]=(0,ex.useReducer)(eK,{selectedIndex:null!=eu?eu:er,tabs:[],panels:[]}),ev=(0,ex.useMemo)(()=>({selectedIndex:em.selectedIndex}),[em.selectedIndex]),ey=(0,eM.E)(es||(()=>{})),eb=(0,eM.E)(em.tabs),ew=(0,ex.useMemo)(()=>({orientation:ed,activation:ef,...em}),[ed,ef,em]),e_=(0,eI.z)(ee=>(eg({type:1,tab:ee}),()=>eg({type:2,tab:ee}))),eC=(0,eI.z)(ee=>(eg({type:3,panel:ee}),()=>eg({type:4,panel:ee}))),eO=(0,eI.z)(ee=>{eT.current!==ee&&ey.current(ee),eh||eg({type:0,index:ee})}),eT=(0,eM.E)(eh?ee.selectedIndex:em.selectedIndex),eN=(0,ex.useMemo)(()=>({registerTab:e_,registerPanel:eC,change:eO}),[]);(0,ej.e)(()=>{eg({type:0,index:null!=eu?eu:er})},[eu]),(0,ej.e)(()=>{if(void 0===eT.current||em.tabs.length<=0)return;let ee=(0,eE.z2)(em.tabs,ee=>ee.current);ee.some((ee,en)=>em.tabs[en]!==ee)&&eO(ee.indexOf(em.tabs[eT.current]))});let eR={ref:ep};return ex.createElement(eZ,null,ex.createElement(eB.Provider,{value:eN},ex.createElement(eV.Provider,{value:ew},ew.tabs.length<=0&&ex.createElement(eP,{onFocus:()=>{var ee,en;for(let er of eb.current)if((null==(ee=er.current)?void 0:ee.tabIndex)===0)return null==(en=er.current)||en.focus(),!0;return!1}}),(0,ek.sY)({ourProps:eR,theirProps:ec,slot:ev,defaultTag:eY,name:"Tabs"}))))}let eJ="div";function eX(ee,en){let{orientation:er,selectedIndex:ei}=eH("Tab.List"),eo=(0,eS.T)(en);return(0,ek.sY)({ourProps:{ref:eo,role:"tablist","aria-orientation":er},theirProps:ee,slot:{selectedIndex:ei},defaultTag:eJ,name:"Tabs.List"})}let e0="button";function e1(ee,en){var er,ei;let eo=(0,ew.M)(),{id:es=`headlessui-tabs-tab-${eo}`,...eu}=ee,{orientation:ec,activation:ed,selectedIndex:ef,tabs:eh,panels:ep}=eH("Tab"),em=eq("Tab"),eg=eH("Tab"),ev=(0,ex.useRef)(null),ey=(0,eS.T)(ev,en);(0,ej.e)(()=>em.registerTab(ev),[em,ev]);let eb=eD("tabs"),eM=eh.indexOf(ev);-1===eM&&(eM=eb);let eT=eM===ef,eN=(0,eI.z)(ee=>{var en;let er=ee();if(er===eE.fE.Success&&"auto"===ed){let ee=null==(en=(0,eA.r)(ev))?void 0:en.activeElement,er=eg.tabs.findIndex(en=>en.current===ee);-1!==er&&em.change(er)}return er}),eP=(0,eI.z)(ee=>{let en=eh.map(ee=>ee.current).filter(Boolean);if(ee.key===eC.R.Space||ee.key===eC.R.Enter){ee.preventDefault(),ee.stopPropagation(),em.change(eM);return}switch(ee.key){case eC.R.Home:case eC.R.PageUp:return ee.preventDefault(),ee.stopPropagation(),eN(()=>(0,eE.jA)(en,eE.TO.First));case eC.R.End:case eC.R.PageDown:return ee.preventDefault(),ee.stopPropagation(),eN(()=>(0,eE.jA)(en,eE.TO.Last))}if(eN(()=>(0,e_.E)(ec,{vertical:()=>ee.key===eC.R.ArrowUp?(0,eE.jA)(en,eE.TO.Previous|eE.TO.WrapAround):ee.key===eC.R.ArrowDown?(0,eE.jA)(en,eE.TO.Next|eE.TO.WrapAround):eE.fE.Error,horizontal:()=>ee.key===eC.R.ArrowLeft?(0,eE.jA)(en,eE.TO.Previous|eE.TO.WrapAround):ee.key===eC.R.ArrowRight?(0,eE.jA)(en,eE.TO.Next|eE.TO.WrapAround):eE.fE.Error}))===eE.fE.Success)return ee.preventDefault()}),eL=(0,ex.useRef)(!1),eF=(0,eI.z)(()=>{var ee;eL.current||(eL.current=!0,null==(ee=ev.current)||ee.focus({preventScroll:!0}),em.change(eM),(0,eR.Y)(()=>{eL.current=!1}))}),eZ=(0,eI.z)(ee=>{ee.preventDefault()}),ez=(0,ex.useMemo)(()=>({selected:eT}),[eT]),e$={ref:ey,onKeyDown:eP,onMouseDown:eZ,onClick:eF,id:es,role:"tab",type:(0,eO.f)(ee,ev),"aria-controls":null==(ei=null==(er=ep[eM])?void 0:er.current)?void 0:ei.id,"aria-selected":eT,tabIndex:eT?0:-1};return(0,ek.sY)({ourProps:e$,theirProps:eu,slot:ez,defaultTag:e0,name:"Tabs.Tab"})}let e2="div";function e4(ee,en){let{selectedIndex:er}=eH("Tab.Panels"),ei=(0,eS.T)(en),eo=(0,ex.useMemo)(()=>({selectedIndex:er}),[er]);return(0,ek.sY)({ourProps:{ref:ei},theirProps:ee,slot:eo,defaultTag:e2,name:"Tabs.Panels"})}let e5="div",e3=ek.AN.RenderStrategy|ek.AN.Static;function e7(ee,en){var er,ei,eo,es;let eu=(0,ew.M)(),{id:ec=`headlessui-tabs-panel-${eu}`,tabIndex:ed=0,...ef}=ee,{selectedIndex:eh,tabs:ep,panels:em}=eH("Tab.Panel"),eg=eq("Tab.Panel"),ev=(0,ex.useRef)(null),ey=(0,eS.T)(ev,en);(0,ej.e)(()=>eg.registerPanel(ev),[eg,ev]);let eb=eD("panels"),e_=em.indexOf(ev);-1===e_&&(e_=eb);let eC=e_===eh,eE=(0,ex.useMemo)(()=>({selected:eC}),[eC]),eO={ref:ey,id:ec,role:"tabpanel","aria-labelledby":null==(ei=null==(er=ep[e_])?void 0:er.current)?void 0:ei.id,tabIndex:eC?ed:-1};return eC||null!=(eo=ef.unmount)&&!eo||null!=(es=ef.static)&&es?(0,ek.sY)({ourProps:eO,theirProps:ef,slot:eE,defaultTag:e5,features:e3,visible:eC,name:"Tabs.Panel"}):ex.createElement(eN._,{as:"span",...eO})}let e6=Object.assign((0,ek.yV)(e1),{Group:(0,ek.yV)(eQ),List:(0,ek.yV)(eX),Panels:(0,ek.yV)(e4),Panel:(0,ek.yV)(e7)});function e9(ee){return!!ee&&"object"==typeof ee&&"label"in ee}function e8({children:ee,...en}){return(0,ec.jsx)(e6.Panel,{...en,className:"nx-rounded nx-pt-6",children:ee})}var tn=Object.assign(function({items:ee,selectedIndex:en,defaultIndex:er=0,onChange:ei,children:eo,storageKey:es}){let[ed,ef]=(0,ex.useState)(er);(0,ex.useEffect)(()=>{void 0!==en&&ef(en)},[en]),(0,ex.useEffect)(()=>{if(!es)return;function ee(ee){ee.key===es&&ef(Number(ee.newValue))}let en=Number(localStorage.getItem(es));return ef(Number.isNaN(en)?0:en),window.addEventListener("storage",ee),()=>{window.removeEventListener("storage",ee)}},[]);let eh=(0,ex.useCallback)(ee=>{if(es){let en=String(ee);localStorage.setItem(es,en),window.dispatchEvent(new StorageEvent("storage",{key:es,newValue:en}));return}ef(ee),ei?.(ee)},[]);return(0,ec.jsxs)(e6.Group,{selectedIndex:ed,defaultIndex:er,onChange:eh,children:[(0,ec.jsx)("div",{className:"nextra-scrollbar nx-overflow-x-auto nx-overflow-y-hidden nx-overscroll-x-contain",children:(0,ec.jsx)(e6.List,{className:"nx-mt-4 nx-flex nx-w-max nx-min-w-full nx-border-b nx-border-gray-200 nx-pb-px dark:nx-border-neutral-800",children:ee.map((ee,en)=>{let er=e9(ee)&&ee.disabled;return(0,ec.jsx)(e6,{disabled:er,className:({selected:ee})=>(0,eu.Z)("nx-mr-2 nx-rounded-t nx-p-2 nx-font-medium nx-leading-5 nx-transition-colors","-nx-mb-0.5 nx-select-none nx-border-b-2",ee?"nx-border-primary-500 nx-text-primary-600":"nx-border-transparent nx-text-gray-600 hover:nx-border-gray-200 hover:nx-text-black dark:nx-text-gray-200 dark:hover:nx-border-neutral-800 dark:hover:nx-text-white",er&&"nx-pointer-events-none nx-text-gray-400 dark:nx-text-neutral-600"),children:e9(ee)?ee.label:ee},en)})})}),(0,ec.jsx)(e6.Panels,{children:eo})]})},{displayName:"Tabs",Tab:e8}),tr=({className:ee="",...en})=>(0,ec.jsx)("td",{className:(0,eu.Z)("nx-m-0 nx-border nx-border-gray-300 nx-px-4 nx-py-2 dark:nx-border-gray-600",ee),...en}),ti=({className:ee="",...en})=>(0,ec.jsx)("table",{className:(0,eu.Z)("nx-block nx-overflow-x-scroll",ee),...en}),to=({className:ee="",...en})=>(0,ec.jsx)("th",{className:(0,eu.Z)("nx-m-0 nx-border nx-border-gray-300 nx-px-4 nx-py-2 nx-font-semibold dark:nx-border-gray-600",ee),...en}),ts=({className:ee="",...en})=>(0,ec.jsx)("tr",{className:(0,eu.Z)("nx-m-0 nx-border-t nx-border-gray-300 nx-p-0 dark:nx-border-gray-600","even:nx-bg-gray-100 even:dark:nx-bg-gray-600/20",ee),...en}),tl=er(1317),tu=er.n(tl),tc={cards:(0,eu.Z)("nextra-cards nx-mt-4 nx-gap-4 nx-grid","nx-not-prose"),card:(0,eu.Z)("nextra-card nx-group nx-flex nx-flex-col nx-justify-start nx-overflow-hidden nx-rounded-lg nx-border nx-border-gray-200","nx-text-current nx-no-underline dark:nx-shadow-none","hover:nx-shadow-gray-100 dark:hover:nx-shadow-none nx-shadow-gray-100","active:nx-shadow-sm active:nx-shadow-gray-200","nx-transition-all nx-duration-200 hover:nx-border-gray-300"),title:(0,eu.Z)("nx-flex nx-font-semibold nx-items-start nx-gap-2 nx-p-4 nx-text-gray-700 hover:nx-text-gray-900")},td=(0,ec.jsx)("span",{className:"nx-transition-transform nx-duration-75 group-hover:nx-translate-x-[2px]",children:"→"});Object.assign(function({children:ee,num:en=3,className:er,style:ei,...eo}){return(0,ec.jsx)("div",{className:(0,eu.Z)(tc.cards,er),...eo,style:{...ei,"--rows":en},children:ee})},{displayName:"Cards",Card:function({children:ee,title:en,icon:er,image:ei,arrow:eo,href:es,...ed}){let ef=eo?td:null;return ei?(0,ec.jsxs)(tu(),{href:es,className:(0,eu.Z)(tc.card,"nx-bg-gray-100 nx-shadow dark:nx-border-neutral-700 dark:nx-bg-neutral-800 dark:nx-text-gray-50 hover:nx-shadow-lg dark:hover:nx-border-neutral-500 dark:hover:nx-bg-neutral-700"),...ed,children:[ee,(0,ec.jsxs)("span",{className:(0,eu.Z)(tc.title,"dark:nx-text-gray-300 dark:hover:nx-text-gray-100"),children:[er,(0,ec.jsxs)("span",{className:"nx-flex nx-gap-1",children:[en,ef]})]})]}):(0,ec.jsx)(tu(),{href:es,className:(0,eu.Z)(tc.card,"nx-bg-transparent nx-shadow-sm dark:nx-border-neutral-800 hover:nx-bg-slate-50 hover:nx-shadow-md dark:hover:nx-border-neutral-700 dark:hover:nx-bg-neutral-900"),...ed,children:(0,ec.jsxs)("span",{className:(0,eu.Z)(tc.title,"dark:nx-text-neutral-200 dark:hover:nx-text-neutral-50 nx-flex nx-items-center"),children:[er,en,ef]})})}});var tf=(0,ex.createContext)(0);function th(){return(0,ex.useContext)(tf)}function tp({children:ee}){return(0,ec.jsx)("div",{className:(0,eu.Z)("nextra-filetree nx-mt-6 nx-select-none nx-text-sm nx-text-gray-800 dark:nx-text-gray-300","nx-not-prose"),children:(0,ec.jsx)("div",{className:"nx-inline-block nx-rounded-lg nx-border nx-px-4 nx-py-2 dark:nx-border-neutral-800",children:ee})})}function tm(){let ee=th();return(0,ec.jsx)(ec.Fragment,{children:Array.from({length:ee},(ee,en)=>(0,ec.jsx)("span",{className:"nx-w-5"},en))})}var tx=(0,ex.memo)(({label:ee,name:en,open:er,children:ei,defaultOpen:eo=!1,onToggle:es})=>{let eu=th(),[ed,ef]=(0,ex.useState)(eo),eh=(0,ex.useCallback)(()=>{es?.(!ed),ef(!ed)},[ed,es]),ep=void 0===er?ed:er;return(0,ec.jsxs)("li",{className:"nx-flex nx-list-none nx-flex-col",children:[(0,ec.jsxs)("button",{onClick:eh,title:en,className:"nx-inline-flex nx-cursor-pointer nx-items-center nx-py-1 hover:nx-opacity-60",children:[(0,ec.jsx)(tm,{}),(0,ec.jsx)("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",children:(0,ec.jsx)("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:ep?"M5 19a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2h4l2 2h4a2 2 0 0 1 2 2v1M5 19h14a2 2 0 0 0 2-2v-5a2 2 0 0 0-2-2H9a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2Z":"M3 7v10a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-6l-2-2H5a2 2 0 0 0-2 2Z"})}),(0,ec.jsx)("span",{className:"nx-ml-1",children:ee??en})]}),ep&&(0,ec.jsx)("ul",{children:(0,ec.jsx)(tf.Provider,{value:eu+1,children:ei})})]})});tx.displayName="Folder";var tg=(0,ex.memo)(({label:ee,name:en,active:er})=>(0,ec.jsx)("li",{className:(0,eu.Z)("nx-flex nx-list-none",er&&"nx-text-primary-600 contrast-more:nx-underline"),children:(0,ec.jsxs)("span",{className:"nx-inline-flex nx-cursor-default nx-items-center nx-py-1",children:[(0,ec.jsx)(tm,{}),(0,ec.jsx)("svg",{width:"1em",height:"1em",viewBox:"0 0 24 24",children:(0,ec.jsx)("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M9 12h6m-6 4h6m2 5H7a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5.586a1 1 0 0 1 .707.293l5.414 5.414a1 1 0 0 1 .293.707V19a2 2 0 0 1-2 2Z"})}),(0,ec.jsx)("span",{className:"nx-ml-1",children:ee??en})]})}));tg.displayName="File",Object.assign(tp,{Folder:tx,File:tg})},456:function(ee,en,er){"use strict";er.d(en,{LZ:function(){return eo},nQ:function(){return es},TI:function(){return eu},D7:function(){return ec},Qq:function(){return ed},fy:function(){return ef},n9:function(){return eh},AV:function(){return ep},Oq:function(){return em},kL:function(){return ex},L4:function(){return eg},NW:function(){return ev},NK:function(){return ey},b0:function(){return eb}});var ei=er(1527);function eo({pathClassName:ee,...en}){return(0,ei.jsx)("svg",{fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",...en,children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M9 5l7 7-7 7",className:ee})})}function es(ee){return(0,ei.jsx)("svg",{viewBox:"0 0 20 20",width:"1em",height:"1em",fill:"currentColor",...ee,children:(0,ei.jsx)("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})})}function eu(ee){return(0,ei.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",stroke:"currentColor",...ee,children:[(0,ei.jsx)("rect",{x:"9",y:"9",width:"13",height:"13",rx:"2",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),(0,ei.jsx)("path",{d:"M5 15H4C2.89543 15 2 14.1046 2 13V4C2 2.89543 2.89543 2 4 2H13C14.1046 2 15 2.89543 15 4V5",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})}function ec(ee){return(0,ei.jsxs)("svg",{width:"24",height:"24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 5 30.67 23.25",...ee,children:[(0,ei.jsx)("title",{children:"Discord"}),(0,ei.jsx)("path",{d:"M26.0015 6.9529C24.0021 6.03845 21.8787 5.37198 19.6623 5C19.3833 5.48048 19.0733 6.13144 18.8563 6.64292C16.4989 6.30193 14.1585 6.30193 11.8336 6.64292C11.6166 6.13144 11.2911 5.48048 11.0276 5C8.79575 5.37198 6.67235 6.03845 4.6869 6.9529C0.672601 12.8736 -0.41235 18.6548 0.130124 24.3585C2.79599 26.2959 5.36889 27.4739 7.89682 28.2489C8.51679 27.4119 9.07477 26.5129 9.55525 25.5675C8.64079 25.2265 7.77283 24.808 6.93587 24.312C7.15286 24.1571 7.36986 23.9866 7.57135 23.8161C12.6241 26.1255 18.0969 26.1255 23.0876 23.8161C23.3046 23.9866 23.5061 24.1571 23.7231 24.312C22.8861 24.808 22.0182 25.2265 21.1037 25.5675C21.5842 26.5129 22.1422 27.4119 22.7621 28.2489C25.2885 27.4739 27.8769 26.2959 30.5288 24.3585C31.1952 17.7559 29.4733 12.0212 26.0015 6.9529ZM10.2527 20.8402C8.73376 20.8402 7.49382 19.4608 7.49382 17.7714C7.49382 16.082 8.70276 14.7025 10.2527 14.7025C11.7871 14.7025 13.0425 16.082 13.0115 17.7714C13.0115 19.4608 11.7871 20.8402 10.2527 20.8402ZM20.4373 20.8402C18.9183 20.8402 17.6768 19.4608 17.6768 17.7714C17.6768 16.082 18.8873 14.7025 20.4373 14.7025C21.9717 14.7025 23.2271 16.082 23.1961 17.7714C23.1961 19.4608 21.9872 20.8402 20.4373 20.8402Z"})]})}function ed({isOpen:ee,...en}){return(0,ei.jsxs)("svg",{height:"12",width:"12",viewBox:"0 0 16 16",fill:"currentColor",...en,children:[(0,ei.jsx)("path",{fillRule:"evenodd",d:"M4.177 7.823l2.396-2.396A.25.25 0 017 5.604v4.792a.25.25 0 01-.427.177L4.177 8.177a.25.25 0 010-.354z",className:ee?"":"nx-origin-[35%] nx-rotate-180"}),(0,ei.jsx)("path",{fillRule:"evenodd",d:"M0 1.75C0 .784.784 0 1.75 0h12.5C15.216 0 16 .784 16 1.75v12.5A1.75 1.75 0 0114.25 16H1.75A1.75 1.75 0 010 14.25V1.75zm1.75-.25a.25.25 0 00-.25.25v12.5c0 .138.112.25.25.25H9.5v-13H1.75zm12.5 13H11v-13h3.25a.25.25 0 01.25.25v12.5a.25.25 0 01-.25.25z"})]})}function ef(ee){return(0,ei.jsxs)("svg",{width:"24",height:"24",fill:"currentColor",viewBox:"3 3 18 18",...ee,children:[(0,ei.jsx)("title",{children:"GitHub"}),(0,ei.jsx)("path",{d:"M12 3C7.0275 3 3 7.12937 3 12.2276C3 16.3109 5.57625 19.7597 9.15374 20.9824C9.60374 21.0631 9.77249 20.7863 9.77249 20.5441C9.77249 20.3249 9.76125 19.5982 9.76125 18.8254C7.5 19.2522 6.915 18.2602 6.735 17.7412C6.63375 17.4759 6.19499 16.6569 5.8125 16.4378C5.4975 16.2647 5.0475 15.838 5.80124 15.8264C6.51 15.8149 7.01625 16.4954 7.18499 16.7723C7.99499 18.1679 9.28875 17.7758 9.80625 17.5335C9.885 16.9337 10.1212 16.53 10.38 16.2993C8.3775 16.0687 6.285 15.2728 6.285 11.7432C6.285 10.7397 6.63375 9.9092 7.20749 9.26326C7.1175 9.03257 6.8025 8.08674 7.2975 6.81794C7.2975 6.81794 8.05125 6.57571 9.77249 7.76377C10.4925 7.55615 11.2575 7.45234 12.0225 7.45234C12.7875 7.45234 13.5525 7.55615 14.2725 7.76377C15.9937 6.56418 16.7475 6.81794 16.7475 6.81794C17.2424 8.08674 16.9275 9.03257 16.8375 9.26326C17.4113 9.9092 17.76 10.7281 17.76 11.7432C17.76 15.2843 15.6563 16.0687 13.6537 16.2993C13.98 16.5877 14.2613 17.1414 14.2613 18.0065C14.2613 19.2407 14.25 20.2326 14.25 20.5441C14.25 20.7863 14.4188 21.0746 14.8688 20.9824C16.6554 20.364 18.2079 19.1866 19.3078 17.6162C20.4077 16.0457 20.9995 14.1611 21 12.2276C21 7.12937 16.9725 3 12 3Z"})]})}function eh(ee){return(0,ei.jsx)("svg",{viewBox:"2 2 16 16",width:"12",height:"12",fill:"currentColor",...ee,children:(0,ei.jsx)("path",{fillRule:"evenodd",d:"M4.083 9h1.946c.089-1.546.383-2.97.837-4.118A6.004 6.004 0 004.083 9zM10 2a8 8 0 100 16 8 8 0 000-16zm0 2c-.076 0-.232.032-.465.262-.238.234-.497.623-.737 1.182-.389.907-.673 2.142-.766 3.556h3.936c-.093-1.414-.377-2.649-.766-3.556-.24-.56-.5-.948-.737-1.182C10.232 4.032 10.076 4 10 4zm3.971 5c-.089-1.546-.383-2.97-.837-4.118A6.004 6.004 0 0115.917 9h-1.946zm-2.003 2H8.032c.093 1.414.377 2.649.766 3.556.24.56.5.948.737 1.182.233.23.389.262.465.262.076 0 .232-.032.465-.262.238-.234.498-.623.737-1.182.389-.907.673-2.142.766-3.556zm1.166 4.118c.454-1.147.748-2.572.837-4.118h1.946a6.004 6.004 0 01-2.783 4.118zm-6.268 0C6.412 13.97 6.118 12.546 6.03 11H4.083a6.004 6.004 0 002.783 4.118z",clipRule:"evenodd"})})}function ep(ee){return(0,ei.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",width:"20",height:"20",...ee,children:(0,ei.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z"})})}function em(ee){return(0,ei.jsxs)("svg",{fill:"none",width:"24",height:"24",viewBox:"0 0 24 24",stroke:"currentColor",...ee,children:[(0,ei.jsx)("g",{children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M4 6h16"})}),(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M4 12h16"}),(0,ei.jsx)("g",{children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M4 18h16"})})]})}function ex(ee){return(0,ei.jsx)("svg",{fill:"none",viewBox:"2 2 20 20",width:"12",height:"12",stroke:"currentColor",...ee,children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",fill:"currentColor",d:"M20.354 15.354A9 9 0 018.646 3.646 9.003 9.003 0 0012 21a9.003 9.003 0 008.354-5.646z"})})}function eg(ee){return(0,ei.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",width:"24",height:"24",...ee,children:[(0,ei.jsx)("circle",{className:"nx-opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),(0,ei.jsx)("path",{className:"nx-opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]})}function ev(ee){return(0,ei.jsx)("svg",{fill:"none",viewBox:"3 3 18 18",width:"12",height:"12",stroke:"currentColor",...ee,children:(0,ei.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",fill:"currentColor",d:"M12 3v1m0 16v1m9-9h-1M4 12H3m15.364 6.364l-.707-.707M6.343 6.343l-.707-.707m12.728 0l-.707.707M6.343 17.657l-.707.707M16 12a4 4 0 11-8 0 4 4 0 018 0z"})})}function ey(ee){return(0,ei.jsx)("svg",{viewBox:"0 0 24 24",width:"24",height:"24",...ee,children:(0,ei.jsx)("path",{fill:"currentColor",d:"M4 19h6v-2H4v2zM20 5H4v2h16V5zm-3 6H4v2h13.25c1.1 0 2 .9 2 2s-.9 2-2 2H15v-2l-3 3l3 3v-2h2c2.21 0 4-1.79 4-4s-1.79-4-4-4z"})})}function eb(ee){return(0,ei.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"currentColor",...ee,children:(0,ei.jsx)("path",{fillRule:"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",clipRule:"evenodd"})})}},3443:function(ee,en,er){"use strict";er.d(en,{Z:function(){return ec},a:function(){return ep}});var ei=er(959);let eo=ei.createContext({});function es(ee){let en=ei.useContext(eo);return ei.useMemo(()=>"function"==typeof ee?ee(en):{...en,...ee},[en,ee])}let eu={};function ec({components:ee,children:en,disableParentContext:er}){let ec;return ec=er?"function"==typeof ee?ee({}):ee||eu:es(ee),ei.createElement(eo.Provider,{value:ec},en)}var ed=er(2389),ef=er.n(ed),eh={img:ee=>(0,ei.createElement)("object"==typeof ee.src?ef():"img",ee)},ep=ee=>es({...eh,...ee})},5182:function(ee,en,er){"use strict";var ei=er(6097);function eo(ee){var en={protocols:[],protocol:null,port:null,resource:"",host:"",user:"",password:"",pathname:"",hash:"",search:"",href:ee,query:{},parse_failed:!1};try{var er=new URL(ee);en.protocols=ei(er),en.protocol=en.protocols[0],en.port=er.port,en.resource=er.hostname,en.host=er.host,en.user=er.username||"",en.password=er.password||"",en.pathname=er.pathname,en.hash=er.hash.slice(1),en.search=er.search.slice(1),en.href=er.href,en.query=Object.fromEntries(er.searchParams)}catch(er){en.protocols=["file"],en.protocol=en.protocols[0],en.port="",en.resource="",en.user="",en.pathname="",en.hash="",en.search="",en.href=ee,en.query={},en.parse_failed=!0}return en}ee.exports=eo},8593:function(ee,en,er){"use strict";var ei=function(ee){return ee&&"object"==typeof ee&&"default"in ee?ee:{default:ee}}(er(5182));let eo="text/plain",es="us-ascii",eu=(ee,en)=>en.some(en=>en instanceof RegExp?en.test(ee):en===ee),ec=(ee,{stripHash:en})=>{let er=/^data:(?[^,]*?),(?[^#]*?)(?:#(?.*))?$/.exec(ee);if(!er)throw Error(`Invalid URL: ${ee}`);let{type:ei,data:eu,hash:ec}=er.groups,ed=ei.split(";");ec=en?"":ec;let ef=!1;"base64"===ed[ed.length-1]&&(ed.pop(),ef=!0);let eh=(ed.shift()||"").toLowerCase(),ep=ed.map(ee=>{let[en,er=""]=ee.split("=").map(ee=>ee.trim());return"charset"===en&&(er=er.toLowerCase())===es?"":`${en}${er?`=${er}`:""}`}).filter(Boolean),em=[...ep];return ef&&em.push("base64"),(em.length>0||eh&&eh!==eo)&&em.unshift(eh),`data:${em.join(";")},${ef?eu.trim():eu}${ec?`#${ec}`:""}`};function ed(ee,en){if(en={defaultProtocol:"http:",normalizeProtocol:!0,forceHttp:!1,forceHttps:!1,stripAuthentication:!0,stripHash:!1,stripTextFragment:!0,stripWWW:!0,removeQueryParameters:[/^utm_\w+/i],removeTrailingSlash:!0,removeSingleSlash:!0,removeDirectoryIndex:!1,sortQueryParameters:!0,...en},ee=ee.trim(),/^data:/i.test(ee))return ec(ee,en);if(/^view-source:/i.test(ee))throw Error("`view-source:` is not supported as it is a non-standard protocol");let er=ee.startsWith("//"),ei=!er&&/^\.*\//.test(ee);ei||(ee=ee.replace(/^(?!(?:\w+:)?\/\/)|^\/\//,en.defaultProtocol));let eo=new URL(ee);if(en.forceHttp&&en.forceHttps)throw Error("The `forceHttp` and `forceHttps` options cannot be used together");if(en.forceHttp&&"https:"===eo.protocol&&(eo.protocol="http:"),en.forceHttps&&"http:"===eo.protocol&&(eo.protocol="https:"),en.stripAuthentication&&(eo.username="",eo.password=""),en.stripHash?eo.hash="":en.stripTextFragment&&(eo.hash=eo.hash.replace(/#?:~:text.*?$/i,"")),eo.pathname){let ee=/\b[a-z][a-z\d+\-.]{1,50}:\/\//g,en=0,er="";for(;;){let ei=ee.exec(eo.pathname);if(!ei)break;let es=ei[0],eu=ei.index,ec=eo.pathname.slice(en,eu);er+=ec.replace(/\/{2,}/g,"/")+es,en=eu+es.length}let ei=eo.pathname.slice(en,eo.pathname.length);er+=ei.replace(/\/{2,}/g,"/"),eo.pathname=er}if(eo.pathname)try{eo.pathname=decodeURI(eo.pathname)}catch{}if(!0===en.removeDirectoryIndex&&(en.removeDirectoryIndex=[/^index\.[a-z]+$/]),Array.isArray(en.removeDirectoryIndex)&&en.removeDirectoryIndex.length>0){let ee=eo.pathname.split("/"),er=ee[ee.length-1];eu(er,en.removeDirectoryIndex)&&(ee=ee.slice(0,-1),eo.pathname=ee.slice(1).join("/")+"/")}if(eo.hostname&&(eo.hostname=eo.hostname.replace(/\.$/,""),en.stripWWW&&/^www\.(?!www\.)[a-z\-\d]{1,63}\.[a-z.\-\d]{2,63}$/.test(eo.hostname)&&(eo.hostname=eo.hostname.replace(/^www\./,""))),Array.isArray(en.removeQueryParameters))for(let ee of[...eo.searchParams.keys()])eu(ee,en.removeQueryParameters)&&eo.searchParams.delete(ee);if(!0===en.removeQueryParameters&&(eo.search=""),en.sortQueryParameters){eo.searchParams.sort();try{eo.search=decodeURIComponent(eo.search)}catch{}}en.removeTrailingSlash&&(eo.pathname=eo.pathname.replace(/\/$/,""));let es=ee;return ee=eo.toString(),en.removeSingleSlash||"/"!==eo.pathname||es.endsWith("/")||""!==eo.hash||(ee=ee.replace(/\/$/,"")),(en.removeTrailingSlash||"/"===eo.pathname)&&""===eo.hash&&en.removeSingleSlash&&(ee=ee.replace(/\/$/,"")),er&&!en.normalizeProtocol&&(ee=ee.replace(/^http:\/\//,"//")),en.stripProtocol&&(ee=ee.replace(/^(?:https?:)?\/\//,"")),ee}let ef=(ee,en=!1)=>{let er=/^(?:([a-z_][a-z0-9_-]{0,31})@|https?:\/\/)([\w\.\-@]+)[\/:]([\~,\.\w,\-,\_,\/]+?(?:\.git|\/)?)$/,eo=en=>{let er=Error(en);throw er.subject_url=ee,er};"string"==typeof ee&&ee.trim()||eo("Invalid url."),ee.length>ef.MAX_INPUT_LENGTH&&eo("Input exceeds maximum length. If needed, change the value of parseUrl.MAX_INPUT_LENGTH."),en&&("object"!=typeof en&&(en={stripHash:!1}),ee=ed(ee,en));let es=ei.default(ee);if(es.parse_failed){let ee=es.href.match(er);ee?(es.protocols=["ssh"],es.protocol="ssh",es.resource=ee[2],es.host=ee[2],es.user=ee[1],es.pathname=`/${ee[3]}`,es.parse_failed=!1):eo("URL parsing failed.")}return es};ef.MAX_INPUT_LENGTH=2048,ee.exports=ef},6097:function(ee){"use strict";ee.exports=function(ee,en){!0===en&&(en=0);var er="";if("string"==typeof ee)try{er=new URL(ee).protocol}catch(ee){}else ee&&ee.constructor===URL&&(er=ee.protocol);var ei=er.split(/\:|\+/).filter(Boolean);return"number"==typeof en?ei[en]:ei}},6593:function(ee){var en={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",Ấ:"A",Ắ:"A",Ẳ:"A",Ẵ:"A",Ặ:"A",Æ:"AE",Ầ:"A",Ằ:"A",Ȃ:"A",Ç:"C",Ḉ:"C",È:"E",É:"E",Ê:"E",Ë:"E",Ế:"E",Ḗ:"E",Ề:"E",Ḕ:"E",Ḝ:"E",Ȇ:"E",Ì:"I",Í:"I",Î:"I",Ï:"I",Ḯ:"I",Ȋ:"I",Ð:"D",Ñ:"N",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",Ố:"O",Ṍ:"O",Ṓ:"O",Ȏ:"O",Ù:"U",Ú:"U",Û:"U",Ü:"U",Ý:"Y",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",ấ:"a",ắ:"a",ẳ:"a",ẵ:"a",ặ:"a",æ:"ae",ầ:"a",ằ:"a",ȃ:"a",ç:"c",ḉ:"c",è:"e",é:"e",ê:"e",ë:"e",ế:"e",ḗ:"e",ề:"e",ḕ:"e",ḝ:"e",ȇ:"e",ì:"i",í:"i",î:"i",ï:"i",ḯ:"i",ȋ:"i",ð:"d",ñ:"n",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",ố:"o",ṍ:"o",ṓ:"o",ȏ:"o",ù:"u",ú:"u",û:"u",ü:"u",ý:"y",ÿ:"y",Ā:"A",ā:"a",Ă:"A",ă:"a",Ą:"A",ą:"a",Ć:"C",ć:"c",Ĉ:"C",ĉ:"c",Ċ:"C",ċ:"c",Č:"C",č:"c",C̆:"C",c̆:"c",Ď:"D",ď:"d",Đ:"D",đ:"d",Ē:"E",ē:"e",Ĕ:"E",ĕ:"e",Ė:"E",ė:"e",Ę:"E",ę:"e",Ě:"E",ě:"e",Ĝ:"G",Ǵ:"G",ĝ:"g",ǵ:"g",Ğ:"G",ğ:"g",Ġ:"G",ġ:"g",Ģ:"G",ģ:"g",Ĥ:"H",ĥ:"h",Ħ:"H",ħ:"h",Ḫ:"H",ḫ:"h",Ĩ:"I",ĩ:"i",Ī:"I",ī:"i",Ĭ:"I",ĭ:"i",Į:"I",į:"i",İ:"I",ı:"i",IJ:"IJ",ij:"ij",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",Ḱ:"K",ḱ:"k",K̆:"K",k̆:"k",Ĺ:"L",ĺ:"l",Ļ:"L",ļ:"l",Ľ:"L",ľ:"l",Ŀ:"L",ŀ:"l",Ł:"l",ł:"l",Ḿ:"M",ḿ:"m",M̆:"M",m̆:"m",Ń:"N",ń:"n",Ņ:"N",ņ:"n",Ň:"N",ň:"n",ʼn:"n",N̆:"N",n̆:"n",Ō:"O",ō:"o",Ŏ:"O",ŏ:"o",Ő:"O",ő:"o",Œ:"OE",œ:"oe",P̆:"P",p̆:"p",Ŕ:"R",ŕ:"r",Ŗ:"R",ŗ:"r",Ř:"R",ř:"r",R̆:"R",r̆:"r",Ȓ:"R",ȓ:"r",Ś:"S",ś:"s",Ŝ:"S",ŝ:"s",Ş:"S",Ș:"S",ș:"s",ş:"s",Š:"S",š:"s",Ţ:"T",ţ:"t",ț:"t",Ț:"T",Ť:"T",ť:"t",Ŧ:"T",ŧ:"t",T̆:"T",t̆:"t",Ũ:"U",ũ:"u",Ū:"U",ū:"u",Ŭ:"U",ŭ:"u",Ů:"U",ů:"u",Ű:"U",ű:"u",Ų:"U",ų:"u",Ȗ:"U",ȗ:"u",V̆:"V",v̆:"v",Ŵ:"W",ŵ:"w",Ẃ:"W",ẃ:"w",X̆:"X",x̆:"x",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Y̆:"Y",y̆:"y",Ź:"Z",ź:"z",Ż:"Z",ż:"z",Ž:"Z",ž:"z",ſ:"s",ƒ:"f",Ơ:"O",ơ:"o",Ư:"U",ư:"u",Ǎ:"A",ǎ:"a",Ǐ:"I",ǐ:"i",Ǒ:"O",ǒ:"o",Ǔ:"U",ǔ:"u",Ǖ:"U",ǖ:"u",Ǘ:"U",ǘ:"u",Ǚ:"U",ǚ:"u",Ǜ:"U",ǜ:"u",Ứ:"U",ứ:"u",Ṹ:"U",ṹ:"u",Ǻ:"A",ǻ:"a",Ǽ:"AE",ǽ:"ae",Ǿ:"O",ǿ:"o",Þ:"TH",þ:"th",Ṕ:"P",ṕ:"p",Ṥ:"S",ṥ:"s",X́:"X",x́:"x",Ѓ:"Г",ѓ:"г",Ќ:"К",ќ:"к",A̋:"A",a̋:"a",E̋:"E",e̋:"e",I̋:"I",i̋:"i",Ǹ:"N",ǹ:"n",Ồ:"O",ồ:"o",Ṑ:"O",ṑ:"o",Ừ:"U",ừ:"u",Ẁ:"W",ẁ:"w",Ỳ:"Y",ỳ:"y",Ȁ:"A",ȁ:"a",Ȅ:"E",ȅ:"e",Ȉ:"I",ȉ:"i",Ȍ:"O",ȍ:"o",Ȑ:"R",ȑ:"r",Ȕ:"U",ȕ:"u",B̌:"B",b̌:"b",Č̣:"C",č̣:"c",Ê̌:"E",ê̌:"e",F̌:"F",f̌:"f",Ǧ:"G",ǧ:"g",Ȟ:"H",ȟ:"h",J̌:"J",ǰ:"j",Ǩ:"K",ǩ:"k",M̌:"M",m̌:"m",P̌:"P",p̌:"p",Q̌:"Q",q̌:"q",Ř̩:"R",ř̩:"r",Ṧ:"S",ṧ:"s",V̌:"V",v̌:"v",W̌:"W",w̌:"w",X̌:"X",x̌:"x",Y̌:"Y",y̌:"y",A̧:"A",a̧:"a",B̧:"B",b̧:"b",Ḑ:"D",ḑ:"d",Ȩ:"E",ȩ:"e",Ɛ̧:"E",ɛ̧:"e",Ḩ:"H",ḩ:"h",I̧:"I",i̧:"i",Ɨ̧:"I",ɨ̧:"i",M̧:"M",m̧:"m",O̧:"O",o̧:"o",Q̧:"Q",q̧:"q",U̧:"U",u̧:"u",X̧:"X",x̧:"x",Z̧:"Z",z̧:"z"},er=Object.keys(en).join("|"),ei=RegExp(er,"g"),eo=RegExp(er,""),es=function(ee){return ee.replace(ei,function(ee){return en[ee]})},eu=function(ee){return!!ee.match(eo)};ee.exports=es,ee.exports.has=eu,ee.exports.remove=es},8246:function(ee,en,er){"use strict";er.d(en,{R:function(){return eo}});var ei,eo=((ei=eo||{}).Space=" ",ei.Enter="Enter",ei.Escape="Escape",ei.Backspace="Backspace",ei.Delete="Delete",ei.ArrowLeft="ArrowLeft",ei.ArrowUp="ArrowUp",ei.ArrowRight="ArrowRight",ei.ArrowDown="ArrowDown",ei.Home="Home",ei.End="End",ei.PageUp="PageUp",ei.PageDown="PageDown",ei.Tab="Tab",ei)},6510:function(ee,en,er){"use strict";er.d(en,{z:function(){return es}});var ei=er(959),eo=er(9691);let es=function(ee){let en=(0,eo.E)(ee);return ei.useCallback((...ee)=>en.current(...ee),[en])}},9038:function(ee,en,er){"use strict";er.d(en,{M:function(){return ed}});var ei,eo=er(959),es=er(6260),eu=er(674),ec=er(6030);let ed=null!=(ei=eo.useId)?ei:function(){let ee=(0,eu.H)(),[en,er]=eo.useState(ee?()=>ec.O.nextId():null);return(0,es.e)(()=>{null===en&&er(ec.O.nextId())},[en]),null!=en?""+en:void 0}},5782:function(ee,en,er){"use strict";er.d(en,{t:function(){return es}});var ei=er(959),eo=er(6260);function es(){let ee=(0,ei.useRef)(!1);return(0,eo.e)(()=>(ee.current=!0,()=>{ee.current=!1}),[]),ee}},6260:function(ee,en,er){"use strict";er.d(en,{e:function(){return es}});var ei=er(959),eo=er(6030);let es=(ee,en)=>{eo.O.isServer?(0,ei.useEffect)(ee,en):(0,ei.useLayoutEffect)(ee,en)}},9691:function(ee,en,er){"use strict";er.d(en,{E:function(){return es}});var ei=er(959),eo=er(6260);function es(ee){let en=(0,ei.useRef)(ee);return(0,eo.e)(()=>{en.current=ee},[ee]),en}},8002:function(ee,en,er){"use strict";er.d(en,{f:function(){return eu}});var ei=er(959),eo=er(6260);function es(ee){var en;if(ee.type)return ee.type;let er=null!=(en=ee.as)?en:"button";if("string"==typeof er&&"button"===er.toLowerCase())return"button"}function eu(ee,en){let[er,eu]=(0,ei.useState)(()=>es(ee));return(0,eo.e)(()=>{eu(es(ee))},[ee.type,ee.as]),(0,eo.e)(()=>{er||en.current&&en.current instanceof HTMLButtonElement&&!en.current.hasAttribute("type")&&eu("button")},[er,en]),er}},674:function(ee,en,er){"use strict";er.d(en,{H:function(){return ec}});var ei,eo=er(959),es=er(6030);function eu(){let ee="undefined"==typeof document;return(0,(ei||(ei=er.t(eo,2))).useSyncExternalStore)(()=>()=>{},()=>!1,()=>!ee)}function ec(){let ee=eu(),[en,er]=eo.useState(es.O.isHandoffComplete);return en&&!1===es.O.isHandoffComplete&&er(!1),eo.useEffect(()=>{!0!==en&&er(!0)},[en]),eo.useEffect(()=>es.O.handoff(),[]),!ee&&en}},9850:function(ee,en,er){"use strict";er.d(en,{T:function(){return eu}});var ei=er(959),eo=er(6510);let es=Symbol();function eu(...ee){let en=(0,ei.useRef)(ee);(0,ei.useEffect)(()=>{en.current=ee},[ee]);let er=(0,eo.z)(ee=>{for(let er of en.current)null!=er&&("function"==typeof er?er(ee):er.current=ee)});return ee.every(ee=>null==ee||(null==ee?void 0:ee[es]))?void 0:er}},1941:function(ee,en,er){"use strict";er.d(en,{A:function(){return eu},_:function(){return ed}});var ei,eo=er(222);let es="div";var eu=((ei=eu||{})[ei.None=1]="None",ei[ei.Focusable=2]="Focusable",ei[ei.Hidden=4]="Hidden",ei);function ec(ee,en){let{features:er=1,...ei}=ee,eu={ref:en,"aria-hidden":(2&er)==2||void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(4&er)==4&&(2&er)!=2&&{display:"none"}}};return(0,eo.sY)({ourProps:eu,theirProps:ei,slot:{},defaultTag:es,name:"Hidden"})}let ed=(0,eo.yV)(ec)},3659:function(ee,en,er){"use strict";function ei(...ee){return Array.from(new Set(ee.flatMap(ee=>"string"==typeof ee?ee.split(" "):[]))).filter(Boolean).join(" ")}er.d(en,{A:function(){return ei}})},5012:function(ee,en,er){"use strict";er.d(en,{k:function(){return eo}});var ei=er(1287);function eo(){let ee=[],en={addEventListener:(ee,er,ei,eo)=>(ee.addEventListener(er,ei,eo),en.add(()=>ee.removeEventListener(er,ei,eo))),requestAnimationFrame(...ee){let er=requestAnimationFrame(...ee);return en.add(()=>cancelAnimationFrame(er))},nextFrame:(...ee)=>en.requestAnimationFrame(()=>en.requestAnimationFrame(...ee)),setTimeout(...ee){let er=setTimeout(...ee);return en.add(()=>clearTimeout(er))},microTask(...ee){let er={current:!0};return(0,ei.Y)(()=>{er.current&&ee[0]()}),en.add(()=>{er.current=!1})},style(ee,en,er){let ei=ee.style.getPropertyValue(en);return Object.assign(ee.style,{[en]:er}),this.add(()=>{Object.assign(ee.style,{[en]:ei})})},group(ee){let en=eo();return ee(en),this.add(()=>en.dispose())},add:en=>(ee.push(en),()=>{let er=ee.indexOf(en);if(er>=0)for(let en of ee.splice(er,1))en()}),dispose(){for(let en of ee.splice(0))en()}};return en}},6030:function(ee,en,er){"use strict";er.d(en,{O:function(){return ec}});var ei=Object.defineProperty,eo=(ee,en,er)=>en in ee?ei(ee,en,{enumerable:!0,configurable:!0,writable:!0,value:er}):ee[en]=er,es=(ee,en,er)=>(eo(ee,"symbol"!=typeof en?en+"":en,er),er);class eu{constructor(){es(this,"current",this.detect()),es(this,"handoffState","pending"),es(this,"currentId",0)}set(ee){this.current!==ee&&(this.handoffState="pending",this.currentId=0,this.current=ee)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return"server"===this.current}get isClient(){return"client"===this.current}detect(){return"undefined"==typeof window||"undefined"==typeof document?"server":"client"}handoff(){"pending"===this.handoffState&&(this.handoffState="complete")}get isHandoffComplete(){return"complete"===this.handoffState}}let ec=new eu},7496:function(ee,en,er){"use strict";er.d(en,{EO:function(){return eS},TO:function(){return em},fE:function(){return ex},jA:function(){return eO},sP:function(){return eb},tJ:function(){return ey},wI:function(){return ek},z2:function(){return ej}});var ei,eo,es,eu,ec,ed=er(5012),ef=er(3011),eh=er(9195);let ep=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(ee=>`${ee}:not([tabindex='-1'])`).join(",");var em=((ei=em||{})[ei.First=1]="First",ei[ei.Previous=2]="Previous",ei[ei.Next=4]="Next",ei[ei.Last=8]="Last",ei[ei.WrapAround=16]="WrapAround",ei[ei.NoScroll=32]="NoScroll",ei),ex=((eo=ex||{})[eo.Error=0]="Error",eo[eo.Overflow=1]="Overflow",eo[eo.Success=2]="Success",eo[eo.Underflow=3]="Underflow",eo),eg=((es=eg||{})[es.Previous=-1]="Previous",es[es.Next=1]="Next",es);function ev(ee=document.body){return null==ee?[]:Array.from(ee.querySelectorAll(ep)).sort((ee,en)=>Math.sign((ee.tabIndex||Number.MAX_SAFE_INTEGER)-(en.tabIndex||Number.MAX_SAFE_INTEGER)))}var ey=((eu=ey||{})[eu.Strict=0]="Strict",eu[eu.Loose=1]="Loose",eu);function eb(ee,en=0){var er;return ee!==(null==(er=(0,eh.r)(ee))?void 0:er.body)&&(0,ef.E)(en,{0:()=>ee.matches(ep),1(){let en=ee;for(;null!==en;){if(en.matches(ep))return!0;en=en.parentElement}return!1}})}function ek(ee){let en=(0,eh.r)(ee);(0,ed.k)().nextFrame(()=>{en&&!eb(en.activeElement,0)&&e_(ee)})}var ew=((ec=ew||{})[ec.Keyboard=0]="Keyboard",ec[ec.Mouse=1]="Mouse",ec);function e_(ee){null==ee||ee.focus({preventScroll:!0})}"undefined"!=typeof window&&"undefined"!=typeof document&&(document.addEventListener("keydown",ee=>{ee.metaKey||ee.altKey||ee.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",ee=>{1===ee.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===ee.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));let eC="textarea,input";function eE(ee){var en,er;return null!=(er=null==(en=null==ee?void 0:ee.matches)?void 0:en.call(ee,eC))&&er}function ej(ee,en=ee=>ee){return ee.slice().sort((ee,er)=>{let ei=en(ee),eo=en(er);if(null===ei||null===eo)return 0;let es=ei.compareDocumentPosition(eo);return es&Node.DOCUMENT_POSITION_FOLLOWING?-1:es&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function eS(ee,en){return eO(ev(),en,{relativeTo:ee})}function eO(ee,en,{sorted:er=!0,relativeTo:ei=null,skipElements:eo=[]}={}){let es=Array.isArray(ee)?ee.length>0?ee[0].ownerDocument:document:ee.ownerDocument,eu=Array.isArray(ee)?er?ej(ee):ee:ev(ee);eo.length>0&&eu.length>1&&(eu=eu.filter(ee=>!eo.includes(ee))),ei=null!=ei?ei:es.activeElement;let ec=(()=>{if(5&en)return 1;if(10&en)return -1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),ed=(()=>{if(1&en)return 0;if(2&en)return Math.max(0,eu.indexOf(ei))-1;if(4&en)return Math.max(0,eu.indexOf(ei))+1;if(8&en)return eu.length-1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),ef=32&en?{preventScroll:!0}:{},eh=0,ep=eu.length,em;do{if(eh>=ep||eh+ep<=0)return 0;let ee=ed+eh;if(16&en)ee=(ee+ep)%ep;else{if(ee<0)return 3;if(ee>=ep)return 1}null==(em=eu[ee])||em.focus(ef),eh+=ec}while(em!==es.activeElement);return 6&en&&eE(em)&&em.select(),2}},3011:function(ee,en,er){"use strict";function ei(ee,en,...er){if(ee in en){let ei=en[ee];return"function"==typeof ei?ei(...er):ei}let eo=Error(`Tried to handle "${ee}" but there is no handler defined. Only defined handlers are: ${Object.keys(en).map(ee=>`"${ee}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(eo,ei),eo}er.d(en,{E:function(){return ei}})},1287:function(ee,en,er){"use strict";function ei(ee){"function"==typeof queueMicrotask?queueMicrotask(ee):Promise.resolve().then(ee).catch(ee=>setTimeout(()=>{throw ee}))}er.d(en,{Y:function(){return ei}})},9195:function(ee,en,er){"use strict";er.d(en,{r:function(){return eo}});var ei=er(6030);function eo(ee){return ei.O.isServer?null:ee instanceof Node?ee.ownerDocument:null!=ee&&ee.hasOwnProperty("current")&&ee.current instanceof Node?ee.current.ownerDocument:document}},222:function(ee,en,er){"use strict";er.d(en,{AN:function(){return ed},l4:function(){return ef},oA:function(){return ev},sY:function(){return eh},yV:function(){return eg}});var ei,eo,es=er(959),eu=er(3659),ec=er(3011),ed=((ei=ed||{})[ei.None=0]="None",ei[ei.RenderStrategy=1]="RenderStrategy",ei[ei.Static=2]="Static",ei),ef=((eo=ef||{})[eo.Unmount=0]="Unmount",eo[eo.Hidden=1]="Hidden",eo);function eh({ourProps:ee,theirProps:en,slot:er,defaultTag:ei,features:eo,visible:es=!0,name:eu}){let ed=ex(en,ee);if(es)return ep(ed,er,ei,eu);let ef=null!=eo?eo:0;if(2&ef){let{static:ee=!1,...en}=ed;if(ee)return ep(en,er,ei,eu)}if(1&ef){let{unmount:ee=!0,...en}=ed;return(0,ec.E)(ee?0:1,{0:()=>null,1:()=>ep({...en,hidden:!0,style:{display:"none"}},er,ei,eu)})}return ep(ed,er,ei,eu)}function ep(ee,en={},er,ei){let{as:eo=er,children:ec,refName:ed="ref",...ef}=ey(ee,["unmount","static"]),eh=void 0!==ee.ref?{[ed]:ee.ref}:{},ep="function"==typeof ec?ec(en):ec;"className"in ef&&ef.className&&"function"==typeof ef.className&&(ef.className=ef.className(en));let eg={};if(en){let ee=!1,er=[];for(let[ei,eo]of Object.entries(en))"boolean"==typeof eo&&(ee=!0),!0===eo&&er.push(ei);ee&&(eg["data-headlessui-state"]=er.join(" "))}if(eo===es.Fragment&&Object.keys(ev(ef)).length>0){if(!(0,es.isValidElement)(ep)||Array.isArray(ep)&&ep.length>1)throw Error(['Passing props on "Fragment"!',"",`The current component <${ei} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(ef).map(ee=>` - ${ee}`).join(` `),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map(ee=>` - ${ee}`).join(` `)].join(` `));let ee=ep.props,en="function"==typeof(null==ee?void 0:ee.className)?(...en)=>(0,eu.A)(null==ee?void 0:ee.className(...en),ef.className):(0,eu.A)(null==ee?void 0:ee.className,ef.className),er=en?{className:en}:{};return(0,es.cloneElement)(ep,Object.assign({},ex(ep.props,ev(ey(ef,["ref"]))),eg,eh,em(ep.ref,eh.ref),er))}return(0,es.createElement)(eo,Object.assign({},ey(ef,["ref"]),eo!==es.Fragment&&eh,eo!==es.Fragment&&eg),ep)}function em(...ee){return{ref:ee.every(ee=>null==ee)?void 0:en=>{for(let er of ee)null!=er&&("function"==typeof er?er(en):er.current=en)}}}function ex(...ee){var en;if(0===ee.length)return{};if(1===ee.length)return ee[0];let er={},ei={};for(let eo of ee)for(let ee in eo)ee.startsWith("on")&&"function"==typeof eo[ee]?(null!=(en=ei[ee])||(ei[ee]=[]),ei[ee].push(eo[ee])):er[ee]=eo[ee];if(er.disabled||er["aria-disabled"])return Object.assign(er,Object.fromEntries(Object.keys(ei).map(ee=>[ee,void 0])));for(let ee in ei)Object.assign(er,{[ee](en,...er){for(let eo of ei[ee]){if((en instanceof Event||(null==en?void 0:en.nativeEvent)instanceof Event)&&en.defaultPrevented)return;eo(en,...er)}}});return er}function eg(ee){var en;return Object.assign((0,es.forwardRef)(ee),{displayName:null!=(en=ee.displayName)?en:ee.name})}function ev(ee){let en=Object.assign({},ee);for(let ee in en)void 0===en[ee]&&delete en[ee];return en}function ey(ee,en=[]){let er=Object.assign({},ee);for(let ee of en)ee in er&&delete er[ee];return er}},5341:function(ee,en,er){"use strict";function ei(ee){var en,er,eo="";if("string"==typeof ee||"number"==typeof ee)eo+=ee;else if("object"==typeof ee){if(Array.isArray(ee))for(en=0;ent in e?c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,x=(e,t)=>{for(var r in t||(t={}))h.call(t,r)&&p(e,r,t[r]);if(l)for(var r of l(t))u.call(t,r)&&p(e,r,t[r]);return e},j=(e,t)=>a(e,d(t)),f=(e,t)=>{var r={};for(var s in e)h.call(e,s)&&0>t.indexOf(s)&&(r[s]=e[s]);if(null!=e&&l)for(var s of l(e))0>t.indexOf(s)&&u.call(e,s)&&(r[s]=e[s]);return r},m=(e,t,r)=>{let n=(0,s.forwardRef)((t,n)=>{var{color:o="currentColor",size:c=24,stroke:a=2,children:d}=t,l=f(t,["color","size","stroke","children"]);return(0,s.createElement)("svg",x(j(x({ref:n},i),{width:c,height:c,stroke:o,strokeWidth:a,className:`tabler-icon tabler-icon-${e}`}),l),[...r.map(([e,t])=>(0,s.createElement)(e,t)),...d||[]])});return n.propTypes={color:o().string,size:o().oneOfType([o().string,o().number]),stroke:o().oneOfType([o().string,o().number])},n.displayName=`${t}`,n}},3630:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/",function(){return r(244)}])},244:function(e,t,r){"use strict";r.r(t),r.d(t,{__toc:function(){return a},default:function(){return l}});var s=r(1527),n=r(2059),o=r(3443),i=(0,r(1047).Z)("coffee","IconCoffee",[["path",{d:"M3 14c.83 .642 2.077 1.017 3.5 1c1.423 .017 2.67 -.358 3.5 -1c.83 -.642 2.077 -1.017 3.5 -1c1.423 -.017 2.67 .358 3.5 1",key:"svg-0"}],["path",{d:"M8 3a2.4 2.4 0 0 0 -1 2a2.4 2.4 0 0 0 1 2",key:"svg-1"}],["path",{d:"M12 3a2.4 2.4 0 0 0 -1 2a2.4 2.4 0 0 0 1 2",key:"svg-2"}],["path",{d:"M3 10h14v5a6 6 0 0 1 -6 6h-2a6 6 0 0 1 -6 -6v-5z",key:"svg-3"}],["path",{d:"M16.746 16.726a3 3 0 1 0 .252 -5.555",key:"svg-4"}]]),c=e=>{let{image:t,name:r,kofiName:n}=e;return(0,s.jsxs)("div",{className:"flex w-32 flex-col items-center justify-center gap-2",children:[(0,s.jsx)("p",{children:r}),(0,s.jsx)("img",{src:t,alt:"".concat(r,"-image"),className:"rounded-md bg-neutral-100 shadow-md dark:bg-neutral-900"}),(0,s.jsx)("a",{href:"https://ko-fi.com/".concat(n),target:"_blank",className:"w-full",children:(0,s.jsxs)("button",{className:"flex w-full items-center justify-center gap-2 rounded-md bg-sky-500/20 p-2 text-sky-500 hover:bg-sky-500/30",children:[(0,s.jsx)(i,{}),"Support"]})})]})};let a=[{depth:2,value:"Support our team",id:"support-our-team"},{depth:2,value:"Creator codes",id:"creator-codes"}];function d(e){let t=Object.assign({h1:"h1",p:"p",h2:"h2",br:"br",ul:"ul",li:"li",table:"table",thead:"thead",tr:"tr",th:"th",tbody:"tbody",td:"td",a:"a"},(0,o.a)(),e.components);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(t.h1,{children:"Introduction"}),"\n",(0,s.jsx)(t.p,{children:"Here you can find all of the official documentation for resources developed by the Overextended team."}),"\n",(0,s.jsx)(t.p,{children:'If you feel like the documentation is lacking in some department then feel free to go onto that page and click the "Edit this page" at the bottom and submit a Pull Request.'}),"\n",(0,s.jsx)(t.h2,{id:"support-our-team",children:"Support our team"}),"\n",(0,s.jsxs)(t.p,{children:["Our projects will always remain free and open-source, with our core developers working voluntarily.",(0,s.jsx)(t.br,{}),"\n","If you love what we do and want to help us continue, why not show your appreciation with a donation?"]}),"\n",(0,s.jsxs)("div",{className:"mt-2 flex flex-wrap justify-evenly gap-4",children:[(0,s.jsx)(c,{image:"https://avatars.githubusercontent.com/u/65407488?v=4",name:"Linden",kofiName:"thelindat"}),(0,s.jsx)(c,{image:"https://avatars.githubusercontent.com/u/39926192?v=4",name:"Luke",kofiName:"lukewastaken"}),(0,s.jsx)(c,{image:"https://avatars.githubusercontent.com/u/31368547?v=4",name:"DokaDoka",kofiName:"dokadoka"})]}),"\n",(0,s.jsx)(t.h2,{id:"creator-codes",children:"Creator codes"}),"\n",(0,s.jsx)(t.p,{children:"Creator codes allow Tebex stores to share a percentage of a purchase with us, while giving a discount to the customer. We make these deals to advertise trusted creators who meet our criteria."}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:"Resources are highly configurable or, preferably, source-available."}),"\n",(0,s.jsx)(t.li,{children:"We trust that customers will be given assistance."}),"\n",(0,s.jsx)(t.li,{children:"The creator is a known member of our community."}),"\n"]}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Store"}),(0,s.jsx)(t.th,{children:"Code"}),(0,s.jsx)(t.th,{children:"Discount"}),(0,s.jsx)(t.th,{children:"Link"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Andyyy"}),(0,s.jsx)(t.td,{children:"ox20"}),(0,s.jsx)(t.td,{children:"20%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://andyyy.tebex.io/",children:"https://andyyy.tebex.io/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Berkie's Workshop"}),(0,s.jsx)(t.td,{children:"ox10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://berkie.tebex.io/",children:"https://berkie.tebex.io/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Dolu Mods"}),(0,s.jsx)(t.td,{children:"overextended"}),(0,s.jsx)(t.td,{children:"15%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://dolu.tebex.io/",children:"https://dolu.tebex.io/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Electus Scripts"}),(0,s.jsx)(t.td,{children:"ox10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.electus-scripts.com/",children:"https://store.electus-scripts.com/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Loaf Scripts"}),(0,s.jsx)(t.td,{children:"ox5"}),(0,s.jsx)(t.td,{children:"5%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.loaf-scripts.com/",children:"https://store.loaf-scripts.com/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"OT Studios"}),(0,s.jsx)(t.td,{children:"ox10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.otstudios.net/ox",children:"https://store.otstudios.net/ox"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"rcore"}),(0,s.jsx)(t.td,{children:"0x10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.rcore.cz/",children:"https://store.rcore.cz/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Wasabi Scripts"}),(0,s.jsx)(t.td,{children:"OX20"}),(0,s.jsx)(t.td,{children:"20%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.wasabiscripts.com/",children:"https://store.wasabiscripts.com/"})})]})]})]}),"\n",(0,s.jsx)(t.p,{children:'You can apply a creator code at checkout under "Support A Creator".'})]})}var l=(0,n.j)({MDXContent:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:t}=Object.assign({},(0,o.a)(),e.components);return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(d,{...e})}):d(e)},pageOpts:{filePath:"pages/index.mdx",route:"/",frontMatter:{title:"Introduction"},title:"Introduction",headings:a},pageNextRoute:"/"})},4049:function(e,t,r){"use strict";var s=r(6257);function n(){}function o(){}o.resetWarningCache=n,e.exports=function(){function e(e,t,r,n,o,i){if(i!==s){var c=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}function t(){return e}e.isRequired=e;var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:n};return r.PropTypes=r,r}},507:function(e,t,r){e.exports=r(4049)()},6257:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}},function(e){e.O(0,[2059,9774,2888,179],function(){return e(e.s=3630)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/pages/index-4039efa6125bbe0e.js b/_next/static/chunks/pages/index-4039efa6125bbe0e.js new file mode 100644 index 0000000000..54594a295d --- /dev/null +++ b/_next/static/chunks/pages/index-4039efa6125bbe0e.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5405],{1047:function(e,t,r){"use strict";r.d(t,{Z:function(){return m}});var s=r(959),n=r(507),o=r.n(n),i={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"},c=Object.defineProperty,d=Object.defineProperties,a=Object.getOwnPropertyDescriptors,l=Object.getOwnPropertySymbols,h=Object.prototype.hasOwnProperty,p=Object.prototype.propertyIsEnumerable,x=(e,t,r)=>t in e?c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,u=(e,t)=>{for(var r in t||(t={}))h.call(t,r)&&x(e,r,t[r]);if(l)for(var r of l(t))p.call(t,r)&&x(e,r,t[r]);return e},j=(e,t)=>d(e,a(t)),f=(e,t)=>{var r={};for(var s in e)h.call(e,s)&&0>t.indexOf(s)&&(r[s]=e[s]);if(null!=e&&l)for(var s of l(e))0>t.indexOf(s)&&p.call(e,s)&&(r[s]=e[s]);return r},m=(e,t,r)=>{let n=(0,s.forwardRef)((t,n)=>{var{color:o="currentColor",size:c=24,stroke:d=2,children:a}=t,l=f(t,["color","size","stroke","children"]);return(0,s.createElement)("svg",u(j(u({ref:n},i),{width:c,height:c,stroke:o,strokeWidth:d,className:`tabler-icon tabler-icon-${e}`}),l),[...r.map(([e,t])=>(0,s.createElement)(e,t)),...a||[]])});return n.propTypes={color:o().string,size:o().oneOfType([o().string,o().number]),stroke:o().oneOfType([o().string,o().number])},n.displayName=`${t}`,n}},3630:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/",function(){return r(244)}])},244:function(e,t,r){"use strict";r.r(t),r.d(t,{__toc:function(){return d},default:function(){return l}});var s=r(1527),n=r(2059),o=r(3443),i=(0,r(1047).Z)("coffee","IconCoffee",[["path",{d:"M3 14c.83 .642 2.077 1.017 3.5 1c1.423 .017 2.67 -.358 3.5 -1c.83 -.642 2.077 -1.017 3.5 -1c1.423 -.017 2.67 .358 3.5 1",key:"svg-0"}],["path",{d:"M8 3a2.4 2.4 0 0 0 -1 2a2.4 2.4 0 0 0 1 2",key:"svg-1"}],["path",{d:"M12 3a2.4 2.4 0 0 0 -1 2a2.4 2.4 0 0 0 1 2",key:"svg-2"}],["path",{d:"M3 10h14v5a6 6 0 0 1 -6 6h-2a6 6 0 0 1 -6 -6v-5z",key:"svg-3"}],["path",{d:"M16.746 16.726a3 3 0 1 0 .252 -5.555",key:"svg-4"}]]),c=e=>{let{image:t,name:r,kofiName:n}=e;return(0,s.jsxs)("div",{className:"flex w-32 flex-col items-center justify-center gap-2",children:[(0,s.jsx)("p",{children:r}),(0,s.jsx)("img",{src:t,alt:"".concat(r,"-image"),className:"rounded-md bg-neutral-100 shadow-md dark:bg-neutral-900"}),(0,s.jsx)("a",{href:"https://ko-fi.com/".concat(n),target:"_blank",className:"w-full",children:(0,s.jsxs)("button",{className:"flex w-full items-center justify-center gap-2 rounded-md bg-sky-500/20 p-2 text-sky-500 hover:bg-sky-500/30",children:[(0,s.jsx)(i,{}),"Support"]})})]})};let d=[{depth:2,value:"Support our team",id:"support-our-team"},{depth:2,value:"Creator codes",id:"creator-codes"}];function a(e){let t=Object.assign({h1:"h1",p:"p",h2:"h2",br:"br",ul:"ul",li:"li",a:"a",table:"table",thead:"thead",tr:"tr",th:"th",tbody:"tbody",td:"td"},(0,o.a)(),e.components);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(t.h1,{children:"Introduction"}),"\n",(0,s.jsx)(t.p,{children:"Here you can find all of the official documentation for resources developed by the Overextended team."}),"\n",(0,s.jsx)(t.p,{children:'If you feel like the documentation is lacking in some department then feel free to go onto that page and click the "Edit this page" at the bottom and submit a Pull Request.'}),"\n",(0,s.jsx)(t.h2,{id:"support-our-team",children:"Support our team"}),"\n",(0,s.jsxs)(t.p,{children:["Our projects will always remain free and open-source, with our core developers working voluntarily.",(0,s.jsx)(t.br,{}),"\n","If you love what we do and want to help us continue, why not show your appreciation with a donation?"]}),"\n",(0,s.jsxs)("div",{className:"mt-2 flex flex-wrap justify-evenly gap-4",children:[(0,s.jsx)(c,{image:"https://avatars.githubusercontent.com/u/65407488?v=4",name:"Linden",kofiName:"thelindat"}),(0,s.jsx)(c,{image:"https://avatars.githubusercontent.com/u/39926192?v=4",name:"Luke",kofiName:"lukewastaken"}),(0,s.jsx)(c,{image:"https://avatars.githubusercontent.com/u/31368547?v=4",name:"DokaDoka",kofiName:"dokadoka"})]}),"\n",(0,s.jsx)(t.h2,{id:"creator-codes",children:"Creator codes"}),"\n",(0,s.jsx)(t.p,{children:"Creator codes allow Tebex stores to share a percentage of a purchase with us, while giving a discount to the customer. We make these deals to advertise trusted creators who meet our criteria."}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:"Resources are highly configurable or, preferably, source-available."}),"\n",(0,s.jsx)(t.li,{children:"We trust that customers will be given assistance."}),"\n",(0,s.jsx)(t.li,{children:"The creator is a known member of our community."}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["More information about these creators is available in our ",(0,s.jsx)(t.a,{href:"https://discord.com/channels/813030955598086174/1028912864389496903",children:"Discord"}),"."]}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Store"}),(0,s.jsx)(t.th,{children:"Code"}),(0,s.jsx)(t.th,{children:"Discount"}),(0,s.jsx)(t.th,{children:"Link"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Andyyy"}),(0,s.jsx)(t.td,{children:"ox20"}),(0,s.jsx)(t.td,{children:"20%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://andyyy.tebex.io/",children:"https://andyyy.tebex.io/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Berkie's Workshop"}),(0,s.jsx)(t.td,{children:"ox10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://berkie.tebex.io/",children:"https://berkie.tebex.io/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Dolu Mods"}),(0,s.jsx)(t.td,{children:"overextended"}),(0,s.jsx)(t.td,{children:"15%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://dolu.tebex.io/",children:"https://dolu.tebex.io/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Electus Scripts"}),(0,s.jsx)(t.td,{children:"ox10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.electus-scripts.com/",children:"https://store.electus-scripts.com/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Loaf Scripts"}),(0,s.jsx)(t.td,{children:"ox5"}),(0,s.jsx)(t.td,{children:"5%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.loaf-scripts.com/",children:"https://store.loaf-scripts.com/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"OT Studios"}),(0,s.jsx)(t.td,{children:"ox10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.otstudios.net/ox",children:"https://store.otstudios.net/ox"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Pickle Mods"}),(0,s.jsx)(t.td,{children:"ox30"}),(0,s.jsx)(t.td,{children:"30%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.picklemods.com/",children:"https://store.picklemods.com/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"rcore"}),(0,s.jsx)(t.td,{children:"ox10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.rcore.cz/",children:"https://store.rcore.cz/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Roleplay inventory icons"}),(0,s.jsx)(t.td,{children:"ox10"}),(0,s.jsx)(t.td,{children:"10%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://pixel-art-roleplay-inventory-i.tebex.io/",children:"https://pixel-art-roleplay-inventory-i.tebex.io/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Renewed Scripts"}),(0,s.jsx)(t.td,{children:"ox15"}),(0,s.jsx)(t.td,{children:"15%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://renewed.tebex.io/",children:"https://renewed.tebex.io/"})})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Wasabi Scripts"}),(0,s.jsx)(t.td,{children:"OX20"}),(0,s.jsx)(t.td,{children:"20%"}),(0,s.jsx)(t.td,{children:(0,s.jsx)(t.a,{href:"https://store.wasabiscripts.com/",children:"https://store.wasabiscripts.com/"})})]})]})]}),"\n",(0,s.jsx)(t.p,{children:'You can apply a creator code at checkout under "Support A Creator".'})]})}var l=(0,n.j)({MDXContent:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:t}=Object.assign({},(0,o.a)(),e.components);return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(a,{...e})}):a(e)},pageOpts:{filePath:"pages/index.mdx",route:"/",frontMatter:{title:"Introduction"},title:"Introduction",headings:d},pageNextRoute:"/"})},4049:function(e,t,r){"use strict";var s=r(6257);function n(){}function o(){}o.resetWarningCache=n,e.exports=function(){function e(e,t,r,n,o,i){if(i!==s){var c=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}function t(){return e}e.isRequired=e;var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:n};return r.PropTypes=r,r}},507:function(e,t,r){e.exports=r(4049)()},6257:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}},function(e){e.O(0,[2059,9774,2888,179],function(){return e(e.s=3630)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/pages/ox_inventory/Functions/Server-819101f5cf3f2301.js b/_next/static/chunks/pages/ox_inventory/Functions/Server-819101f5cf3f2301.js deleted file mode 100644 index 303df51189..0000000000 --- a/_next/static/chunks/pages/ox_inventory/Functions/Server-819101f5cf3f2301.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5789],{5929:function(e,s,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/ox_inventory/Functions/Server",function(){return n(5830)}])},5830:function(e,s,n){"use strict";n.r(s),n.d(s,{__toc:function(){return o}});var l=n(1527),r=n(2059),i=n(3443),t=n(8242);let o=[{depth:2,value:"setPlayerInventory",id:"setplayerinventory"},{depth:2,value:"forceOpenInventory",id:"forceopeninventory"},{depth:2,value:"UpdateVehicle",id:"updatevehicle"},{depth:2,value:"Items",id:"items"},{depth:2,value:"AddItem",id:"additem"},{depth:2,value:"RemoveItem",id:"removeitem"},{depth:2,value:"GetItem",id:"getitem"},{depth:2,value:"ConvertItems",id:"convertitems"},{depth:2,value:"CanCarryItem",id:"cancarryitem"},{depth:2,value:"CanCarryAmount",id:"cancarryamount"},{depth:2,value:"CanCarryWeight",id:"cancarryweight"},{depth:2,value:"SetMaxWeight",id:"setmaxweight"},{depth:2,value:"CanSwapItem",id:"canswapitem"},{depth:2,value:"GetItemCount",id:"getitemcount"},{depth:2,value:"GetItemSlots",id:"getitemslots"},{depth:2,value:"GetSlot",id:"getslot"},{depth:2,value:"GetSlotForItem",id:"getslotforitem"},{depth:2,value:"GetSlotIdWithItem",id:"getslotidwithitem"},{depth:2,value:"GetSlotIdsWithItem",id:"getslotidswithitem"},{depth:2,value:"GetSlotWithItem",id:"getslotwithitem"},{depth:2,value:"GetSlotsWithItem",id:"getslotswithitem"},{depth:2,value:"GetEmptySlot",id:"getemptyslot"},{depth:2,value:"GetContainerFromSlot",id:"getcontainerfromslot"},{depth:2,value:"SetSlotCount",id:"setslotcount"},{depth:2,value:"GetInventory",id:"getinventory"},{depth:2,value:"GetInventoryItems",id:"getinventoryitems"},{depth:2,value:"ConfiscateInventory",id:"confiscateinventory"},{depth:2,value:"ReturnInventory",id:"returninventory"},{depth:2,value:"ClearInventory",id:"clearinventory"},{depth:2,value:"Search",id:"search"},{depth:2,value:"SwapSlots",id:"swapslots"},{depth:2,value:"RegisterStash",id:"registerstash"},{depth:2,value:"CreateTemporaryStash",id:"createtemporarystash"},{depth:2,value:"CustomDrop",id:"customdrop"},{depth:2,value:"CreateDropFromPlayer",id:"createdropfromplayer"},{depth:2,value:"GetCurrentWeapon",id:"getcurrentweapon"},{depth:2,value:"SetDurability",id:"setdurability"},{depth:2,value:"SetMetadata",id:"setmetadata"}];function a(e){let s=Object.assign({h1:"h1",h2:"h2",p:"p",pre:"pre",code:"code",span:"span",ul:"ul",li:"li",a:"a",strong:"strong",em:"em"},(0,i.a)(),e.components);return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(s.h1,{children:"Server"}),"\n",(0,l.jsx)(s.h2,{id:"setplayerinventory",children:"setPlayerInventory"}),"\n",(0,l.jsx)(s.p,{children:"Creates and sets the player's inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"setPlayerInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(player, data)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["player: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["source: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["identifier: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["name: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["groups?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["sex?: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["dateofbirth?: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["data?: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"If not provided will load player's inventory data from the db."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"forceopeninventory",children:"forceOpenInventory"}),"\n",(0,l.jsx)(s.p,{children:"Opens an inventory using the passed data.\nForces a player to open an inventory, without usual security checks (groups, coords)."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(playerId, invType, data)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["invType: ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'player'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'stash'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'container'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'drop'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'glovebox'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'trunk'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'dumpster'"})}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["data: ",(0,l.jsx)(s.code,{children:"number"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n",(0,l.jsxs)(t.mQ,{items:["Player","Stash"],children:[(0,l.jsxs)(t.OK,{children:[(0,l.jsx)(s.p,{children:"Open the target player's inventory."}),(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'player'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})})}),(0,l.jsx)(s.p,{children:"Admin command to open a player's inventory."}),(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RegisterCommand"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'openplayerinv'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-parameter)"},children:"source"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-parameter)"},children:"args"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'player'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"tonumber"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(args["}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"]))"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})})]}),(0,l.jsxs)(t.OK,{children:[(0,l.jsx)(s.p,{children:"Open a custom stash (created on the server with RegisterStash)."}),(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'society_police'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})})}),(0,l.jsx)(s.p,{children:"Open a stash with a specific owner."}),(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", { id "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_locker'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", owner "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'license:xxxxxxxx' "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"})"})]})})})]})]}),"\n",(0,l.jsx)(s.h2,{id:"updatevehicle",children:"UpdateVehicle"}),"\n",(0,l.jsx)(s.p,{children:"Update the internal reference to vehicle stashes, without triggering a save or updating the database."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"UpdateVehicle"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(oldPlate, newPlate)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["oldPlate: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["newPlate: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"items",children:"Items"}),"\n",(0,l.jsxs)(s.p,{children:["Returns a table of all registered items. The format is as defined in ",(0,l.jsx)(s.a,{href:"https://github.com/overextended/ox_inventory/blob/main/data/items.lua",children:"data/items.lua"}),"."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"Items"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]})})}),"\n",(0,l.jsx)(s.p,{children:"The following snippet can be used in crafting resources such as okokCrafting or core_crafting, rather than querying the database."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" itemNames"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ESX."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RegisterServerCallback"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'crafting:itemNames'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-parameter)"},children:"source"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-parameter)"},children:"cb"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"not"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" itemNames "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" itemNames "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {}"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"for"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" item, data "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"in"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"pairs"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"Items"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"()) "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"do"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" itemNames[item] "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" data.label"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"cb"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(itemNames)"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"additem",children:"AddItem"}),"\n",(0,l.jsx)(s.p,{children:"Adds an item into the specified inventory."}),"\n",(0,l.jsxs)(s.p,{children:["Should be used alongside ",(0,l.jsx)(s.a,{href:"#cancarryitem",children:"CanCarryItem"})," otherwise, the maximum weight may be exceeded."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"AddItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, count, metadata, slot, cb)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["The inventory's unique id, or a table with the id and owner.","\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"1"})]}),"\n",(0,l.jsxs)(s.li,{children:["inventoryId: ",(0,l.jsx)(s.code,{children:"gloveVGH283"})]}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"{ id = 'personallocker', owner = 'license:xxxxxx'}"})}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"The name of the item to add to the target."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["count: ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"The number of items to add."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:'A table of unique data to attach to the item object. A string will create a table with the "type" field.'}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["slot?: ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"A specific slot to add the item to. If the slot is invalid, the first available slot will be used instead."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["cb?: function(success: ",(0,l.jsx)(s.code,{children:"boolean"}),", response?: ",(0,l.jsx)(s.code,{children:"string"}),")"]}),"\n"]}),"\n",(0,l.jsxs)(s.p,{children:["If used for glovebox, trunk or stash you must first check the inventory is loaded with ",(0,l.jsx)(s.a,{href:"./GetInventory",children:"GetInventory"})]}),"\n",(0,l.jsxs)(s.p,{children:["Returns ",(0,l.jsx)(s.code,{children:"success, response"})," if cb is undefined, otherwise they are used in the callback only."]}),"\n",(0,l.jsx)(s.p,{children:(0,l.jsx)(s.strong,{children:'Possible value of the "response" argument, on failure:'})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:'"invalid_item": the item doesn\'t exist'}),"\n",(0,l.jsx)(s.li,{children:'"invalid_inventory": the inventory doesn\'t exist'}),"\n",(0,l.jsx)(s.li,{children:'"inventory_full": no free slots'}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" success, response "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"AddItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'gloveVGH283'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'bread'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"4"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"not"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" success "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'-- if no slots are available, the value will be "inventory_full"'})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(response)"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(response, {indent"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}))"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"--[["})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" {"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "metadata": [],'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "label": "Bread",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "slot": 1,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "stack": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "close": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "name": "bread",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "count": 1,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "weight": 150'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"]]"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"removeitem",children:"RemoveItem"}),"\n",(0,l.jsx)(s.p,{children:"Removes the specified item from the specified inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RemoveItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, count, metadata, slot)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["The inventory's unique id, or a table with the id and owner.","\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"1"})]}),"\n",(0,l.jsxs)(s.li,{children:["inventoryId: ",(0,l.jsx)(s.code,{children:"gloveVGH283"})]}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"{ id = 'personallocker', owner = 'license:xxxxxx'}"})}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"The name of the item to remove from the target."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["count: ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"The number of items to remove."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Only remove items with matching metadata properties."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["slot?: ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"A specific slot to remove the item from. If the slot is invalid, the first available slot will be used instead."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["cb?: function(success: ",(0,l.jsx)(s.code,{children:"boolean"}),", response?: ",(0,l.jsx)(s.code,{children:"string"}),")"]}),"\n"]}),"\n",(0,l.jsxs)(s.p,{children:["Returns success: ",(0,l.jsx)(s.code,{children:"boolean"}),", response: ",(0,l.jsx)(s.code,{children:"string?"}),"."]}),"\n",(0,l.jsx)(s.p,{children:(0,l.jsx)(s.strong,{children:'Possible values of "response" on failure:'})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:'"invalid_item": the item doesn\'t exist'}),"\n",(0,l.jsx)(s.li,{children:'"invalid_inventory": the inventory doesn\'t exist'}),"\n",(0,l.jsx)(s.li,{children:'"not_enough_items": inventory did not contain enough of the given item'}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Removes 2 water from the glovebox for the given plate."})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" success "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RemoveItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'gloveVGH283'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"getitem",children:"GetItem"}),"\n",(0,l.jsxs)(s.p,{children:["Returns ",(0,l.jsx)(s.em,{children:"generic"})," item data from the specified inventory, with the total count."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, metadata, returnsCount)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Can be items array."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"any"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Only returns the count of items that strictly match the given metadata."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["returnsCount?: ",(0,l.jsx)(s.code,{children:"boolean"})]}),"\n"]}),"\n",(0,l.jsxs)(s.p,{children:["If ",(0,l.jsx)(s.code,{children:"returnsCount"})," is set to true, the returned value will be the ",(0,l.jsx)(s.code,{children:"count"})," based on\nhow many times the item was found.\nOtherwise returns the data related to the item ",(0,l.jsx)(s.em,{children:"and"})," its total count found in the inventory."]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" item "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"nil"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"false"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(item, {indent"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}))"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"--[["})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" {"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "consume": 1,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "count": 15,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "stack": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "name": "water",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "weight": 500,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "label": "Water",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "close": true'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"]]"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"convertitems",children:"ConvertItems"}),"\n",(0,l.jsx)(s.p,{children:"Takes traditional item data and updates it to support ox_inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"ConvertItems"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(playerId, items)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["items: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Data Conversion Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"Old: [{"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"cola"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"bread"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}]"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"New: [{"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"slot"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"name"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"cola"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"count"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"},"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"{"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"slot"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"name"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"bread"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"count"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}]"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"cancarryitem",children:"CanCarryItem"}),"\n",(0,l.jsx)(s.p,{children:"Returns true or false depending if the inventory can carry the specified item."}),"\n",(0,l.jsx)(s.p,{children:"The function checks for inventory weight and available slots."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, count, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["item ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Can be array of items."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["count: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["If metadata is passed as string then ",(0,l.jsx)(s.code,{children:"metadata.type"})," will be checked."]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Checks if the player calling the event can carry 3 water items"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:") "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Do stuff if can carry"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"else"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Do stuff if can't carry"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"cancarryamount",children:"CanCarryAmount"}),"\n",(0,l.jsx)(s.p,{children:"Returns the amount a player can hold based on available weight."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryAmount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Can be array to check multiple items."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Checks how much you can carry"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"amountToAdd "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryAmount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stone'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Adds the amount"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"AddItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stone'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", amountToAdd)"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"cancarryweight",children:"CanCarryWeight"}),"\n",(0,l.jsx)(s.p,{children:"Returns if inventory can carry specified weight and free inventory weight."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryWeight"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, weight)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["weight: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Checks if player can carry 1000 grams."})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" fillAmount "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1000"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" canCarryWeight, freeWeight "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryWeight"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(playerId, fillAmount)"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" freeWeight "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"=="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"0"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Player can't carry weight."})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"elseif"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"not"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" canCarryWeight "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Modify fillAmount, because inventory can't carry specified weight"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" fillAmount "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" freeWeight"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Do something"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"setmaxweight",children:"SetMaxWeight"}),"\n",(0,l.jsx)(s.p,{children:"Sets the maximum weight available for an inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetMaxWeight"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, maxWeight)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["maxWeight: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Set the max weight for player 1's inventory to 20kg."})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetMaxWeight"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"20000"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"canswapitem",children:"CanSwapItem"}),"\n",(0,l.jsx)(s.p,{children:"Returns true if the item swap is possible based on inventory weight."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanSwapItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, firstItem, firstItemCount, testItem, testItemCount)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["firstItem: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["firstItemCount: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["testItem: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["testItemCount: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getitemcount",children:"GetItemCount"}),"\n",(0,l.jsx)(s.p,{children:"Get the total item count for all items in an inventory with the given name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetItemCount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["itemCount: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getitemslots",children:"GetItemSlots"}),"\n",(0,l.jsx)(s.p,{children:"Returns the number of slots the specified item is in, the item's total count and the remaining empty slots."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetItemSlots"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslot",children:"GetSlot"}),"\n",(0,l.jsx)(s.p,{children:"Returns the specified slot data as a table."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlot"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slot)"})]})]})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slot: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" slot "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlot"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(slot, {indent"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}))"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"--[["})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" {"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "weight": 2000,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "name": "water",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "metadata": [],'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "slot": 1,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "label": "Water",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "close": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "stack": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "count: 4'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"]]"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"getslotforitem",children:"GetSlotForItem"}),"\n",(0,l.jsx)(s.p,{children:"Get the slot id of an existing item matching the given data, or an empty slot."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotForItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata: ",(0,l.jsx)(s.code,{children:"table?"})]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotId: ",(0,l.jsx)(s.code,{children:"number?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslotidwithitem",children:"GetSlotIdWithItem"}),"\n",(0,l.jsx)(s.p,{children:"Get a slot id in an inventory matching the given item name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotIdWithItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotId: ",(0,l.jsx)(s.code,{children:"number?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslotidswithitem",children:"GetSlotIdsWithItem"}),"\n",(0,l.jsx)(s.p,{children:"Get all slot ids in an inventory matching the given name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotIdsWithItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotIds: ",(0,l.jsx)(s.code,{children:"number[]?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslotwithitem",children:"GetSlotWithItem"}),"\n",(0,l.jsx)(s.p,{children:"Get data for a slot in an inventory matching the given name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotWithItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotData: ",(0,l.jsx)(s.code,{children:"table?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslotswithitem",children:"GetSlotsWithItem"}),"\n",(0,l.jsx)(s.p,{children:"Get data all slots in an inventory matching the given name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotsWithItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotsData: ",(0,l.jsx)(s.code,{children:"table[]?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getemptyslot",children:"GetEmptySlot"}),"\n",(0,l.jsx)(s.p,{children:"Get the first available empty slot in an inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetEmptySlot"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotId: ",(0,l.jsx)(s.code,{children:"number?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getcontainerfromslot",children:"GetContainerFromSlot"}),"\n",(0,l.jsx)(s.p,{children:"Returns the inventory associated with the container linked in the slot of the given inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetContainerFromSlot"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slotId)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slotId: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["containerData: ",(0,l.jsx)(s.code,{children:"table?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"setslotcount",children:"SetSlotCount"}),"\n",(0,l.jsx)(s.p,{children:"Sets the number of slots available for an inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetSlotCount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slots)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slots: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Set the slot count for player 1's inventory to 10."})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetSlotCount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"10"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"getinventory",children:"GetInventory"}),"\n",(0,l.jsx)(s.p,{children:"Returns the inventory associated with the ID (and owner if defined). Otherwise returns null."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, owner)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"number"})," or ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["owner?: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"boolean"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'example_stash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"false"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inventory, {indent "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}))"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"--[["})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" {"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "id": "example_stash,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "label": "Police Stash",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "type": "stash,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "slots": 50,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "weight": 0,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "maxWeight": 100000,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "owner": false,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" ..."})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"]]"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"getinventoryitems",children:"GetInventoryItems"}),"\n",(0,l.jsx)(s.p,{children:"Returns all slots with items in a inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetInventoryItems"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, owner)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"number"})," or ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["owner?: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"boolean"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" playerItems "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetInventoryItems"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source)"})]})})}),"\n",(0,l.jsx)(s.h2,{id:"confiscateinventory",children:"ConfiscateInventory"}),"\n",(0,l.jsx)(s.p,{children:"Clears a player's inventory and saves it to a stash."}),"\n",(0,l.jsxs)(s.p,{children:["Use ",(0,l.jsx)(s.a,{href:"#returninventory",children:"ReturnInventory"})," to return the confiscated inventory back to\nthe player."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"ConfiscateInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["source: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"returninventory",children:"ReturnInventory"}),"\n",(0,l.jsx)(s.p,{children:"Returns the confiscated inventory back to the player."}),"\n",(0,l.jsxs)(s.p,{children:["Use it alongside ",(0,l.jsx)(s.a,{href:"#confiscateinventory",children:"ConfiscateInventory"}),"."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"ReturnInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["source: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"clearinventory",children:"ClearInventory"}),"\n",(0,l.jsxs)(s.p,{children:["Clears the specified inventory. The ",(0,l.jsx)(s.code,{children:"keep"})," argument is either a string or an array of strings containing the name(s) of the item(s) to keep in the inventory after clearing."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"ClearInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, keep)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["keep?: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"string[]"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"search",children:"Search"}),"\n",(0,l.jsx)(s.p,{children:"Searches an inventory for a specified item."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"Search"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, search, item, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["search: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n",(0,l.jsxs)(s.p,{children:[(0,l.jsx)(s.code,{children:"search"})," can be either ",(0,l.jsx)(s.code,{children:"'slots'"})," or ",(0,l.jsx)(s.code,{children:"'count'"}),", where slots will return a table of data\nand count will return the found amount of the specified item."]}),"\n",(0,l.jsx)(s.h2,{id:"swapslots",children:"SwapSlots"}),"\n",(0,l.jsx)(s.p,{children:"Swaps slots in specified inventories."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SwapSlots"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(fromInventory, toInventory, slot1, slot2)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["fromInventory: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["toInventory: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slot1: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slot2: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"registerstash",children:"RegisterStash"}),"\n",(0,l.jsx)(s.p,{children:"Creates a new custom stash."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RegisterStash"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(id, label, slots, maxWeight, owner, groups, coords)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["id: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Stash identifier when loading from the database."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["label: ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Display name when inventory is open."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["slots: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["maxWeight: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["owner: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"boolean"})," or ",(0,l.jsx)(s.code,{children:"nil"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"string"}),": Can only access the stash linked to the owner."]}),"\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"true"}),": Each player has a unique stash but can request other player's stashes."]}),"\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"nil"}),": Always shared."]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["groups: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Table of player groups (jobs) able to access the stash."}),"\n",(0,l.jsx)(s.li,{children:"Table of group names where the numeric value is the minimum grade required."}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"{['police'] = 0, ['ambulance'] = 2}"})}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["coords?: ",(0,l.jsx)(s.code,{children:"vector3"})," or ",(0,l.jsx)(s.code,{children:"vector3[]"})]}),"\n"]}),"\n",(0,l.jsx)(t.UW,{children:(0,l.jsx)(s.p,{children:"This function needs to be triggered before a player can open the stash."})}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsxs)(s.p,{children:[(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),(0,l.jsx)("br",{}),"\nFor a use case example on this function check out the written ",(0,l.jsx)(s.a,{href:"../Guides/stashes",children:"Guide"})," for it."]}),"\n",(0,l.jsx)(s.h2,{id:"createtemporarystash",children:"CreateTemporaryStash"}),"\n",(0,l.jsx)(s.p,{children:"Creates a temporary stash which will be removed after some time."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CreateTemporaryStash"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(properties)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["properties: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["label: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["slots: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["maxWeight: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["owner?: ",(0,l.jsx)(s.code,{children:"string"})," ",(0,l.jsx)(s.code,{children:"number"})," or ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"string"}),": Can only access the stash linked to the owner."]}),"\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"true"}),": Each player has a unique stash but can request other player's stashes."]}),"\n",(0,l.jsxs)(s.li,{children:["The inventory is always shared if ",(0,l.jsx)(s.code,{children:"false"})," or ",(0,l.jsx)(s.code,{children:"nil"}),"."]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["groups?: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Table of group names (e.g. jobs) where the numeric value is the minimum grade required."}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"{['police'] = 0, ['ambulance'] = 2}"})}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["coords?: ",(0,l.jsx)(s.code,{children:"vector3"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Stash can only be accessed while nearby."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["items?: ",(0,l.jsx)(s.code,{children:"{ [number]: string, [number]: number, [number]?: table }[]"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"An array of tables, containing a sequence of itemName, count, metadata."}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inventoryId: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" mystash "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CreateTemporaryStash"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'mystash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" slots "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" maxWeight "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5000"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" items "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'WEAPON_MINISMG'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'ammo-9'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"69"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", { label "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Mineral water' "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"} }"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"TriggerClientEvent"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'ox_inventory:openInventory'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", mystash)"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"customdrop",children:"CustomDrop"}),"\n",(0,l.jsx)(s.p,{children:"Drops can be created from other resources, containing a variety of items and utilising a custom label (instead of 'Drop 32648')."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CustomDrop"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(prefix, items, coords, slots, maxWeight, instance, model)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["prefix: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["items: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["name: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["count: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["coords: ",(0,l.jsx)(s.code,{children:"vector3"})]}),"\n",(0,l.jsxs)(s.li,{children:["slots?: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["maxWeight?: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["instance?: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["model?: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Create a generic drop with a marker"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CustomDrop"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Carcass'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", {"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'meat'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", { grade "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", type "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'deer' "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}},"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'hide'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", { grade "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", type "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'deer' "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}}"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}, coords)"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Create a drop with an entity"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CustomDrop"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'SMG'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", {"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'WEAPON_MINISMG'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'ammo-9'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"69"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetEntityCoords"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetPlayerPed"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")), "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"10000"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"nil"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"`w_sb_minismg`"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"createdropfromplayer",children:"CreateDropFromPlayer"}),"\n",(0,l.jsx)(s.p,{children:"Creates a new drop with the contents of a player's inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CreateDropFromPlayer"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(playerId)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["dropId: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" dropId "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CreateDropFromPlayer"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})})}),"\n",(0,l.jsx)(s.h2,{id:"getcurrentweapon",children:"GetCurrentWeapon"}),"\n",(0,l.jsx)(s.p,{children:"Returns the player's currently equipped weapon as a table."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- inv: string or number"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetCurrentWeapon"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv)"})]})]})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"setdurability",children:"SetDurability"}),"\n",(0,l.jsx)(s.p,{children:"Sets durability onto the specified slot."}),"\n",(0,l.jsx)(s.p,{children:"Can be used for repairing weapons."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetDurability"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slot, durability)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slot: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["durability: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Set the durability of the item in slot 3 of source player's inventory to 100"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetDurability"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"100"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Set the durability of the source player's current weapon to 100"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" weapon "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetCurrentWeapon"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source)"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" weapon "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetDurability"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, weapon.slot, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"100"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"setmetadata",children:"SetMetadata"}),"\n",(0,l.jsx)(s.p,{children:"Sets metadata on the specified slot."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetMetadata"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slot, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slot: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" water "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"Search"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"for"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" k, v "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"in"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"pairs"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(water) "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"do"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'\\n______________'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:".."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'\\n- index '"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:".."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"k)"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(v.name, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'slot: '"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:".."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"v.slot, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'metadata: '"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:".."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(v.metadata))"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" water "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" v"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"break"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"water.metadata.type "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'clean'"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetMetadata"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, water.slot, water.metadata)"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'modified %sx water in slot %s with new metadata'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"):"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"format"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(water.count, water.slot))"})]})]})})]})}s.default=(0,r.j)({MDXContent:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:s}=Object.assign({},(0,i.a)(),e.components);return s?(0,l.jsx)(s,{...e,children:(0,l.jsx)(a,{...e})}):a(e)},pageOpts:{filePath:"pages/ox_inventory/Functions/Server.mdx",route:"/ox_inventory/Functions/Server",title:"Server",headings:o},pageNextRoute:"/ox_inventory/Functions/Server"})}},function(e){e.O(0,[2059,9774,2888,179],function(){return e(e.s=5929)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/pages/ox_inventory/Functions/Server-836e4f28c5115b3a.js b/_next/static/chunks/pages/ox_inventory/Functions/Server-836e4f28c5115b3a.js new file mode 100644 index 0000000000..7db1b31f3d --- /dev/null +++ b/_next/static/chunks/pages/ox_inventory/Functions/Server-836e4f28c5115b3a.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5789],{5929:function(e,s,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/ox_inventory/Functions/Server",function(){return n(5830)}])},5830:function(e,s,n){"use strict";n.r(s),n.d(s,{__toc:function(){return o}});var l=n(1527),r=n(2059),i=n(3443),t=n(8242);let o=[{depth:2,value:"setPlayerInventory",id:"setplayerinventory"},{depth:2,value:"forceOpenInventory",id:"forceopeninventory"},{depth:2,value:"UpdateVehicle",id:"updatevehicle"},{depth:2,value:"Items",id:"items"},{depth:2,value:"AddItem",id:"additem"},{depth:2,value:"RemoveItem",id:"removeitem"},{depth:2,value:"GetItem",id:"getitem"},{depth:2,value:"ConvertItems",id:"convertitems"},{depth:2,value:"CanCarryItem",id:"cancarryitem"},{depth:2,value:"CanCarryAmount",id:"cancarryamount"},{depth:2,value:"CanCarryWeight",id:"cancarryweight"},{depth:2,value:"SetMaxWeight",id:"setmaxweight"},{depth:2,value:"CanSwapItem",id:"canswapitem"},{depth:2,value:"GetItemCount",id:"getitemcount"},{depth:2,value:"GetItemSlots",id:"getitemslots"},{depth:2,value:"GetSlot",id:"getslot"},{depth:2,value:"GetSlotForItem",id:"getslotforitem"},{depth:2,value:"GetSlotIdWithItem",id:"getslotidwithitem"},{depth:2,value:"GetSlotIdsWithItem",id:"getslotidswithitem"},{depth:2,value:"GetSlotWithItem",id:"getslotwithitem"},{depth:2,value:"GetSlotsWithItem",id:"getslotswithitem"},{depth:2,value:"GetEmptySlot",id:"getemptyslot"},{depth:2,value:"GetContainerFromSlot",id:"getcontainerfromslot"},{depth:2,value:"SetSlotCount",id:"setslotcount"},{depth:2,value:"GetInventory",id:"getinventory"},{depth:2,value:"GetInventoryItems",id:"getinventoryitems"},{depth:2,value:"ConfiscateInventory",id:"confiscateinventory"},{depth:2,value:"ReturnInventory",id:"returninventory"},{depth:2,value:"ClearInventory",id:"clearinventory"},{depth:2,value:"Search",id:"search"},{depth:2,value:"RegisterStash",id:"registerstash"},{depth:2,value:"CreateTemporaryStash",id:"createtemporarystash"},{depth:2,value:"CustomDrop",id:"customdrop"},{depth:2,value:"CreateDropFromPlayer",id:"createdropfromplayer"},{depth:2,value:"GetCurrentWeapon",id:"getcurrentweapon"},{depth:2,value:"SetDurability",id:"setdurability"},{depth:2,value:"SetMetadata",id:"setmetadata"}];function a(e){let s=Object.assign({h1:"h1",h2:"h2",p:"p",pre:"pre",code:"code",span:"span",ul:"ul",li:"li",a:"a",strong:"strong",em:"em"},(0,i.a)(),e.components);return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(s.h1,{children:"Server"}),"\n",(0,l.jsx)(s.h2,{id:"setplayerinventory",children:"setPlayerInventory"}),"\n",(0,l.jsx)(s.p,{children:"Creates and sets the player's inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"setPlayerInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(player, data)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["player: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["source: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["identifier: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["name: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["groups?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["sex?: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["dateofbirth?: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["data?: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"If not provided will load player's inventory data from the db."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"forceopeninventory",children:"forceOpenInventory"}),"\n",(0,l.jsx)(s.p,{children:"Opens an inventory using the passed data.\nForces a player to open an inventory, without usual security checks (groups, coords)."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(playerId, invType, data)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["invType: ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'player'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'stash'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'container'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'drop'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'glovebox'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'trunk'"})}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"'dumpster'"})}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["data: ",(0,l.jsx)(s.code,{children:"number"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n",(0,l.jsxs)(t.mQ,{items:["Player","Stash"],children:[(0,l.jsxs)(t.OK,{children:[(0,l.jsx)(s.p,{children:"Open the target player's inventory."}),(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'player'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})})}),(0,l.jsx)(s.p,{children:"Admin command to open a player's inventory."}),(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RegisterCommand"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'openplayerinv'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-parameter)"},children:"source"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-parameter)"},children:"args"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'player'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"tonumber"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(args["}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"]))"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})})]}),(0,l.jsxs)(t.OK,{children:[(0,l.jsx)(s.p,{children:"Open a custom stash (created on the server with RegisterStash)."}),(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'society_police'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})})}),(0,l.jsx)(s.p,{children:"Open a stash with a specific owner."}),(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"forceOpenInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", { id "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_locker'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", owner "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'license:xxxxxxxx' "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"})"})]})})})]})]}),"\n",(0,l.jsx)(s.h2,{id:"updatevehicle",children:"UpdateVehicle"}),"\n",(0,l.jsx)(s.p,{children:"Update the internal reference to vehicle stashes, without triggering a save or updating the database."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"UpdateVehicle"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(oldPlate, newPlate)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["oldPlate: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["newPlate: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"items",children:"Items"}),"\n",(0,l.jsxs)(s.p,{children:["Returns a table of all registered items. The format is as defined in ",(0,l.jsx)(s.a,{href:"https://github.com/overextended/ox_inventory/blob/main/data/items.lua",children:"data/items.lua"}),"."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"Items"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]})})}),"\n",(0,l.jsx)(s.p,{children:"The following snippet can be used in crafting resources such as okokCrafting or core_crafting, rather than querying the database."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" itemNames"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ESX."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RegisterServerCallback"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'crafting:itemNames'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-parameter)"},children:"source"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-parameter)"},children:"cb"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"not"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" itemNames "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" itemNames "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {}"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"for"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" item, data "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"in"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"pairs"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"Items"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"()) "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"do"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" itemNames[item] "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" data.label"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"cb"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(itemNames)"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"additem",children:"AddItem"}),"\n",(0,l.jsx)(s.p,{children:"Adds an item into the specified inventory."}),"\n",(0,l.jsxs)(s.p,{children:["Should be used alongside ",(0,l.jsx)(s.a,{href:"#cancarryitem",children:"CanCarryItem"})," otherwise, the maximum weight may be exceeded."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"AddItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, count, metadata, slot, cb)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["The inventory's unique id, or a table with the id and owner.","\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"1"})]}),"\n",(0,l.jsxs)(s.li,{children:["inventoryId: ",(0,l.jsx)(s.code,{children:"gloveVGH283"})]}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"{ id = 'personallocker', owner = 'license:xxxxxx'}"})}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"The name of the item to add to the target."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["count: ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"The number of items to add."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:'A table of unique data to attach to the item object. A string will create a table with the "type" field.'}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["slot?: ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"A specific slot to add the item to. If the slot is invalid, the first available slot will be used instead."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["cb?: function(success: ",(0,l.jsx)(s.code,{children:"boolean"}),", response?: ",(0,l.jsx)(s.code,{children:"string"}),")"]}),"\n"]}),"\n",(0,l.jsxs)(s.p,{children:["If used for glovebox, trunk or stash you must first check the inventory is loaded with ",(0,l.jsx)(s.a,{href:"./GetInventory",children:"GetInventory"})]}),"\n",(0,l.jsxs)(s.p,{children:["Returns ",(0,l.jsx)(s.code,{children:"success, response"})," if cb is undefined, otherwise they are used in the callback only."]}),"\n",(0,l.jsx)(s.p,{children:(0,l.jsx)(s.strong,{children:'Possible value of the "response" argument, on failure:'})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:'"invalid_item": the item doesn\'t exist'}),"\n",(0,l.jsx)(s.li,{children:'"invalid_inventory": the inventory doesn\'t exist'}),"\n",(0,l.jsx)(s.li,{children:'"inventory_full": no free slots'}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" success, response "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"AddItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'gloveVGH283'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'bread'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"4"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"not"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" success "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:'-- if no slots are available, the value will be "inventory_full"'})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(response)"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(response, {indent"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}))"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"--[["})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" {"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "metadata": [],'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "label": "Bread",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "slot": 1,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "stack": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "close": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "name": "bread",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "count": 1,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "weight": 150'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"]]"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"removeitem",children:"RemoveItem"}),"\n",(0,l.jsx)(s.p,{children:"Removes the specified item from the specified inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RemoveItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, count, metadata, slot, ignoreTotal)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["The inventory's unique id, or a table with the id and owner.","\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"1"})]}),"\n",(0,l.jsxs)(s.li,{children:["inventoryId: ",(0,l.jsx)(s.code,{children:"gloveVGH283"})]}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"{ id = 'personallocker', owner = 'license:xxxxxx'}"})}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"The name of the item to remove from the target."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["count: ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"The number of items to remove."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Only remove items with matching metadata properties."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["slot?: ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"A specific slot to remove the item from. If the slot is invalid, the first available slot will be used instead."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["ignoreTotal?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Removes as many items as possible up to count."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.p,{children:["Returns success: ",(0,l.jsx)(s.code,{children:"boolean"}),", response: ",(0,l.jsx)(s.code,{children:"string?"}),"."]}),"\n",(0,l.jsx)(s.p,{children:(0,l.jsx)(s.strong,{children:'Possible values of "response" on failure:'})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:'"invalid_item": the item doesn\'t exist'}),"\n",(0,l.jsx)(s.li,{children:'"invalid_inventory": the inventory doesn\'t exist'}),"\n",(0,l.jsx)(s.li,{children:'"not_enough_items": inventory did not contain enough of the given item'}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Removes 2 water from the glovebox for the given plate."})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" success "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RemoveItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'gloveVGH283'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"getitem",children:"GetItem"}),"\n",(0,l.jsxs)(s.p,{children:["Returns ",(0,l.jsx)(s.em,{children:"generic"})," item data from the specified inventory, with the total count."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, metadata, returnsCount)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Can be items array."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"any"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Only returns the count of items that strictly match the given metadata."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["returnsCount?: ",(0,l.jsx)(s.code,{children:"boolean"})]}),"\n"]}),"\n",(0,l.jsxs)(s.p,{children:["If ",(0,l.jsx)(s.code,{children:"returnsCount"})," is set to true, the returned value will be the ",(0,l.jsx)(s.code,{children:"count"})," based on\nhow many times the item was found.\nOtherwise returns the data related to the item ",(0,l.jsx)(s.em,{children:"and"})," its total count found in the inventory."]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" item "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"nil"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"false"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(item, {indent"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}))"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"--[["})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" {"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "consume": 1,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "count": 15,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "stack": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "name": "water",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "weight": 500,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "label": "Water",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "close": true'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"]]"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"convertitems",children:"ConvertItems"}),"\n",(0,l.jsx)(s.p,{children:"Takes traditional item data and updates it to support ox_inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"ConvertItems"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(playerId, items)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["items: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Data Conversion Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"Old: [{"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"cola"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"bread"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}]"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"New: [{"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"slot"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"name"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"cola"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"count"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"},"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"{"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"slot"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"name"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"bread"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"count"'}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:":"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}]"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"cancarryitem",children:"CanCarryItem"}),"\n",(0,l.jsx)(s.p,{children:"Returns true or false depending if the inventory can carry the specified item."}),"\n",(0,l.jsx)(s.p,{children:"The function checks for inventory weight and available slots."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, count, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["item ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Can be array of items."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["count: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["If metadata is passed as string then ",(0,l.jsx)(s.code,{children:"metadata.type"})," will be checked."]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Checks if the player calling the event can carry 3 water items"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:") "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Do stuff if can carry"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"else"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Do stuff if can't carry"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"cancarryamount",children:"CanCarryAmount"}),"\n",(0,l.jsx)(s.p,{children:"Returns the amount a player can hold based on available weight."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryAmount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Can be array to check multiple items."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Checks how much you can carry"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"amountToAdd "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryAmount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stone'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Adds the amount"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"AddItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stone'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", amountToAdd)"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"cancarryweight",children:"CanCarryWeight"}),"\n",(0,l.jsx)(s.p,{children:"Returns if inventory can carry specified weight and free inventory weight."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryWeight"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, weight)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["weight: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Checks if player can carry 1000 grams."})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" fillAmount "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1000"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" canCarryWeight, freeWeight "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanCarryWeight"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(playerId, fillAmount)"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" freeWeight "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"=="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"0"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Player can't carry weight."})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"elseif"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"not"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" canCarryWeight "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Modify fillAmount, because inventory can't carry specified weight"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" fillAmount "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" freeWeight"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Do something"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"setmaxweight",children:"SetMaxWeight"}),"\n",(0,l.jsx)(s.p,{children:"Sets the maximum weight available for an inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetMaxWeight"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, maxWeight)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["maxWeight: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Set the max weight for player 1's inventory to 20kg."})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetMaxWeight"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"20000"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"canswapitem",children:"CanSwapItem"}),"\n",(0,l.jsx)(s.p,{children:"Returns true if the item swap is possible based on inventory weight."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CanSwapItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, firstItem, firstItemCount, testItem, testItemCount)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["firstItem: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["firstItemCount: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["testItem: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["testItemCount: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getitemcount",children:"GetItemCount"}),"\n",(0,l.jsx)(s.p,{children:"Get the total item count for all items in an inventory with the given name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetItemCount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["itemCount: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getitemslots",children:"GetItemSlots"}),"\n",(0,l.jsx)(s.p,{children:"Returns the number of slots the specified item is in, the item's total count and the remaining empty slots."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetItemSlots"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, item, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslot",children:"GetSlot"}),"\n",(0,l.jsx)(s.p,{children:"Returns the specified slot data as a table."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlot"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slot)"})]})]})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slot: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" slot "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlot"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(slot, {indent"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}))"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"--[["})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" {"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "weight": 2000,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "name": "water",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "metadata": [],'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "slot": 1,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "label": "Water",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "close": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "stack": true,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "count: 4'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"]]"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"getslotforitem",children:"GetSlotForItem"}),"\n",(0,l.jsx)(s.p,{children:"Get the slot id of an existing item matching the given data, or an empty slot."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotForItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata: ",(0,l.jsx)(s.code,{children:"table?"})]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotId: ",(0,l.jsx)(s.code,{children:"number?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslotidwithitem",children:"GetSlotIdWithItem"}),"\n",(0,l.jsx)(s.p,{children:"Get a slot id in an inventory matching the given item name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotIdWithItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotId: ",(0,l.jsx)(s.code,{children:"number?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslotidswithitem",children:"GetSlotIdsWithItem"}),"\n",(0,l.jsx)(s.p,{children:"Get all slot ids in an inventory matching the given name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotIdsWithItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotIds: ",(0,l.jsx)(s.code,{children:"number[]?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslotwithitem",children:"GetSlotWithItem"}),"\n",(0,l.jsx)(s.p,{children:"Get data for a slot in an inventory matching the given name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotWithItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotData: ",(0,l.jsx)(s.code,{children:"table?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getslotswithitem",children:"GetSlotsWithItem"}),"\n",(0,l.jsx)(s.p,{children:"Get data all slots in an inventory matching the given name and metadata."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetSlotsWithItem"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, itemName, metadata, strict)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["itemName: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["strict?: ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Strictly match metadata properties, otherwise use partial matching."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotsData: ",(0,l.jsx)(s.code,{children:"table[]?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getemptyslot",children:"GetEmptySlot"}),"\n",(0,l.jsx)(s.p,{children:"Get the first available empty slot in an inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetEmptySlot"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["slotId: ",(0,l.jsx)(s.code,{children:"number?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"getcontainerfromslot",children:"GetContainerFromSlot"}),"\n",(0,l.jsx)(s.p,{children:"Returns the inventory associated with the container linked in the slot of the given inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetContainerFromSlot"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slotId)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slotId: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["containerData: ",(0,l.jsx)(s.code,{children:"table?"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"setslotcount",children:"SetSlotCount"}),"\n",(0,l.jsx)(s.p,{children:"Sets the number of slots available for an inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetSlotCount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slots)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slots: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Set the slot count for player 1's inventory to 10."})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetSlotCount"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"10"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"getinventory",children:"GetInventory"}),"\n",(0,l.jsx)(s.p,{children:"Returns the inventory associated with the ID (and owner if defined). Otherwise returns null."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, owner)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"number"})," or ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["owner?: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"boolean"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'example_stash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"false"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inventory, {indent "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}))"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"--[["})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" {"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "id": "example_stash,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "label": "Police Stash",'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "type": "stash,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "slots": 50,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "weight": 0,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "maxWeight": 100000,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:' "owner": false,'})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" ..."})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"]]"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"getinventoryitems",children:"GetInventoryItems"}),"\n",(0,l.jsx)(s.p,{children:"Returns all slots with items in a inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetInventoryItems"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, owner)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"number"})," or ",(0,l.jsx)(s.code,{children:"table"})]}),"\n",(0,l.jsxs)(s.li,{children:["owner?: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"boolean"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" playerItems "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetInventoryItems"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source)"})]})})}),"\n",(0,l.jsx)(s.h2,{id:"confiscateinventory",children:"ConfiscateInventory"}),"\n",(0,l.jsx)(s.p,{children:"Clears a player's inventory and saves it to a stash."}),"\n",(0,l.jsxs)(s.p,{children:["Use ",(0,l.jsx)(s.a,{href:"#returninventory",children:"ReturnInventory"})," to return the confiscated inventory back to\nthe player."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"ConfiscateInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["source: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"returninventory",children:"ReturnInventory"}),"\n",(0,l.jsx)(s.p,{children:"Returns the confiscated inventory back to the player."}),"\n",(0,l.jsxs)(s.p,{children:["Use it alongside ",(0,l.jsx)(s.a,{href:"#confiscateinventory",children:"ConfiscateInventory"}),"."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"ReturnInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["source: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"clearinventory",children:"ClearInventory"}),"\n",(0,l.jsxs)(s.p,{children:["Clears the specified inventory. The ",(0,l.jsx)(s.code,{children:"keep"})," argument is either a string or an array of strings containing the name(s) of the item(s) to keep in the inventory after clearing."]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"ClearInventory"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, keep)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["keep?: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"string[]"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"search",children:"Search"}),"\n",(0,l.jsx)(s.p,{children:"Searches an inventory for a specified item."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"Search"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, search, item, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["search: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["item: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n",(0,l.jsxs)(s.p,{children:[(0,l.jsx)(s.code,{children:"search"})," can be either ",(0,l.jsx)(s.code,{children:"'slots'"})," or ",(0,l.jsx)(s.code,{children:"'count'"}),", where slots will return a table of data\nand count will return the found amount of the specified item."]}),"\n",(0,l.jsx)(s.h2,{id:"registerstash",children:"RegisterStash"}),"\n",(0,l.jsx)(s.p,{children:"Creates a new custom stash."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"RegisterStash"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(id, label, slots, maxWeight, owner, groups, coords)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["id: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Stash identifier when loading from the database."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["label: ",(0,l.jsx)(s.code,{children:"string"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Display name when inventory is open."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["slots: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["maxWeight: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["owner: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"boolean"})," or ",(0,l.jsx)(s.code,{children:"nil"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"string"}),": Can only access the stash linked to the owner."]}),"\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"true"}),": Each player has a unique stash but can request other player's stashes."]}),"\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"nil"}),": Always shared."]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["groups: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Table of player groups (jobs) able to access the stash."}),"\n",(0,l.jsx)(s.li,{children:"Table of group names where the numeric value is the minimum grade required."}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"{['police'] = 0, ['ambulance'] = 2}"})}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["coords?: ",(0,l.jsx)(s.code,{children:"vector3"})," or ",(0,l.jsx)(s.code,{children:"vector3[]"})]}),"\n"]}),"\n",(0,l.jsx)(t.UW,{children:(0,l.jsx)(s.p,{children:"This function needs to be triggered before a player can open the stash."})}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsxs)(s.p,{children:[(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),(0,l.jsx)("br",{}),"\nFor a use case example on this function check out the written ",(0,l.jsx)(s.a,{href:"../Guides/stashes",children:"Guide"})," for it."]}),"\n",(0,l.jsx)(s.h2,{id:"createtemporarystash",children:"CreateTemporaryStash"}),"\n",(0,l.jsx)(s.p,{children:"Creates a temporary stash which will be removed after some time."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CreateTemporaryStash"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(properties)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["properties: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["label: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["slots: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["maxWeight: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["owner?: ",(0,l.jsx)(s.code,{children:"string"})," ",(0,l.jsx)(s.code,{children:"number"})," or ",(0,l.jsx)(s.code,{children:"boolean"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"string"}),": Can only access the stash linked to the owner."]}),"\n",(0,l.jsxs)(s.li,{children:[(0,l.jsx)(s.code,{children:"true"}),": Each player has a unique stash but can request other player's stashes."]}),"\n",(0,l.jsxs)(s.li,{children:["The inventory is always shared if ",(0,l.jsx)(s.code,{children:"false"})," or ",(0,l.jsx)(s.code,{children:"nil"}),"."]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["groups?: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Table of group names (e.g. jobs) where the numeric value is the minimum grade required."}),"\n",(0,l.jsx)(s.li,{children:(0,l.jsx)(s.code,{children:"{['police'] = 0, ['ambulance'] = 2}"})}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["coords?: ",(0,l.jsx)(s.code,{children:"vector3"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"Stash can only be accessed while nearby."}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["items?: ",(0,l.jsx)(s.code,{children:"{ [number]: string, [number]: number, [number]?: table }[]"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsx)(s.li,{children:"An array of tables, containing a sequence of itemName, count, metadata."}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inventoryId: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" mystash "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CreateTemporaryStash"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'mystash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" slots "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" maxWeight "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5000"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" items "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'WEAPON_MINISMG'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'ammo-9'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"69"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", { label "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Mineral water' "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"} }"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"TriggerClientEvent"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'ox_inventory:openInventory'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'stash'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", mystash)"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"customdrop",children:"CustomDrop"}),"\n",(0,l.jsx)(s.p,{children:"Drops can be created from other resources, containing a variety of items and utilising a custom label (instead of 'Drop 32648')."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CustomDrop"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(prefix, items, coords, slots, maxWeight, instance, model)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["prefix: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["items: ",(0,l.jsx)(s.code,{children:"table"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["name: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n",(0,l.jsxs)(s.li,{children:["count: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata?: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n"]}),"\n",(0,l.jsxs)(s.li,{children:["coords: ",(0,l.jsx)(s.code,{children:"vector3"})]}),"\n",(0,l.jsxs)(s.li,{children:["slots?: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["maxWeight?: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["instance?: ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["model?: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Create a generic drop with a marker"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CustomDrop"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Carcass'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", {"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'meat'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", { grade "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", type "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'deer' "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}},"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'hide'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", { grade "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"2"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", type "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'deer' "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}}"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}, coords)"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Create a drop with an entity"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CustomDrop"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'SMG'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", {"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'WEAPON_MINISMG'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" { "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'ammo-9'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"69"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetEntityCoords"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetPlayerPed"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")), "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"10000"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"nil"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"`w_sb_minismg`"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,l.jsx)(s.h2,{id:"createdropfromplayer",children:"CreateDropFromPlayer"}),"\n",(0,l.jsx)(s.p,{children:"Creates a new drop with the contents of a player's inventory."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CreateDropFromPlayer"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(playerId)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["playerId: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.p,{children:"Return:"}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["dropId: ",(0,l.jsx)(s.code,{children:"string"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" dropId "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"CreateDropFromPlayer"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})})}),"\n",(0,l.jsx)(s.h2,{id:"getcurrentweapon",children:"GetCurrentWeapon"}),"\n",(0,l.jsx)(s.p,{children:"Returns the player's currently equipped weapon as a table."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- inv: string or number"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetCurrentWeapon"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv)"})]})]})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)(s.h2,{id:"setdurability",children:"SetDurability"}),"\n",(0,l.jsx)(s.p,{children:"Sets durability onto the specified slot."}),"\n",(0,l.jsx)(s.p,{children:"Can be used for repairing weapons."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"exports.ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetDurability"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slot, durability)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slot: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["durability: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Set the durability of the item in slot 3 of source player's inventory to 100"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetDurability"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"3"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"100"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- Set the durability of the source player's current weapon to 100"})}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" weapon "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"GetCurrentWeapon"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source)"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" weapon "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetDurability"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, weapon.slot, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"100"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})})]})}),"\n",(0,l.jsx)(s.h2,{id:"setmetadata",children:"SetMetadata"}),"\n",(0,l.jsx)(s.p,{children:"Sets metadata on the specified slot."}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetMetadata"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(inv, slot, metadata)"})]})})}),"\n",(0,l.jsxs)(s.ul,{children:["\n",(0,l.jsxs)(s.li,{children:["inv: ",(0,l.jsx)(s.code,{children:"table"})," or ",(0,l.jsx)(s.code,{children:"string"})," or ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["slot: ",(0,l.jsx)(s.code,{children:"number"})]}),"\n",(0,l.jsxs)(s.li,{children:["metadata: ",(0,l.jsx)(s.code,{children:"table"})]}),"\n"]}),"\n",(0,l.jsx)("br",{}),"\n",(0,l.jsx)("u",{children:(0,l.jsx)(s.strong,{children:"Example"})}),"\n",(0,l.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,l.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" exports.ox_inventory"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" water "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"Search"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'water'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"for"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" k, v "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"in"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"pairs"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(water) "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"do"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'\\n______________'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:".."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'\\n- index '"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:".."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"k)"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(v.name, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'slot: '"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:".."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"v.slot, "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'metadata: '"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:".."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"json."}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"encode"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(v.metadata))"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" water "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" v"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"break"})]}),"\n",(0,l.jsx)(s.span,{className:"line",children:(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})}),"\n",(0,l.jsx)(s.span,{className:"line",children:" "}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"water.metadata.type "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'clean'"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"ox_inventory:"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"SetMetadata"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(source, water.slot, water.metadata)"})]}),"\n",(0,l.jsxs)(s.span,{className:"line",children:[(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(("}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'modified %sx water in slot %s with new metadata'"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"):"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"format"}),(0,l.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(water.count, water.slot))"})]})]})})]})}s.default=(0,r.j)({MDXContent:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:s}=Object.assign({},(0,i.a)(),e.components);return s?(0,l.jsx)(s,{...e,children:(0,l.jsx)(a,{...e})}):a(e)},pageOpts:{filePath:"pages/ox_inventory/Functions/Server.mdx",route:"/ox_inventory/Functions/Server",title:"Server",headings:o},pageNextRoute:"/ox_inventory/Functions/Server"})}},function(e){e.O(0,[2059,9774,2888,179],function(){return e(e.s=5929)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/pages/ox_lib/Modules/Interface/Client/radial-3799eaaf2507a3e8.js b/_next/static/chunks/pages/ox_lib/Modules/Interface/Client/radial-3799eaaf2507a3e8.js new file mode 100644 index 0000000000..46a66f748c --- /dev/null +++ b/_next/static/chunks/pages/ox_lib/Modules/Interface/Client/radial-3799eaaf2507a3e8.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6508],{7687:function(s,e,l){(window.__NEXT_P=window.__NEXT_P||[]).push(["/ox_lib/Modules/Interface/Client/radial",function(){return l(6028)}])},6028:function(s,e,l){"use strict";l.r(e),l.d(e,{__toc:function(){return a}});var n=l(1527),i=l(2059),r=l(3443),o=l(8242);let a=[{depth:2,value:"lib.addRadialItem",id:"libaddradialitem"},{depth:2,value:"lib.removeRadialItem",id:"libremoveradialitem"},{depth:2,value:"lib.clearRadialItems",id:"libclearradialitems"},{depth:2,value:"lib.registerRadial",id:"libregisterradial"},{depth:2,value:"lib.hideRadial",id:"libhideradial"},{depth:2,value:"lib.disableRadial",id:"libdisableradial"},{depth:2,value:"lib.getCurrentRadialId",id:"libgetcurrentradialid"},{depth:2,value:"Usage Example",id:"usage-example"}];function c(s){let e=Object.assign({h1:"h1",ul:"ul",li:"li",code:"code",h2:"h2",p:"p",pre:"pre",span:"span",img:"img"},(0,r.a)(),s.components);return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(e.h1,{children:"Radial Menu"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["Radial menu has a global menu that's by default accessed with ",(0,n.jsx)(e.code,{children:"z"})," and only displays when there is at least one item."]}),"\n",(0,n.jsxs)(e.li,{children:["You can add and remove items from the global menu using ",(0,n.jsx)(e.code,{children:"lib.addRadialItem"})," and ",(0,n.jsx)(e.code,{children:"lib.removeRadialItem"}),"."]}),"\n",(0,n.jsxs)(e.li,{children:["Use ",(0,n.jsx)(e.code,{children:"lib.registerRadial"})," for creating sub menus and use the ",(0,n.jsx)(e.code,{children:"menu"})," property on the items to open those sub menus."]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libaddradialitem",children:"lib.addRadialItem"}),"\n",(0,n.jsx)(e.p,{children:"Item or array of items added to the global radial menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(items)"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(items);"})]})]})})})]}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["items: ",(0,n.jsx)(e.code,{children:"table"})," (",(0,n.jsx)(e.code,{children:"object"})," or ",(0,n.jsx)(e.code,{children:"array"}),")","\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["id: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Id that is used for removing options."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["icon: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Either a font awesome or a custom URI.1"}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["iconWidth?: ",(0,n.jsx)(e.code,{children:"number"})]}),"\n",(0,n.jsxs)(e.li,{children:["iconHeight?: ",(0,n.jsx)(e.code,{children:"number"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"In the case of a custom URI, adjust the size of the icon."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["label: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["Label uses ",(0,n.jsx)(e.code,{children:" \\n"})," to insert a newline"]}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["menu?: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Id of a menu to open."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["onSelect: ",(0,n.jsx)(e.code,{children:"function(currentMenu: string | nil, itemIndex: number)"})," | ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Function that's ran when a user clicks the item."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["keepOpen?: ",(0,n.jsx)(e.code,{children:"boolean"})]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libremoveradialitem",children:"lib.removeRadialItem"}),"\n",(0,n.jsx)(e.p,{children:"Id of an item to be removed from the global menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"removeRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(item)"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".removeRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(item);"})]})]})})})]}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["id: ",(0,n.jsx)(e.code,{children:"string"})]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libclearradialitems",children:"lib.clearRadialItems"}),"\n",(0,n.jsx)(e.p,{children:"Removes all items from the radial menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"clearRadialItems"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".clearRadialItems"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"();"})]})]})})})]}),"\n",(0,n.jsx)(e.h2,{id:"libregisterradial",children:"lib.registerRadial"}),"\n",(0,n.jsx)(e.p,{children:"Registers a radial sub menu with predefined options."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"registerRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(radial)"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".registerRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(radial);"})]})]})})})]}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["radial: ",(0,n.jsx)(e.code,{children:"table"})," (",(0,n.jsx)(e.code,{children:"object"}),")","\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["id: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["Unique menu id used to open with ",(0,n.jsx)(e.code,{children:"menu"})," prop on an item."]}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["items: ",(0,n.jsx)(e.code,{children:"array"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["icon: ",(0,n.jsx)(e.code,{children:"string"})]}),"\n",(0,n.jsxs)(e.li,{children:["label: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["Label uses ",(0,n.jsx)(e.code,{children:" \\n"})," to insert a newline"]}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["menu?: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Id of a menu to open."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["onSelect?: ",(0,n.jsx)(e.code,{children:"function(currentMenu: string | nil, itemIndex: number)"})," | ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Function that's ran when a user clicks the item."}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libhideradial",children:"lib.hideRadial"}),"\n",(0,n.jsx)(e.p,{children:"Hides the radial menu if one is open."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"hideRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".hideRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"();"})]})]})})})]}),"\n",(0,n.jsx)(e.h2,{id:"libdisableradial",children:"lib.disableRadial"}),"\n",(0,n.jsx)(e.p,{children:"Disallow players from opening the radial menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"disableRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(state)"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".disableRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(state);"})]})]})})})]}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["state: ",(0,n.jsx)(e.code,{children:"boolean"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Whether or not radial menu should be disabled"}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libgetcurrentradialid",children:"lib.getCurrentRadialId"}),"\n",(0,n.jsx)(e.p,{children:"Returns the id of the currently open radial menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"getCurrentRadialId"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"let"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".getCurrentRadialId"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"();"})]})]})})})]}),"\n",(0,n.jsx)(e.h2,{id:"usage-example",children:"Usage Example"}),"\n",(0,n.jsx)(o.UW,{children:(0,n.jsx)(e.p,{children:"When adding radial menu items whether they are global or for a sub menu, make sure to stick to short as possible labels\nas long labels will look out of place and should not be used with the radial menu because of its density."})}),"\n",(0,n.jsx)(e.p,{children:"Here's a use case example with some global options and an option utilising the lib's points system."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"exports"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'myMenuHandler'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-parameter)"},children:"menu"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-parameter)"},children:"item"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(menu, item)"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" menu "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu' "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"and"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" item "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Handcuffs'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"registerRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" items "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Handcuff'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'handcuffs'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" onSelect "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'myMenuHandler'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Frisk'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'hand'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Fingerprint'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'fingerprint'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Jail'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'bus'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Search'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'magnifying-glass'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Search'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Police'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'shield-halved'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" menu "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'business_stuff'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Business'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'briefcase'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"Business"'}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" coords "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"GetEntityCoords"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(cache.ped)"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" point "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib.points."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"new"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(coords, "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" point:"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onEnter"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'garage_access'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'warehouse'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Garage'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Garage'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" })"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" point:"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onExit"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"removeRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'garage_access'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})})]})})}),(0,n.jsxs)(o.OK,{children:[(0,n.jsx)(o.UW,{children:(0,n.jsx)(e.p,{children:"Points system in the lib isn't available for the npm package."})}),(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"exports"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'myMenuHandler'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" (menu"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" item) "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=>"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"console"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".log"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(menu"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" item)"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" (menu "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"==="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" and item "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"==="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:") {"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"console"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".log"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Handcuffs'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".registerRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" items"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" ["})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Handcuff'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'handcuffs'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'myMenuHandler'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Frisk'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'hand'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Fingerprint'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'fingerprint'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Jail'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'bus'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Search'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'magnifying-glass'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" () "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=>"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"console"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".log"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Search'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" ]"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(["})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Police'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'shield-halved'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" menu"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'business_stuff'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Business'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'briefcase'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" () "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=>"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"console"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".log"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Business'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"])"})})]})})]})]}),"\n",(0,n.jsxs)(e.p,{children:[(0,n.jsx)(e.img,{src:"https://i.imgur.com/4eYU94s.png",alt:"radial1"}),"\n",(0,n.jsx)(e.img,{src:"https://i.imgur.com/Czw7mLF.png",alt:"radial2"})]})]})}e.default=(0,i.j)({MDXContent:function(){let s=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:e}=Object.assign({},(0,r.a)(),s.components);return e?(0,n.jsx)(e,{...s,children:(0,n.jsx)(c,{...s})}):c(s)},pageOpts:{filePath:"pages/ox_lib/Modules/Interface/Client/radial.mdx",route:"/ox_lib/Modules/Interface/Client/radial",frontMatter:{title:"Radial Menu"},title:"Radial Menu",headings:a},pageNextRoute:"/ox_lib/Modules/Interface/Client/radial"})}},function(s){s.O(0,[2059,9774,2888,179],function(){return s(s.s=7687)}),_N_E=s.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/pages/ox_lib/Modules/Interface/Client/radial-52da50c399d3beff.js b/_next/static/chunks/pages/ox_lib/Modules/Interface/Client/radial-52da50c399d3beff.js deleted file mode 100644 index 5214fa2d4d..0000000000 --- a/_next/static/chunks/pages/ox_lib/Modules/Interface/Client/radial-52da50c399d3beff.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6508],{7687:function(s,e,l){(window.__NEXT_P=window.__NEXT_P||[]).push(["/ox_lib/Modules/Interface/Client/radial",function(){return l(6028)}])},6028:function(s,e,l){"use strict";l.r(e),l.d(e,{__toc:function(){return a}});var n=l(1527),i=l(2059),r=l(3443),o=l(8242);let a=[{depth:2,value:"lib.addRadialItem",id:"libaddradialitem"},{depth:2,value:"lib.removeRadialItem",id:"libremoveradialitem"},{depth:2,value:"lib.clearRadialItems",id:"libclearradialitems"},{depth:2,value:"lib.registerRadial",id:"libregisterradial"},{depth:2,value:"lib.hideRadial",id:"libhideradial"},{depth:2,value:"lib.disableRadial",id:"libdisableradial"},{depth:2,value:"lib.getCurrentRadialId",id:"libgetcurrentradialid"},{depth:2,value:"Usage Example",id:"usage-example"}];function c(s){let e=Object.assign({h1:"h1",ul:"ul",li:"li",code:"code",h2:"h2",p:"p",pre:"pre",span:"span",img:"img"},(0,r.a)(),s.components);return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(e.h1,{children:"Radial Menu"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["Radial menu has a global menu that's by default accessed with ",(0,n.jsx)(e.code,{children:"z"})," and only displays when there is at least one item."]}),"\n",(0,n.jsxs)(e.li,{children:["You can add and remove items from the global menu using ",(0,n.jsx)(e.code,{children:"lib.addRadialItem"})," and ",(0,n.jsx)(e.code,{children:"lib.removeRadialItem"}),"."]}),"\n",(0,n.jsxs)(e.li,{children:["Use ",(0,n.jsx)(e.code,{children:"lib.registerRadial"})," for creating sub menus and use the ",(0,n.jsx)(e.code,{children:"menu"})," property on the items to open those sub menus."]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libaddradialitem",children:"lib.addRadialItem"}),"\n",(0,n.jsx)(e.p,{children:"Item or array of items added to the global radial menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(items)"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(items);"})]})]})})})]}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["items: ",(0,n.jsx)(e.code,{children:"table"})," (",(0,n.jsx)(e.code,{children:"object"})," or ",(0,n.jsx)(e.code,{children:"array"}),")","\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["id: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Id that is used for removing options."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["icon: ",(0,n.jsx)(e.code,{children:"string"})]}),"\n",(0,n.jsxs)(e.li,{children:["label: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["Label uses ",(0,n.jsx)(e.code,{children:" \\n"})," to insert a newline"]}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["menu?: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Id of a menu to open."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["onSelect: ",(0,n.jsx)(e.code,{children:"function(currentMenu: string | nil, itemIndex: number)"})," | ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Function that's ran when a user clicks the item."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["keepOpen?: ",(0,n.jsx)(e.code,{children:"boolean"})]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libremoveradialitem",children:"lib.removeRadialItem"}),"\n",(0,n.jsx)(e.p,{children:"Id of an item to be removed from the global menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"removeRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(item)"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".removeRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(item);"})]})]})})})]}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["id: ",(0,n.jsx)(e.code,{children:"string"})]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libclearradialitems",children:"lib.clearRadialItems"}),"\n",(0,n.jsx)(e.p,{children:"Removes all items from the radial menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"clearRadialItems"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".clearRadialItems"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"();"})]})]})})})]}),"\n",(0,n.jsx)(e.h2,{id:"libregisterradial",children:"lib.registerRadial"}),"\n",(0,n.jsx)(e.p,{children:"Registers a radial sub menu with predefined options."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"registerRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(radial)"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".registerRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(radial);"})]})]})})})]}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["radial: ",(0,n.jsx)(e.code,{children:"table"})," (",(0,n.jsx)(e.code,{children:"object"}),")","\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["id: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["Unique menu id used to open with ",(0,n.jsx)(e.code,{children:"menu"})," prop on an item."]}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["items: ",(0,n.jsx)(e.code,{children:"array"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["icon: ",(0,n.jsx)(e.code,{children:"string"})]}),"\n",(0,n.jsxs)(e.li,{children:["label: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["Label uses ",(0,n.jsx)(e.code,{children:" \\n"})," to insert a newline"]}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["menu?: ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Id of a menu to open."}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(e.li,{children:["onSelect?: ",(0,n.jsx)(e.code,{children:"function(currentMenu: string | nil, itemIndex: number)"})," | ",(0,n.jsx)(e.code,{children:"string"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Function that's ran when a user clicks the item."}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libhideradial",children:"lib.hideRadial"}),"\n",(0,n.jsx)(e.p,{children:"Hides the radial menu if one is open."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"hideRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".hideRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"();"})]})]})})})]}),"\n",(0,n.jsx)(e.h2,{id:"libdisableradial",children:"lib.disableRadial"}),"\n",(0,n.jsx)(e.p,{children:"Disallow players from opening the radial menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"disableRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(state)"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".disableRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(state);"})]})]})})})]}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsxs)(e.li,{children:["state: ",(0,n.jsx)(e.code,{children:"boolean"}),"\n",(0,n.jsxs)(e.ul,{children:["\n",(0,n.jsx)(e.li,{children:"Whether or not radial menu should be disabled"}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(e.h2,{id:"libgetcurrentradialid",children:"lib.getCurrentRadialId"}),"\n",(0,n.jsx)(e.p,{children:"Returns the id of the currently open radial menu."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"getCurrentRadialId"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]})})})}),(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:";"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"let"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".getCurrentRadialId"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"();"})]})]})})})]}),"\n",(0,n.jsx)(e.h2,{id:"usage-example",children:"Usage Example"}),"\n",(0,n.jsx)(o.UW,{children:(0,n.jsx)(e.p,{children:"When adding radial menu items whether they are global or for a sub menu, make sure to stick to short as possible labels\nas long labels will look out of place and should not be used with the radial menu because of its density."})}),"\n",(0,n.jsx)(e.p,{children:"Here's a use case example with some global options and an option utilising the lib's points system."}),"\n",(0,n.jsxs)(o.mQ,{items:["Lua","JS"],children:[(0,n.jsx)(o.OK,{children:(0,n.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"exports"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'myMenuHandler'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-parameter)"},children:"menu"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-parameter)"},children:"item"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(menu, item)"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" menu "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu' "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"and"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" item "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Handcuffs'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"registerRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" items "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Handcuff'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'handcuffs'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" onSelect "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'myMenuHandler'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Frisk'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'hand'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Fingerprint'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'fingerprint'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Jail'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'bus'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Search'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'magnifying-glass'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Search'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Police'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'shield-halved'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" menu "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'business_stuff'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Business'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'briefcase'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"Business"'}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" coords "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"GetEntityCoords"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(cache.ped)"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" point "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib.points."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"new"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(coords, "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"5"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" point:"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onEnter"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'garage_access'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'warehouse'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Garage'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Garage'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" })"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" point:"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onExit"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"removeRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'garage_access'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})})]})})}),(0,n.jsxs)(o.OK,{children:[(0,n.jsx)(o.UW,{children:(0,n.jsx)(e.p,{children:"Points system in the lib isn't available for the npm package."})}),(0,n.jsx)(e.pre,{"data-language":"ts","data-theme":"default",children:(0,n.jsxs)(e.code,{"data-language":"ts","data-theme":"default",children:[(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"import"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"from"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@overextended/ox_lib/client'"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"exports"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'myMenuHandler'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" (menu"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" item) "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=>"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"console"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".log"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(menu"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" item)"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" (menu "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"==="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" and item "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"==="}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:") {"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"console"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".log"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Handcuffs'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".registerRadial"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" items"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" ["})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Handcuff'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'handcuffs'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'myMenuHandler'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Frisk'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'hand'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Fingerprint'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'fingerprint'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Jail'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'bus'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Search'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'magnifying-glass'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" () "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=>"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"console"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".log"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Search'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" ]"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"lib"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".addRadialItem"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(["})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Police'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'shield-halved'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" menu"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'police_menu'"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" id"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'business_stuff'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" label"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Business'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" icon"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'briefcase'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-punctuation)"},children:","})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"onSelect"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:":"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" () "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"=>"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(e.span,{className:"line",children:[(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"console"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:".log"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Business'"}),(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" }"})}),"\n",(0,n.jsx)(e.span,{className:"line",children:(0,n.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"])"})})]})})]})]}),"\n",(0,n.jsxs)(e.p,{children:[(0,n.jsx)(e.img,{src:"https://i.imgur.com/4eYU94s.png",alt:"radial1"}),"\n",(0,n.jsx)(e.img,{src:"https://i.imgur.com/Czw7mLF.png",alt:"radial2"})]})]})}e.default=(0,i.j)({MDXContent:function(){let s=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:e}=Object.assign({},(0,r.a)(),s.components);return e?(0,n.jsx)(e,{...s,children:(0,n.jsx)(c,{...s})}):c(s)},pageOpts:{filePath:"pages/ox_lib/Modules/Interface/Client/radial.mdx",route:"/ox_lib/Modules/Interface/Client/radial",frontMatter:{title:"Radial Menu"},title:"Radial Menu",headings:a},pageNextRoute:"/ox_lib/Modules/Interface/Client/radial"})}},function(s){s.O(0,[2059,9774,2888,179],function(){return s(s.s=7687)}),_N_E=s.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/pages/ox_lib/Modules/Marker/Client-92ef0b2960245e93.js b/_next/static/chunks/pages/ox_lib/Modules/Marker/Client-92ef0b2960245e93.js new file mode 100644 index 0000000000..8df3c42f6a --- /dev/null +++ b/_next/static/chunks/pages/ox_lib/Modules/Marker/Client-92ef0b2960245e93.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[936],{8514:function(s,e,l){(window.__NEXT_P=window.__NEXT_P||[]).push(["/ox_lib/Modules/Marker/Client",function(){return l(8983)}])},8983:function(s,e,l){"use strict";l.r(e),l.d(e,{__toc:function(){return o}});var r=l(1527),n=l(2059),i=l(3443);let o=[{depth:2,value:"lib.marker",id:"libmarker"},{depth:2,value:"Marker Class",id:"marker-class"},{depth:2,value:"lib.marker.new",id:"libmarkernew"},{depth:3,value:"Usage Example",id:"usage-example"},{depth:3,value:"Interactive Example",id:"interactive-example"}];function c(s){let e=Object.assign({h1:"h1",h2:"h2",p:"p",ul:"ul",li:"li",code:"code",a:"a",pre:"pre",span:"span",h3:"h3"},(0,i.a)(),s.components);return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(e.h1,{children:"Client"}),"\n",(0,r.jsx)(e.h2,{id:"libmarker",children:"lib.marker"}),"\n",(0,r.jsx)(e.p,{children:"Simple way to create markers"}),"\n",(0,r.jsx)(e.h2,{id:"marker-class",children:"Marker Class"}),"\n",(0,r.jsx)(e.p,{children:"A table representing a marker with the following properties."}),"\n",(0,r.jsxs)(e.ul,{children:["\n",(0,r.jsxs)(e.li,{children:["type: ",(0,r.jsx)(e.code,{children:"number"})," or ",(0,r.jsx)(e.code,{children:"string"}),"\n",(0,r.jsxs)(e.ul,{children:["\n",(0,r.jsxs)(e.li,{children:["This field accepts either a numerical value representing the marker ID or a string containing the name of a marker as documented on ",(0,r.jsx)(e.a,{href:"https://docs.fivem.net/docs/game-references/markers/",children:"FiveM Docs"}),"."]}),"\n"]}),"\n"]}),"\n",(0,r.jsxs)(e.li,{children:["coords?: ",(0,r.jsx)(e.code,{children:"vector3"})]}),"\n",(0,r.jsxs)(e.li,{children:["width?: ",(0,r.jsx)(e.code,{children:"number"})]}),"\n",(0,r.jsxs)(e.li,{children:["height?: ",(0,r.jsx)(e.code,{children:"number"})]}),"\n",(0,r.jsxs)(e.li,{children:["color?: ",(0,r.jsx)(e.code,{children:"{ r: number, g: number, b: number, a: number}"})]}),"\n",(0,r.jsxs)(e.li,{children:["direction?: ",(0,r.jsx)(e.code,{children:"vector3"})]}),"\n",(0,r.jsxs)(e.li,{children:["rotation?: ",(0,r.jsx)(e.code,{children:"vector3"})]}),"\n"]}),"\n",(0,r.jsx)(e.h2,{id:"libmarkernew",children:"lib.marker.new"}),"\n",(0,r.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,r.jsx)(e.code,{"data-language":"lua","data-theme":"default",children:(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"lib.marker."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"new"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(options)"})]})})}),"\n",(0,r.jsxs)(e.ul,{children:["\n",(0,r.jsxs)(e.li,{children:["Returns: ",(0,r.jsx)(e.code,{children:"Marker"})]}),"\n"]}),"\n",(0,r.jsx)(e.h3,{id:"usage-example",children:"Usage Example"}),"\n",(0,r.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,r.jsxs)(e.code,{"data-language":"lua","data-theme":"default",children:[(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" marker "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib.marker."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"new"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" type "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" coords "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"GetEntityCoords"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(cache.ped),"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" color "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" { r "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"255"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:", g "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"0"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:", b "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"0"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:", a "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"200"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" },"})]}),"\n",(0,r.jsx)(e.span,{className:"line",children:(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,r.jsx)(e.span,{className:"line",children:" "}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"Citizen."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"CreateThread"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"while"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"true"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"do"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" marker:"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"draw"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,r.jsx)(e.span,{className:"line",children:" "}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" Citizen."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"Wait"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,r.jsx)(e.h3,{id:"interactive-example",children:"Interactive Example"}),"\n",(0,r.jsx)(e.pre,{"data-language":"lua","data-theme":"default",children:(0,r.jsxs)(e.code,{"data-language":"lua","data-theme":"default",children:[(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" point "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib.points."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"new"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" coords "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" SharedConfig.Warehouse.coords,"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" distance "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"20"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,r.jsx)(e.span,{className:"line",children:(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,r.jsx)(e.span,{className:"line",children:" "}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" marker "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib.marker."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"new"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" coords "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"GetEntityCoords"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"(SharedConfig.Warehouse.coords),"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" type "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"1"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,r.jsx)(e.span,{className:"line",children:(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"})"})}),"\n",(0,r.jsx)(e.span,{className:"line",children:" "}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"function"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" point:"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"nearby"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" marker:"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"draw"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,r.jsx)(e.span,{className:"line",children:" "}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" self.currentDistance "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"<"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"1.5"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"not"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"isTextUIOpen"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"() "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"showTextUI"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"Press [E] to get notified"'}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,r.jsx)(e.span,{className:"line",children:" "}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"IsControlJustPressed"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"0"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:", "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-constant)"},children:"51"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:") "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"notify"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"({"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" description "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"Hello, World!"'})]}),"\n",(0,r.jsx)(e.span,{className:"line",children:(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" })"})}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"else"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"if"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"isTextUIOpen"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"() "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"then"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-function)"},children:"hideTextUI"}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:"()"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,r.jsxs)(e.span,{className:"line",children:[(0,r.jsx)(e.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})]}),"\n",(0,r.jsx)(e.span,{className:"line",children:(0,r.jsx)(e.span,{style:{color:"var(--shiki-token-keyword)"},children:"end"})})]})})]})}e.default=(0,n.j)({MDXContent:function(){let s=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:e}=Object.assign({},(0,i.a)(),s.components);return e?(0,r.jsx)(e,{...s,children:(0,r.jsx)(c,{...s})}):c(s)},pageOpts:{filePath:"pages/ox_lib/Modules/Marker/Client.mdx",route:"/ox_lib/Modules/Marker/Client",title:"Client",headings:o},pageNextRoute:"/ox_lib/Modules/Marker/Client"})}},function(s){s.O(0,[2059,9774,2888,179],function(){return s(s.s=8514)}),_N_E=s.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/pages/ox_lib/Modules/Require/Shared-0151ce18c505673e.js b/_next/static/chunks/pages/ox_lib/Modules/Require/Shared-0151ce18c505673e.js new file mode 100644 index 0000000000..8925ad1ab4 --- /dev/null +++ b/_next/static/chunks/pages/ox_lib/Modules/Require/Shared-0151ce18c505673e.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9982],{5060:function(e,s,l){(window.__NEXT_P=window.__NEXT_P||[]).push(["/ox_lib/Modules/Require/Shared",function(){return l(1876)}])},1876:function(e,s,l){"use strict";l.r(s),l.d(s,{__toc:function(){return o}});var n=l(1527),a=l(2059),r=l(3443),i=l(8242);let o=[{depth:2,value:"require",id:"require"},{depth:3,value:"Usage Example",id:"usage-example"},{depth:2,value:"lib.load",id:"libload"},{depth:3,value:"Usage Example",id:"usage-example-1"},{depth:2,value:"lib.loadJson",id:"libloadjson"},{depth:3,value:"Usage Example",id:"usage-example-2"}];function t(e){let s=Object.assign({h1:"h1",p:"p",em:"em",h2:"h2",code:"code",ul:"ul",li:"li",pre:"pre",span:"span",h3:"h3"},(0,r.a)(),e.components);return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(s.h1,{children:"Shared"}),"\n",(0,n.jsx)(s.p,{children:(0,n.jsx)(s.em,{children:"This module is always loaded by default."})}),"\n",(0,n.jsx)(s.h2,{id:"require",children:"require"}),"\n",(0,n.jsxs)(s.p,{children:["Loads the given module. The function starts by indexing the ",(0,n.jsx)(s.code,{children:"loaded"})," table to determine whether ",(0,n.jsx)(s.code,{children:"modname"})," is already loaded. If it is, then ",(0,n.jsx)(s.code,{children:"require"})," returns the value stored at ",(0,n.jsx)(s.code,{children:"loaded[modname]"}),"."]}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsx)(s.li,{children:"Module names are the path to a file relative to the resource."}),"\n",(0,n.jsxs)(s.li,{children:["The module name must point to a ",(0,n.jsx)(s.code,{children:".lua"})," file."]}),"\n",(0,n.jsxs)(s.li,{children:["Use ",(0,n.jsx)(s.code,{children:"."})," to separate directories in a path."]}),"\n",(0,n.jsxs)(s.li,{children:["Modules can be loaded from external resources using ",(0,n.jsx)(s.code,{children:"@resource.modname"}),"."]}),"\n"]}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"require"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'modname'"})]})})}),"\n",(0,n.jsxs)(i.UW,{type:"warning",children:[(0,n.jsxs)(s.p,{children:["Client modules must be defined in the ",(0,n.jsx)(s.code,{children:"file"})," section of the resource manifest."]}),(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"fxmanifest.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"file"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'modname.lua'"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-comment)"},children:"-- or"})}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"files"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'modname.lua'"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})})]})})]}),"\n",(0,n.jsx)(s.h3,{id:"usage-example",children:"Usage Example"}),"\n",(0,n.jsx)(s.pre,{"data-language":"text","data-theme":"default",children:(0,n.jsxs)(s.code,{"data-language":"text","data-theme":"default",children:[(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"- resources/"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - mylib/"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - import.lua"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - data/"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - events.lua"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - myresource/"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - server.lua"})})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"mylib/import.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" mylib "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" events "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"require"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'data.events'"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Loaded mylib'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" mylib"})]})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"mylib/data/events.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" disconnect "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'onPlayerDropped'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"myresource/server.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" mylib "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"require"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@mylib.import'"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(mylib.events.disconnect)"})]})]})}),"\n",(0,n.jsx)(s.h2,{id:"libload",children:"lib.load"}),"\n",(0,n.jsx)(s.p,{children:"Loads and runs a Lua file at the given path. Unlike require, the chunk is not cached for future use."}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"load"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(filePath, env)"})]})})}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["filePath: ",(0,n.jsx)(s.code,{children:"string"}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["A path to the Lua file, using the same rules as ",(0,n.jsx)(s.code,{children:"require"}),"."]}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(s.li,{children:["env?: ",(0,n.jsx)(s.code,{children:"table"}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["A table to use as the global environment, defaulting to ",(0,n.jsx)(s.code,{children:"_ENV"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(s.h3,{id:"usage-example-1",children:"Usage Example"}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"myresource/import.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" events "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"load"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'data.events'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Loaded events'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"myresource/data/events.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" disconnect "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'onPlayerDropped'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})})]})}),"\n",(0,n.jsx)(s.h2,{id:"libloadjson",children:"lib.loadJson"}),"\n",(0,n.jsx)(s.p,{children:"Loads a JSON file at the given path and decodes it as a table."}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"loadJson"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(filePath)"})]})})}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["filePath: ",(0,n.jsx)(s.code,{children:"string"}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["A path to the Lua file, using the same rules as ",(0,n.jsx)(s.code,{children:"require"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(s.h3,{id:"usage-example-2",children:"Usage Example"}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"myresource/import.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" events "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"loadJson"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'data.events'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Loaded events'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"json","data-theme":"default",filename:"myresource/data/events.json",children:(0,n.jsxs)(s.code,{"data-language":"json","data-theme":"default",children:[(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"{"})}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:'"disconnect"'}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-punctuation)"},children:":"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"onPlayerDropped"'})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})})]})})]})}s.default=(0,a.j)({MDXContent:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:s}=Object.assign({},(0,r.a)(),e.components);return s?(0,n.jsx)(s,{...e,children:(0,n.jsx)(t,{...e})}):t(e)},pageOpts:{filePath:"pages/ox_lib/Modules/Require/Shared.mdx",route:"/ox_lib/Modules/Require/Shared",title:"Shared",headings:o},pageNextRoute:"/ox_lib/Modules/Require/Shared"})}},function(e){e.O(0,[2059,9774,2888,179],function(){return e(e.s=5060)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/pages/ox_lib/Modules/Require/Shared-6fd9540795b07659.js b/_next/static/chunks/pages/ox_lib/Modules/Require/Shared-6fd9540795b07659.js deleted file mode 100644 index a2aaabcf36..0000000000 --- a/_next/static/chunks/pages/ox_lib/Modules/Require/Shared-6fd9540795b07659.js +++ /dev/null @@ -1 +0,0 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9982],{5060:function(e,s,l){(window.__NEXT_P=window.__NEXT_P||[]).push(["/ox_lib/Modules/Require/Shared",function(){return l(1876)}])},1876:function(e,s,l){"use strict";l.r(s),l.d(s,{__toc:function(){return i}});var n=l(1527),a=l(2059),r=l(3443);let i=[{depth:2,value:"require",id:"require"},{depth:3,value:"Usage Example",id:"usage-example"},{depth:2,value:"lib.load",id:"libload"},{depth:3,value:"Usage Example",id:"usage-example-1"},{depth:2,value:"lib.loadJson",id:"libloadjson"},{depth:3,value:"Usage Example",id:"usage-example-2"}];function o(e){let s=Object.assign({h1:"h1",p:"p",em:"em",h2:"h2",code:"code",ul:"ul",li:"li",pre:"pre",span:"span",h3:"h3"},(0,r.a)(),e.components);return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(s.h1,{children:"Shared"}),"\n",(0,n.jsx)(s.p,{children:(0,n.jsx)(s.em,{children:"This module is always loaded by default."})}),"\n",(0,n.jsx)(s.h2,{id:"require",children:"require"}),"\n",(0,n.jsxs)(s.p,{children:["Loads the given module. The function starts by indexing the ",(0,n.jsx)(s.code,{children:"loaded"})," table to determine whether ",(0,n.jsx)(s.code,{children:"modname"})," is already loaded. If it is, then ",(0,n.jsx)(s.code,{children:"require"})," returns the value stored at ",(0,n.jsx)(s.code,{children:"loaded[modname]"}),"."]}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsx)(s.li,{children:"Module names are the path to a file relative to the resource."}),"\n",(0,n.jsxs)(s.li,{children:["The module name must point to a ",(0,n.jsx)(s.code,{children:".lua"})," file."]}),"\n",(0,n.jsxs)(s.li,{children:["Use ",(0,n.jsx)(s.code,{children:"."})," to separate directories in a path."]}),"\n",(0,n.jsxs)(s.li,{children:["Modules can be loaded from external resources using ",(0,n.jsx)(s.code,{children:"@resource.modname"}),"."]}),"\n"]}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"require"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'modname'"})]})})}),"\n",(0,n.jsx)(s.h3,{id:"usage-example",children:"Usage Example"}),"\n",(0,n.jsx)(s.pre,{"data-language":"text","data-theme":"default",children:(0,n.jsxs)(s.code,{"data-language":"text","data-theme":"default",children:[(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"- resources/"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - mylib/"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - import.lua"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - data/"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - events.lua"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - myresource/"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" - server.lua"})})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"mylib/import.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" mylib "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" events "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"require"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'data.events'"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})}),"\n",(0,n.jsx)(s.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Loaded mylib'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" mylib"})]})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"mylib/data/events.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" disconnect "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'onPlayerDropped'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"myresource/server.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" mylib "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"require"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'@mylib.import'"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(mylib.events.disconnect)"})]})]})}),"\n",(0,n.jsx)(s.h2,{id:"libload",children:"lib.load"}),"\n",(0,n.jsx)(s.p,{children:"Loads and runs a Lua file at the given path. Unlike require, the chunk is not cached for future use."}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"load"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(filePath, env)"})]})})}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["filePath: ",(0,n.jsx)(s.code,{children:"string"}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["A path to the Lua file, using the same rules as ",(0,n.jsx)(s.code,{children:"require"}),"."]}),"\n"]}),"\n"]}),"\n",(0,n.jsxs)(s.li,{children:["env?: ",(0,n.jsx)(s.code,{children:"table"}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["A table to use as the global environment, defaulting to ",(0,n.jsx)(s.code,{children:"_ENV"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(s.h3,{id:"usage-example-1",children:"Usage Example"}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"myresource/import.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" events "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"load"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'data.events'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Loaded events'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"myresource/data/events.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"return"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" {"})]}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" disconnect "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'onPlayerDropped'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:","})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})})]})}),"\n",(0,n.jsx)(s.h2,{id:"libloadjson",children:"lib.loadJson"}),"\n",(0,n.jsx)(s.p,{children:"Loads a JSON file at the given path and decodes it as a table."}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",children:(0,n.jsx)(s.code,{"data-language":"lua","data-theme":"default",children:(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"lib."}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"loadJson"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"(filePath)"})]})})}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["filePath: ",(0,n.jsx)(s.code,{children:"string"}),"\n",(0,n.jsxs)(s.ul,{children:["\n",(0,n.jsxs)(s.li,{children:["A path to the Lua file, using the same rules as ",(0,n.jsx)(s.code,{children:"require"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,n.jsx)(s.h3,{id:"usage-example-2",children:"Usage Example"}),"\n",(0,n.jsx)(s.pre,{"data-language":"lua","data-theme":"default",filename:"myresource/import.lua",children:(0,n.jsxs)(s.code,{"data-language":"lua","data-theme":"default",children:[(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"local"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" events "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:"="}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" lib."}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"load"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'data.events'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:" "}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-function)"},children:"print"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"("}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:"'Loaded events'"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:")"})]})]})}),"\n",(0,n.jsx)(s.pre,{"data-language":"json","data-theme":"default",filename:"myresource/data/events.json",children:(0,n.jsxs)(s.code,{"data-language":"json","data-theme":"default",children:[(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"{"})}),"\n",(0,n.jsxs)(s.span,{className:"line",children:[(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-keyword)"},children:'"disconnect"'}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-punctuation)"},children:":"}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:" "}),(0,n.jsx)(s.span,{style:{color:"var(--shiki-token-string-expression)"},children:'"onPlayerDropped"'})]}),"\n",(0,n.jsx)(s.span,{className:"line",children:(0,n.jsx)(s.span,{style:{color:"var(--shiki-color-text)"},children:"}"})})]})})]})}s.default=(0,a.j)({MDXContent:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:s}=Object.assign({},(0,r.a)(),e.components);return s?(0,n.jsx)(s,{...e,children:(0,n.jsx)(o,{...e})}):o(e)},pageOpts:{filePath:"pages/ox_lib/Modules/Require/Shared.mdx",route:"/ox_lib/Modules/Require/Shared",title:"Shared",headings:i},pageNextRoute:"/ox_lib/Modules/Require/Shared"})}},function(e){e.O(0,[2059,9774,2888,179],function(){return e(e.s=5060)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/guides/git.html b/guides/git.html index 98acee31a0..a072b6fc93 100644 --- a/guides/git.html +++ b/guides/git.html @@ -11,10 +11,10 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
Guides
Git

Git

+
Guides
Git

Git

Git is a version control system, allowing changes to be effectively tracked, merged, and reverted.

As our resources are hosted on GitHub, it can be incredibly useful to learn how to create your own repository to track changes and keep up-to-date. If you plan on making your own changes to our resources, this will allow you to keep your own changes and prevent loss of data.


Overextended
\ No newline at end of file +

Overextended
\ No newline at end of file diff --git a/guides/nodejs.html b/guides/nodejs.html index f5620dd28f..b545da9a2b 100644 --- a/guides/nodejs.html +++ b/guides/nodejs.html @@ -11,10 +11,10 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
Guides
Node.js

Node.js

+
Guides
Node.js

Node.js

Node.js is a JavaScript runtime and is used for building applications. In the context of FiveM it is necessary to bundle resources into a single package that can be ran on both the server and client.

  • Download (opens in a new tab) and install the LTS version of Node.js.
  • Open a command-line terminal (e.g. Terminal, Command Prompt).
  • Enter node --version to confirm successful installation.
  • -

Overextended
\ No newline at end of file +

Overextended
\ No newline at end of file diff --git a/guides/pnpm.html b/guides/pnpm.html index f3e8c60d15..cfb6cd13b7 100644 --- a/guides/pnpm.html +++ b/guides/pnpm.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
Guides
pnpm

pnpm

+
Guides
pnpm

pnpm

pnpm is a fast and disk space efficient package manager, serving as an alternative to npm and yarn.

  • Ensure you have installed Node.js.
  • @@ -27,4 +27,4 @@ "preview": "vite preview", "format": "prettier --write \"./src/**/*.{ts,tsx,css}\"" },
-

Using the example above pnpm build will run the build script for the given package.


Overextended
\ No newline at end of file +

Using the example above pnpm build will run the build script for the given package.


Overextended
\ No newline at end of file diff --git a/guides/types.html b/guides/types.html index f1cb36462e..3e8ce547d3 100644 --- a/guides/types.html +++ b/guides/types.html @@ -11,8 +11,8 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
Guides
Types

Setup git, vscode, and vscode extensions

Download our Lua type definitions

git clone https://github.com/overextended/ox_types.git`

Update your settings

You can modify the user, workspace, or folder settings for vscode.
+

Guides
Types

Setup git, vscode, and vscode extensions

Download our Lua type definitions

git clone https://github.com/overextended/ox_types.git`

Update your settings

You can modify the user, workspace, or folder settings for vscode.
Create an entry in Lua.workspace.library pointing to the cloned directory, or specific subdirectories.

"Lua.workspace.library": [
     "F:/GitHub/ox_types/types",
     "F:/GitHub/ox_lib"
-],

Overextended
\ No newline at end of file +],

Overextended
\ No newline at end of file diff --git a/guides/vscode.html b/guides/vscode.html index 1c7af1b4c9..f31b47724e 100644 --- a/guides/vscode.html +++ b/guides/vscode.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
Guides
VS Code

VS Code

+

Overextended
\ No newline at end of file +

Overextended
\ No newline at end of file diff --git a/index.html b/index.html index 7f09d210d5..b1a48b1d00 100644 --- a/index.html +++ b/index.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
Introduction

Introduction

+
Introduction

Introduction

Here you can find all of the official documentation for resources developed by the Overextended team.

If you feel like the documentation is lacking in some department then feel free to go onto that page and click the "Edit this page" at the bottom and submit a Pull Request.

Support our team

@@ -25,5 +25,6 @@

We trust that customers will be given assistance.
  • The creator is a known member of our community.
  • -
    StoreCodeDiscountLink
    Andyyyox2020%https://andyyy.tebex.io/ (opens in a new tab)
    Berkie's Workshopox1010%https://berkie.tebex.io/ (opens in a new tab)
    Dolu Modsoverextended15%https://dolu.tebex.io/ (opens in a new tab)
    Electus Scriptsox1010%https://store.electus-scripts.com/ (opens in a new tab)
    Loaf Scriptsox55%https://store.loaf-scripts.com/ (opens in a new tab)
    OT Studiosox1010%https://store.otstudios.net/ox (opens in a new tab)
    rcore0x1010%https://store.rcore.cz/ (opens in a new tab)
    Wasabi ScriptsOX2020%https://store.wasabiscripts.com/ (opens in a new tab)
    -

    You can apply a creator code at checkout under "Support A Creator".


    Overextended
    \ No newline at end of file +

    More information about these creators is available in our Discord (opens in a new tab).

    +
    StoreCodeDiscountLink
    Andyyyox2020%https://andyyy.tebex.io/ (opens in a new tab)
    Berkie's Workshopox1010%https://berkie.tebex.io/ (opens in a new tab)
    Dolu Modsoverextended15%https://dolu.tebex.io/ (opens in a new tab)
    Electus Scriptsox1010%https://store.electus-scripts.com/ (opens in a new tab)
    Loaf Scriptsox55%https://store.loaf-scripts.com/ (opens in a new tab)
    OT Studiosox1010%https://store.otstudios.net/ox (opens in a new tab)
    Pickle Modsox3030%https://store.picklemods.com/ (opens in a new tab)
    rcoreox1010%https://store.rcore.cz/ (opens in a new tab)
    Roleplay inventory iconsox1010%https://pixel-art-roleplay-inventory-i.tebex.io/ (opens in a new tab)
    Renewed Scriptsox1515%https://renewed.tebex.io/ (opens in a new tab)
    Wasabi ScriptsOX2020%https://store.wasabiscripts.com/ (opens in a new tab)
    +

    You can apply a creator code at checkout under "Support A Creator".


    Overextended
    \ No newline at end of file diff --git a/ox_core.html b/ox_core.html index 4e869334d9..af42289fd7 100644 --- a/ox_core.html +++ b/ox_core.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Ox Core

    Ox Core

    +
    Ox Core

    Ox Core

    An experimental framework for FiveM. Limited support and breaking changes guaranteed.

    ⚠️

    This resource does not have a stable (v1.0) release; breaking changes are likely.
    @@ -66,4 +66,4 @@

    setr ox:deathSystem 0 # Disable the spawn selection. -setr ox:spawnSelect 0


    Overextended
    \ No newline at end of file +setr ox:spawnSelect 0

    Overextended
    \ No newline at end of file diff --git a/ox_core/Client/Player.html b/ox_core/Client/Player.html index cd9a080629..95cd252588 100644 --- a/ox_core/Client/Player.html +++ b/ox_core/Client/Player.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Client
    Player

    Client

    +
    Client
    Player

    Client

    When ox_core is imported into a resource it will create the player global.
    If player is nil, then the client has not yet selected a character and spawned.

    Example:

    @@ -28,4 +28,4 @@
  • groups: table
  • -

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_core/Client/Player/callbacks.html b/ox_core/Client/Player/callbacks.html index 035613848e..21bc06d686 100644 --- a/ox_core/Client/Player/callbacks.html +++ b/ox_core/Client/Player/callbacks.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Client
    Callbacks

    Callbacks

    +
    Client
    Callbacks

    Callbacks

    ox:getStatus

    lib.callback.await('ox:getStatus', delay, targetId, statusName)
      @@ -51,4 +51,4 @@

      The radius from the player's location to return vehicles.

    -

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_core/Client/Player/events.html b/ox_core/Client/Player/events.html index 2010540294..381445a2c2 100644 --- a/ox_core/Client/Player/events.html +++ b/ox_core/Client/Player/events.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Client
    Events

    Events

    +
    Client
    Events

    Events

    Client events

    ox:playerLoaded

    Triggered once the player has selected a character and spawned.

    @@ -34,4 +34,4 @@

    RegisterNetEvent('ox:licenseAdded', function(name) end)

    ox:licenseRemoved

    Triggered when the player's license is revoked.

    -
    RegisterNetEvent('ox:licenseRemoved', function(name) end)

    Overextended
    \ No newline at end of file +
    RegisterNetEvent('ox:licenseRemoved', function(name) end)

    Overextended
    \ No newline at end of file diff --git a/ox_core/Client/functions.html b/ox_core/Client/functions.html index c7b21da63b..104bbd13d9 100644 --- a/ox_core/Client/functions.html +++ b/ox_core/Client/functions.html @@ -11,5 +11,5 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_core/Server/Player.html b/ox_core/Server/Player.html index ee5722f53a..f3014a8495 100644 --- a/ox_core/Server/Player.html +++ b/ox_core/Server/Player.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Player

    Server

    +
    Server
    Player

    Server

    Ox.GetPlayer

    Return an instance of OxPlayer for the given player source.

    local player = Ox.GetPlayer(source)
    @@ -45,4 +45,4 @@ 

    for i = 1, #players do local player = players[i] print(json.encode(player, { indent = true })) -end


    Overextended
    \ No newline at end of file +end

    Overextended
    \ No newline at end of file diff --git a/ox_core/Server/Player/events.html b/ox_core/Server/Player/events.html index 7104526db2..da2dee9081 100644 --- a/ox_core/Server/Player/events.html +++ b/ox_core/Server/Player/events.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Events

    Events

    +
    Server
    Events

    Events

    Server events

    ox:playerLoaded

    Triggered after a player has selected a character.

    @@ -37,4 +37,4 @@

    RegisterNetEvent('ox:playerDeath', function(isDead) end)

    ox:setPlayerInService

    Can be triggered to set a player as "in service" for a specific group they are a member of.

    -
    RegisterNetEvent('ox:setPlayerInService', function(group) end)

    Overextended
    \ No newline at end of file +
    RegisterNetEvent('ox:setPlayerInService', function(group) end)

    Overextended
    \ No newline at end of file diff --git a/ox_core/Server/Player/methods.html b/ox_core/Server/Player/methods.html index 6a7e757d39..2f38b07843 100644 --- a/ox_core/Server/Player/methods.html +++ b/ox_core/Server/Player/methods.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Methods

    Methods

    +
    Server
    Methods

    Methods

    These functions are inherited from the Player class.

    player.set

    Update the player's metadata, optionally syncing it with the client.

    @@ -109,4 +109,4 @@

  • eventName: string
  • ...?: any[]
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_core/Server/Vehicle.html b/ox_core/Server/Vehicle.html index 8dd72eafcc..90dd77444e 100644 --- a/ox_core/Server/Vehicle.html +++ b/ox_core/Server/Vehicle.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Server

    Server

    +
    Server
    Server

    Server

    Ox.GetVehicle

    Return an instance of OxVehicle for the given entity.

    local vehicle = Ox.GetVehicle(entity)
    @@ -42,4 +42,4 @@ 

    local vehicle = Ox.CreateVehicle({
         model = 'sultanrs',
         owner = player.charid,
    -}, player.getCoords(), GetEntityHeading(player.ped))


    Overextended
    \ No newline at end of file +}, player.getCoords(), GetEntityHeading(player.ped))

    Overextended
    \ No newline at end of file diff --git a/ox_core/Server/Vehicle/callbacks.html b/ox_core/Server/Vehicle/callbacks.html index 4a0f592d33..13fcc0acc8 100644 --- a/ox_core/Server/Vehicle/callbacks.html +++ b/ox_core/Server/Vehicle/callbacks.html @@ -11,11 +11,11 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Callbacks

    Callbacks

    +
    Server
    Callbacks

    Callbacks

    ox:getNearbyVehicles

    Get all vehicles within range of the target player.

    lib.callback.await('ox:getNearbyVehicles', playerId, radius)
    • playerId: number
    • radius?: number
    • -

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_core/Server/Vehicle/methods.html b/ox_core/Server/Vehicle/methods.html index e256ba09b5..4875285472 100644 --- a/ox_core/Server/Vehicle/methods.html +++ b/ox_core/Server/Vehicle/methods.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Methods

    Methods

    +
    Server
    Methods

    Methods

    These functions are inherited from the Vehicle class.

    vehicle.set

    Sets the vehicle's metadata for key to the given value.

    @@ -62,4 +62,4 @@

    vehicle.setPlate(plate)

    • plate: string
    • -

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_core/Server/functions.html b/ox_core/Server/functions.html index 76c80970c2..46f143ea49 100644 --- a/ox_core/Server/functions.html +++ b/ox_core/Server/functions.html @@ -11,5 +11,5 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_core/concepts.html b/ox_core/concepts.html index d10cb495e7..58cea906f5 100644 --- a/ox_core/concepts.html +++ b/ox_core/concepts.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Concepts

    Concepts

    +
    Concepts

    Concepts

    We'll try to explain some technical but core concepts used in ox_core here.

    Classes

    Lua doesn't have support for true classes, but rather prototype-based inheritance.
    @@ -46,4 +46,4 @@

    print(username)

    When using the imported classes in your resources you can treat the methods as if you are calling a regular function.

    local player = Ox.GetPlayer(playerId)
    -print(player.getUsername())

    Overextended
    \ No newline at end of file +print(player.getUsername())

    Overextended
    \ No newline at end of file diff --git a/ox_doorlock.html b/ox_doorlock.html index 82fd904c08..3711f19c6b 100644 --- a/ox_doorlock.html +++ b/ox_doorlock.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Ox Doorlock

    Ox Doorlock

    +
    Ox Doorlock

    Ox Doorlock

    A door management resource that can be used standalone or alongside ox_core, qb-core, and es_extended.

    Installation

    @@ -46,4 +46,4 @@

    Conversion cannot be guaranteed, especially if the config was not written for nui_doorlock.

    Adding new native audio

    -

    A guide can be found here (opens in a new tab) for adding new native audio.


    Overextended
    \ No newline at end of file +

    A guide can be found here (opens in a new tab) for adding new native audio.


    Overextended
    \ No newline at end of file diff --git a/ox_doorlock/Client/functions.html b/ox_doorlock/Client/functions.html index a91997ac18..d53a09d4b9 100644 --- a/ox_doorlock/Client/functions.html +++ b/ox_doorlock/Client/functions.html @@ -11,10 +11,10 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Client
    Functions

    Functions

    +
    Client
    Functions

    Functions

    pickClosestDoor

    Attempt to pick the lock of the closest door. Dependant on server-side checks and may fail.

    exports.ox_doorlock:pickClosestDoor()

    useClosestDoor

    Interact with the closest door. Dependant on server-side checks and may fail.

    -
    exports.ox_doorlock:useClosestDoor()

    Overextended
    \ No newline at end of file +
    exports.ox_doorlock:useClosestDoor()

    Overextended
    \ No newline at end of file diff --git a/ox_doorlock/Server/events.html b/ox_doorlock/Server/events.html index fe905cc846..db106d7127 100644 --- a/ox_doorlock/Server/events.html +++ b/ox_doorlock/Server/events.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Events

    Events

    +
    Server
    Events

    Events

    Handlers

    These events should not be triggered by any other scripts.

    ox_doorlock:stateChanged

    @@ -22,4 +22,4 @@

    doorId: number
  • state: boolean
  • usedItem: string or false or nil
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_doorlock/Server/functions.html b/ox_doorlock/Server/functions.html index ad3a09f804..060a025f48 100644 --- a/ox_doorlock/Server/functions.html +++ b/ox_doorlock/Server/functions.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Functions

    Functions

    +
    Server
    Functions

    Functions

    Gets data for a door with the given id, matching the id for the database entry.

    getDoor

    exports.ox_doorlock:getDoor(doorId)
    @@ -46,4 +46,4 @@

  • doorId: number
  • state: 0 or 1 or boolean
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_doorlock/settings.html b/ox_doorlock/settings.html index d91dacfece..fef1061440 100644 --- a/ox_doorlock/settings.html +++ b/ox_doorlock/settings.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Door Settings

    Door Settings

    +
    Door Settings

    Door Settings

    General

    • Door name @@ -140,4 +140,4 @@

      Note: Sounds are stored in the ./web/public/sounds directory.


    Overextended
    \ No newline at end of file +

    Note: Sounds are stored in the ./web/public/sounds directory.


    Overextended
    \ No newline at end of file diff --git a/ox_fuel.html b/ox_fuel.html index 1c6dba8354..3dc908c0c3 100644 --- a/ox_fuel.html +++ b/ox_fuel.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Ox Fuel

    Ox Fuel

    +
    Ox Fuel

    Ox Fuel

    A simple fuel resource meant to replace LegacyFuel or serve as a showcase for using petrol cans as an item.

    Installation

    @@ -20,4 +20,4 @@

    ox_inventory

    Download a release (opens in a new tab) or clone the source code.

    git clone https://github.com/overextended/ox_fuel.git

    Install optional dependencies.

    These resources aren't required but provide additional functionality.


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_fuel/Client/functions.html b/ox_fuel/Client/functions.html index b1bf7f9b90..3656deff6e 100644 --- a/ox_fuel/Client/functions.html +++ b/ox_fuel/Client/functions.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Client
    Functions

    Functions

    +

    Overextended
    \ No newline at end of file +end)

    Overextended
    \ No newline at end of file diff --git a/ox_fuel/Server/functions.html b/ox_fuel/Server/functions.html index f92e5f44b0..d07f531095 100644 --- a/ox_fuel/Server/functions.html +++ b/ox_fuel/Server/functions.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Server
    Functions

    Functions

    +
    Server
    Functions

    Functions

    setPaymentMethod

    Override the built-in payment method.

    exports.ox_fuel:setPaymentMethod(method)
    @@ -33,4 +33,4 @@

    type = 'error', description = locale('not_enough_money', amount - bankAmount) }) -end)


    Overextended
    \ No newline at end of file +end)

    Overextended
    \ No newline at end of file diff --git a/ox_fuel/Shared.html b/ox_fuel/Shared.html index 3e04eaab4b..392fea9744 100644 --- a/ox_fuel/Shared.html +++ b/ox_fuel/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Shared

    Get vehicle fuel amount

    +
    Shared

    Get vehicle fuel amount

    local fuel = Entity(vehicleId).state.fuel

    Set vehicle fuel amount

    -
    Entity(vehicleId).state.fuel = fuelAmount

    Overextended
    \ No newline at end of file +
    Entity(vehicleId).state.fuel = fuelAmount

    Overextended
    \ No newline at end of file diff --git a/ox_inventory.html b/ox_inventory.html index 36884ab8fe..b16ca43cf3 100644 --- a/ox_inventory.html +++ b/ox_inventory.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Ox Inventory

    Ox Inventory

    +
    Ox Inventory

    Ox Inventory

    A slot-based inventory with item metadata for "item uniqueness".

    ⚠️

    If you are replacing a built-in framework inventory there will be compatibility errors.
    @@ -190,4 +190,4 @@

    Improved security and performance of qb resources.
  • Integrated support for ox_inventory, with improved compatibility.
  • Support for ox_lib and ox_target.
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Events/Client.html b/ox_inventory/Events/Client.html index 63db1d1e2f..e650d0e6fb 100644 --- a/ox_inventory/Events/Client.html +++ b/ox_inventory/Events/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Events
    Client

    Client

    +
    Events
    Client

    Client

    This is not a comprehensive list of events and is missing events intended for internal use only.

    Event Triggers

    These events are safe to trigger and handle in other scripts.

    @@ -62,4 +62,4 @@

    name: string
  • slotId: number
  • metadata?: table
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Events/Server.html b/ox_inventory/Events/Server.html index 965fec6ff4..0f7be82e13 100644 --- a/ox_inventory/Events/Server.html +++ b/ox_inventory/Events/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Events
    Server

    Server

    +
    Events
    Server

    Server

    This is not a comprehensive list of events and is missing events intended for internal use only.

    Handlers

    ⚠️

    These events should not be triggered by any other scripts.

    @@ -32,4 +32,4 @@

    name: string
  • slotId: number
  • metadata?: table
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Frameworks/esx.html b/ox_inventory/Frameworks/esx.html index 79c792f719..1324ef1914 100644 --- a/ox_inventory/Frameworks/esx.html +++ b/ox_inventory/Frameworks/esx.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Frameworks
    ESX

    ESX

    +
    Frameworks
    ESX

    ESX

    Compatibility

    Ox Inventory is a complete replacement for existing item, inventory, and weapon systems; it is inherently incompatible with ESX and any resources that rely on default behaviour.

      @@ -43,4 +43,4 @@

      xPlayer.removeInventoryItem("acetone", 3) xPlayer.removeInventoryItem("antifreeze", 5) xPlayer.removeInventoryItem("sudo", 10) -end


    Overextended
    \ No newline at end of file +end

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Frameworks/qb.html b/ox_inventory/Frameworks/qb.html index 301a2172d9..2c04006704 100644 --- a/ox_inventory/Frameworks/qb.html +++ b/ox_inventory/Frameworks/qb.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Frameworks
    QBCore

    QBCore

    +
    Frameworks
    QBCore

    QBCore

    ⚠️

    QBCore support is experimental and cannot work as a "drag and drop" solution due to many incompatibilities.

    Compatibility

    Ox Inventory provides a complete suite of tools to replace the built-in items and inventory system from QBCore, and is not intended to be used with resources designed around it.

    @@ -55,4 +55,4 @@

    Player.Functions.RemoveItem("acetone", 3) Player.Functions.RemoveItem("antifreeze", 5) Player.Functions.RemoveItem("sudo", 10) -end


    Overextended
    \ No newline at end of file +end

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Functions/Client.html b/ox_inventory/Functions/Client.html index ac13c0d7c6..ed32e9d4ea 100644 --- a/ox_inventory/Functions/Client.html +++ b/ox_inventory/Functions/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    Client

    Client

    +
    Functions
    Client

    Client

    openInventory

    Opens an inventory using the passed data.

    exports.ox_inventory:openInventory(invType, data)
    @@ -352,4 +352,4 @@

    end

    canUseWeapons

    Allows you to enable/disable the use of weapons for a player.

    -
    LocalPlayer.state.canUseWeapons = false

    Overextended
    \ No newline at end of file +
    LocalPlayer.state.canUseWeapons = false

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Functions/Server.html b/ox_inventory/Functions/Server.html index 54d906e7b4..b4a9141a71 100644 --- a/ox_inventory/Functions/Server.html +++ b/ox_inventory/Functions/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    Server

    Server

    +
    Functions
    Server

    Server

    setPlayerInventory

    Creates and sets the player's inventory.

    exports.ox_inventory:setPlayerInventory(player, data)
    @@ -146,7 +146,7 @@

    ]]

    RemoveItem

    Removes the specified item from the specified inventory.

    -
    exports.ox_inventory:RemoveItem(inv, item, count, metadata, slot)
    +
    exports.ox_inventory:RemoveItem(inv, item, count, metadata, slot, ignoreTotal)
    • inv: table or string or number
        @@ -179,7 +179,11 @@

        A specific slot to remove the item from. If the slot is invalid, the first available slot will be used instead.

    • -
    • cb?: function(success: boolean, response?: string)
    • +
    • ignoreTotal?: boolean +
        +
      • Removes as many items as possible up to count.
      • +
      +

    Returns success: boolean, response: string?.

    Possible values of "response" on failure:

    @@ -558,15 +562,6 @@

    search can be either 'slots' or 'count', where slots will return a table of data and count will return the found amount of the specified item.

    -

    SwapSlots

    -

    Swaps slots in specified inventories.

    -
    exports.ox_inventory:SwapSlots(fromInventory, toInventory, slot1, slot2)
    -
      -
    • fromInventory: table or string or number
    • -
    • toInventory: table or string or number
    • -
    • slot1: number
    • -
    • slot2: number
    • -

    RegisterStash

    Creates a new custom stash.

    exports.ox_inventory:RegisterStash(id, label, slots, maxWeight, owner, groups, coords)
    @@ -749,4 +744,4 @@

    water.metadata.type = 'clean' ox_inventory:SetMetadata(source, water.slot, water.metadata) -print(('modified %sx water in slot %s with new metadata'):format(water.count, water.slot))


    Overextended
    \ No newline at end of file +print(('modified %sx water in slot %s with new metadata'):format(water.count, water.slot))

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Functions/Server/Hooks.html b/ox_inventory/Functions/Server/Hooks.html index 8613474219..d8cb1ef843 100644 --- a/ox_inventory/Functions/Server/Hooks.html +++ b/ox_inventory/Functions/Server/Hooks.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    Hooks

    Hooks

    +
    Functions
    Hooks

    Hooks

    Event hooks allow 3rd party resources to define new behaviour without modifying the inventory code directly.

    registerHook

    exports.ox_inventory:registerHook(eventName, function(payload) end, options)
    @@ -201,4 +201,4 @@

    exports.ox_inventory:removeHooks(id)

    • id?: number
    • -

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Guides/crafting.html b/ox_inventory/Guides/crafting.html index 5f5fb8d086..6c374be383 100644 --- a/ox_inventory/Guides/crafting.html +++ b/ox_inventory/Guides/crafting.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Guides
    Crafting

    Crafting

    +

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Guides/creatingItems.html b/ox_inventory/Guides/creatingItems.html index c7907cb613..7295ffe042 100644 --- a/ox_inventory/Guides/creatingItems.html +++ b/ox_inventory/Guides/creatingItems.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Guides
    Creating Items

    Creating Items

    +
    Guides
    Creating Items

    Creating Items

    Defining item data

    Before being able to see or use an item in game it must first be defined.

    All of the items are defined in the /data/items.lua (opens in a new tab) file with key, value pairs. @@ -259,4 +259,4 @@

    slots = 5, maxWeight = 1000, blacklist = { 'testburger' } -})


    Overextended
    \ No newline at end of file +})

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Guides/metadata.html b/ox_inventory/Guides/metadata.html index e51d74b62a..cc08c7ee20 100644 --- a/ox_inventory/Guides/metadata.html +++ b/ox_inventory/Guides/metadata.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Guides
    Metadata

    Metadata

    +
    Guides
    Metadata

    Metadata

    Item metadata is a very powerful tool that can be used to create multiple different items out of a single item.

    In this guide we'll use pokemon cards as an example, but you can find an already integrated example in the inventory with the garbage item.

    @@ -113,4 +113,4 @@

    hp = 'HP', attack = 'ATK', defense = 'DEF' -})


    Overextended
    \ No newline at end of file +})

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Guides/shops.html b/ox_inventory/Guides/shops.html index b1010116c6..a77813e074 100644 --- a/ox_inventory/Guides/shops.html +++ b/ox_inventory/Guides/shops.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Guides
    Creating Shops

    Creating Shops

    +

    Overextended
    \ No newline at end of file +})

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/Guides/stashes.html b/ox_inventory/Guides/stashes.html index 668020ea79..44582d28e4 100644 --- a/ox_inventory/Guides/stashes.html +++ b/ox_inventory/Guides/stashes.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Guides
    Custom Stashes

    Custom Stashes

    +
    Guides
    Custom Stashes

    Custom Stashes

    We can set up custom stashes from outside the resource utilising the exported RegisterStash function.

    Firstly, we need to define the stashes properties.

    Stash properties

    @@ -101,4 +101,4 @@

    end

    Example Resource

    We put together an example resource showcasing how to properly utilise the stash API:

    -

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_inventory/issues.html b/ox_inventory/issues.html index 9158c4446f..1358506b3a 100644 --- a/ox_inventory/issues.html +++ b/ox_inventory/issues.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Common Issues

    Common Issues

    +
    Common Issues

    Common Issues

    UI has not been built

    Because the UI for inventory is written in React it can't run natively under FiveM so it must first be bundled into html/css/js.

    We provide an easy way for you to do this by downloading a pre-bundled release, which you can get from here (opens in a new tab).
    @@ -32,4 +32,4 @@

    txAdmin scheduled restarts and shutdowns will trigger a save.
  • The saveinv command can be used manually or triggered in the console.
  • All inventories are saved when the number of online players hits 0.
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib.html b/ox_lib.html index 34250bbfde..616c75d75b 100644 --- a/ox_lib.html +++ b/ox_lib.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Ox Lib

    Ox Lib

    +
    Ox Lib

    Ox Lib

    A standalone library for providing easily reusable code as importable modules and exports.

    Installation

    @@ -68,4 +68,4 @@

    When working in the browser you can run pnpm start, which supports hot reloads meaning that you will see your changes after saving your file.

    If you want to work in game you can run pnpm start:game which writes changes to disk, so -the only thing you have to do is restart the resource for it take affect.


    Overextended
    \ No newline at end of file +the only thing you have to do is restart the resource for it take affect.


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/ACL/Server.html b/ox_lib/Modules/ACL/Server.html index c609eb80ad..d9b91a6783 100644 --- a/ox_lib/Modules/ACL/Server.html +++ b/ox_lib/Modules/ACL/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    ACL
    Server

    Server

    +

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/AddCommand/Server.html b/ox_lib/Modules/AddCommand/Server.html index 1876e4a252..2b5c13d070 100644 --- a/ox_lib/Modules/AddCommand/Server.html +++ b/ox_lib/Modules/AddCommand/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    AddCommand
    Server

    Server

    +
    Modules
    AddCommand
    Server

    Server

    Registers commands and simplifies argument validation, permissions, and chat suggestions.

    lib.addCommand(commandName, properties, cb)
      @@ -63,4 +63,4 @@ if item then Inventory.AddItem(args.target, item.name, args.count or 1, args.metatype) end -end)

    Overextended
    \ No newline at end of file +end)

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/AddKeybind/Client.html b/ox_lib/Modules/AddKeybind/Client.html index 04128e7fad..4082f8875e 100644 --- a/ox_lib/Modules/AddKeybind/Client.html +++ b/ox_lib/Modules/AddKeybind/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    AddKeybind
    Client

    Client

    +
    Modules
    AddKeybind
    Client

    Client

    Registers keybinds and simplifies interactions of the keybinds.

    CKeybind Class

    A table representing a keybind with the following properties.

    @@ -121,4 +121,4 @@

    Enable / Disable Keybinds

    Keybinds can be enabled / disabled by using the disable method.

    keybind:disable(true) -- disables the keybind
    -keybind:disable(false) -- enables the keybind

    Overextended
    \ No newline at end of file +keybind:disable(false) -- enables the keybind

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Cache/Client.html b/ox_lib/Modules/Cache/Client.html index c164251f89..93b6cf00e0 100644 --- a/ox_lib/Modules/Cache/Client.html +++ b/ox_lib/Modules/Cache/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Cache
    Client

    Client

    +
    Modules
    Cache
    Client

    Client

    Values and cache functionality available to the client, in addition to the shared values.

    Default values

      @@ -74,4 +74,4 @@

      lib.onCache('vehicle', function(value)
           print('old vehicle:', cache.vehicle)
           print('new vehicle:', value)
      -end)


    Overextended
    \ No newline at end of file +end)

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Cache/Shared.html b/ox_lib/Modules/Cache/Shared.html index 347e87aaf6..f428f5f7df 100644 --- a/ox_lib/Modules/Cache/Shared.html +++ b/ox_lib/Modules/Cache/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Cache
    Shared

    Shared

    +
    Modules
    Cache
    Shared

    Shared

    A table containing cached function results, which may be constants or infrequently changed.

    Default values

      @@ -63,4 +63,4 @@

      > 1 > 6 > 6 -> 6


    Overextended
    \ No newline at end of file +> 6

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Callback/JavaScript/Client.html b/ox_lib/Modules/Callback/JavaScript/Client.html index 969c20e267..0086553c62 100644 --- a/ox_lib/Modules/Callback/JavaScript/Client.html +++ b/ox_lib/Modules/Callback/JavaScript/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Callback
    JavaScript
    Client

    Client

    +
    Modules
    Callback
    JavaScript
    Client

    Client

    Trigger Server Callback

    triggerServerCallback

    triggerServerCallback(eventName, delay, ...args)
    @@ -45,4 +45,4 @@

    const response = await triggerServerCallback<{ serverValue: number }>('test:server', 1, args); if (!response) return; console.log('Response from server', response); -}, 100);


    Overextended
    \ No newline at end of file +}, 100);

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Callback/JavaScript/Server.html b/ox_lib/Modules/Callback/JavaScript/Server.html index 35c4685bfb..47e4c885cc 100644 --- a/ox_lib/Modules/Callback/JavaScript/Server.html +++ b/ox_lib/Modules/Callback/JavaScript/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Callback
    JavaScript
    Server

    Server

    +
    Modules
    Callback
    JavaScript
    Server

    Server

    Trigger Client Callback

    triggerClientCallback

    triggerClientCallback(eventName, playerId, ...args)
    @@ -41,4 +41,4 @@

    if (!response) return; console.log(response.clientValue); console.log('Response from client', response); -}, 100);


    Overextended
    \ No newline at end of file +}, 100);

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Callback/Lua/Client.html b/ox_lib/Modules/Callback/Lua/Client.html index 3eebe9565b..12686ec1bd 100644 --- a/ox_lib/Modules/Callback/Lua/Client.html +++ b/ox_lib/Modules/Callback/Lua/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Callback
    Lua
    Client

    Client

    +
    Modules
    Callback
    Lua
    Client

    Client

    Trigger Server Callback

    lib.callback

    The response is handled in a separate coroutine.

    @@ -54,4 +54,4 @@

    lib.callback.register('ox:getNearbyVehicles', function(radius)
         local nearbyVehicles = lib.getNearbyVehicles(GetEntityCoords(cache.ped), radius, true)
         return nearbyVehicles
    -end)


    Overextended
    \ No newline at end of file +end)

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Callback/Lua/Server.html b/ox_lib/Modules/Callback/Lua/Server.html index 3921f845ae..7ecfd142ed 100644 --- a/ox_lib/Modules/Callback/Lua/Server.html +++ b/ox_lib/Modules/Callback/Lua/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Callback
    Lua
    Server

    Server

    +
    Modules
    Callback
    Lua
    Server

    Server

    Trigger Client Callback

    lib.callback

    The response is handled in a separate coroutine.

    @@ -51,4 +51,4 @@

    lib.callback.register('ox_inventory:getItemCount', function(source, item, metadata, target)
         local inventory = target and Inventory(target) or Inventory(source)
         return (inventory and Inventory.GetItem(inventory, item, metadata, true)) or 0
    -end)


    Overextended
    \ No newline at end of file +end)

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Class/Shared.html b/ox_lib/Modules/Class/Shared.html index 5570d5251d..4e002977fe 100644 --- a/ox_lib/Modules/Class/Shared.html +++ b/ox_lib/Modules/Class/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Class
    Shared

    Shared

    +
    Modules
    Class
    Shared

    Shared

    lib.class

    Creates a new class.

    local MyClass = lib.class(name, super)
    @@ -79,4 +79,4 @@

    }) print(('the banana is %s and %s - gross!'):format(rottenBanana:getColour(), rottenBanana:getStench())) -end)


    Overextended
    \ No newline at end of file +end)

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Cron/Server.html b/ox_lib/Modules/Cron/Server.html index 2a7ba927b2..5336fab414 100644 --- a/ox_lib/Modules/Cron/Server.html +++ b/ox_lib/Modules/Cron/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Cron
    Server

    Server

    +
    Modules
    Cron
    Server

    Server

    A Lua implementation of cron, allowing tasks to be scheduled to run periodically at fixed times, dates, and intervals.

    Cron expression

    A string containing five values separated by white spaces, representing a set of times to execute a task.

    @@ -45,4 +45,4 @@

    Return:

    • task: OxTask
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/DisableControls/Client.html b/ox_lib/Modules/DisableControls/Client.html index fe11e45475..05fefd1edc 100644 --- a/ox_lib/Modules/DisableControls/Client.html +++ b/ox_lib/Modules/DisableControls/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    DisableControls
    Client

    Client

    +
    Modules
    DisableControls
    Client

    Client

    A centralized way to track and disable controls.

    lib.disableControls

    Call on frame to disable all stored controls.

    @@ -47,4 +47,4 @@

    Control(s) to clear out from being tracked -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/GetClosestObject/Shared.html b/ox_lib/Modules/GetClosestObject/Shared.html index bc2e685421..35c184b583 100644 --- a/ox_lib/Modules/GetClosestObject/Shared.html +++ b/ox_lib/Modules/GetClosestObject/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    GetClosestObject
    Shared

    Shared

    +
    Modules
    GetClosestObject
    Shared

    Shared

    lib.getClosestObject

    Get the object handle and coords of the closest object to a set of coordinates.

    lib.getClosestObject(coords, maxDistance)
    @@ -32,4 +32,4 @@

  • object?: number
  • coords?: vector3
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/GetClosestPed/Shared.html b/ox_lib/Modules/GetClosestPed/Shared.html index 985f9ba251..122777d859 100644 --- a/ox_lib/Modules/GetClosestPed/Shared.html +++ b/ox_lib/Modules/GetClosestPed/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    GetClosestPed
    Shared

    Shared

    +
    Modules
    GetClosestPed
    Shared

    Shared

    lib.getClosestPed

    Get the ped handle and coords of the closest ped to a set of coordinates.

    lib.getClosestPed(coords, maxDistance)
    @@ -32,4 +32,4 @@

  • ped?: number
  • coords?: vector3
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/GetClosestPlayer/Shared.html b/ox_lib/Modules/GetClosestPlayer/Shared.html index 5831de6cfb..7303e35fc5 100644 --- a/ox_lib/Modules/GetClosestPlayer/Shared.html +++ b/ox_lib/Modules/GetClosestPlayer/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    GetClosestPlayer
    Shared

    Shared

    +
    Modules
    GetClosestPlayer
    Shared

    Shared

    lib.getClosestPlayer

    Get the player id, ped handle, and coords of the closest player to a set of coordinates.

    lib.getClosestPlayer(coords, maxDistance, includePlayer)
    @@ -39,4 +39,4 @@

    playerId?: number
  • playerPed?: number
  • playerCoords?: vector3
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/GetClosestVehicle/Shared.html b/ox_lib/Modules/GetClosestVehicle/Shared.html index f2125d7a87..6af5fb3879 100644 --- a/ox_lib/Modules/GetClosestVehicle/Shared.html +++ b/ox_lib/Modules/GetClosestVehicle/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    GetClosestVehicle
    Shared

    Shared

    +
    Modules
    GetClosestVehicle
    Shared

    Shared

    lib.getClosestVehicle

    Get the vehicle handle and coords of the closest vehicle to a set of coordinates.

    lib.getClosestVehicle(coords, maxDistance, includePlayerVehicle)
    @@ -38,4 +38,4 @@

  • vehicle?: number
  • vehicleCoords?: vector3
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/GetNearbyObjects/Shared.html b/ox_lib/Modules/GetNearbyObjects/Shared.html index 5a19e4b082..fd495af0e7 100644 --- a/ox_lib/Modules/GetNearbyObjects/Shared.html +++ b/ox_lib/Modules/GetNearbyObjects/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    GetNearbyObjects
    Shared

    Shared

    +
    Modules
    GetNearbyObjects
    Shared

    Shared

    lib.getNearbyObjects

    Get the object handle and coords of all objects within range of a set of coordinates.

    lib.getNearbyObjects(coords, maxDistance)
    @@ -31,4 +31,4 @@

    Return:

    • objects: { object: number, coords: vector3 }[]
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/GetNearbyPeds/Shared.html b/ox_lib/Modules/GetNearbyPeds/Shared.html index 5ffa9c519f..98383aae84 100644 --- a/ox_lib/Modules/GetNearbyPeds/Shared.html +++ b/ox_lib/Modules/GetNearbyPeds/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    GetNearbyPeds
    Shared

    Shared

    +
    Modules
    GetNearbyPeds
    Shared

    Shared

    lib.getNearbyPeds

    Get the ped handle and coords of all peds within range of a set of coordinates.

    lib.getNearbyPeds(coords, maxDistance)
    @@ -31,4 +31,4 @@

    Return:

    • peds: { ped: number, coords: vector3 }[]
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/GetNearbyPlayers/Shared.html b/ox_lib/Modules/GetNearbyPlayers/Shared.html index 6f6f6412a5..305052e55b 100644 --- a/ox_lib/Modules/GetNearbyPlayers/Shared.html +++ b/ox_lib/Modules/GetNearbyPlayers/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    GetNearbyPlayers
    Shared

    Shared

    +
    Modules
    GetNearbyPlayers
    Shared

    Shared

    lib.getNearbyPlayers

    Get the player id, ped handle, and coords of all players within range of a set of coordinates.

    lib.getNearbyPlayers(coords, maxDistance, includePlayer)
    @@ -37,4 +37,4 @@

    Return:

    • players: { id: number, ped: number, coords: vector3 }[]
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/GetNearbyVehicles/Shared.html b/ox_lib/Modules/GetNearbyVehicles/Shared.html index debbda5ed0..67e6426b35 100644 --- a/ox_lib/Modules/GetNearbyVehicles/Shared.html +++ b/ox_lib/Modules/GetNearbyVehicles/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    GetNearbyVehicles
    Shared

    Shared

    +
    Modules
    GetNearbyVehicles
    Shared

    Shared

    lib.getNearbyVehicles

    Get the vehicle handle and coords of all vehicles within range of a set of coordinates.

    lib.getNearbyVehicles(coords, maxDistance, includePlayerVehicle)
    @@ -37,4 +37,4 @@

    Return:

    • vehicles: { vehicle: number, coords: vector3 }[]
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface.html b/ox_lib/Modules/Interface.html index 13f9db52d2..93cd8cafcb 100644 --- a/ox_lib/Modules/Interface.html +++ b/ox_lib/Modules/Interface.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Interface

    Interface

    +
    Modules
    Interface

    Interface

    If you wish to change the primary colour for the UI to better match your server's theme you can do so easily through the available convars.

    They don't require you to build the UI, just restart the resource.

    Convars:

    @@ -22,4 +22,4 @@

    You can find the full list of preset colours and shades here:

    https://v6.mantine.dev/theming/colors/#default-colors (opens in a new tab)

    If you wish to create your own pallete I suggest following the guide on that page.
    -Keep in mind doing so will require you to download the source code and build the UI.


    Overextended
    \ No newline at end of file +Keep in mind doing so will require you to download the source code and build the UI.


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/alert.html b/ox_lib/Modules/Interface/Client/alert.html index 7570ed4e25..8903376bb5 100644 --- a/ox_lib/Modules/Interface/Client/alert.html +++ b/ox_lib/Modules/Interface/Client/alert.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Alert Dialog

    Alert Dialog

    +
    Modules
    Client
    Alert Dialog

    Alert Dialog

    Simple alert dialog that can display a message to the player.
    Returns whether the player pressed the confirm button or canceled the dialog.

    lib.alertDialog

    @@ -65,4 +65,4 @@

    }) print(alert)

    -

    alert_dialog


    Overextended
    \ No newline at end of file +

    alert_dialog


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/clipboard.html b/ox_lib/Modules/Interface/Client/clipboard.html index 2f18e7d227..c34077b940 100644 --- a/ox_lib/Modules/Interface/Client/clipboard.html +++ b/ox_lib/Modules/Interface/Client/clipboard.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Clipboard

    Clipboard

    +
    Modules
    Client
    Clipboard

    Clipboard

    lib.setClipboard

    Sets the player's clipboard to the specified string value.

    💡

    Will not work if focus is already taken by some NUI component.

    @@ -19,4 +19,4 @@

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/context.html b/ox_lib/Modules/Interface/Client/context.html index 4ffbd45659..07ef1fc262 100644 --- a/ox_lib/Modules/Interface/Client/context.html +++ b/ox_lib/Modules/Interface/Client/context.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Context Menu

    Context Menu

    +
    Modules
    Client
    Context Menu

    Context Menu

    lib.registerContext

    Used for registering a context menu.

    lib.registerContext(context)
    @@ -263,4 +263,4 @@

    menu_example metadata sub_menu -event_menu


    Overextended
    \ No newline at end of file +event_menu


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/input.html b/ox_lib/Modules/Interface/Client/input.html index e3b39fc7aa..e52a69a0fc 100644 --- a/ox_lib/Modules/Interface/Client/input.html +++ b/ox_lib/Modules/Interface/Client/input.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Input Dialog

    Input Dialog

    +
    Modules
    Client
    Input Dialog

    Input Dialog

    The input dialog window allows you to take data from the user by setting input fields.

    lib.inputDialog

    lib.inputDialog(heading, rows, options)
    @@ -254,4 +254,4 @@

    -- Transforming date timestamp to a readable format with Lua's os library (server-only) local timestamp = math.floor(input[5] / 1000) local date = os.date('%Y-%m-%d %H:%M:%S', timestamp)

    -

    Example image


    Overextended
    \ No newline at end of file +

    Example image


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/menu.html b/ox_lib/Modules/Interface/Client/menu.html index 16ac0c7006..6dfefa2bc4 100644 --- a/ox_lib/Modules/Interface/Client/menu.html +++ b/ox_lib/Modules/Interface/Client/menu.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Menu

    Menu

    +
    Modules
    Client
    Menu

    Menu

    Keyboard navigation menu with specific event functions.

    lib.registerMenu

    Registers and caches a menu under the specified id.

    @@ -194,4 +194,4 @@

    RegisterCommand('testmenu', function() lib.showMenu('some_menu_id') end)

    -

    Example


    Overextended
    \ No newline at end of file +

    Example


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/notify.html b/ox_lib/Modules/Interface/Client/notify.html index e4b9865948..262f211b4b 100644 --- a/ox_lib/Modules/Interface/Client/notify.html +++ b/ox_lib/Modules/Interface/Client/notify.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Notifications

    Notifications

    +
    Modules
    Client
    Notifications

    Notifications

    lib.notify

    Custom notifications with a lot of styling options.

    lib.notify(data)
    @@ -86,4 +86,4 @@

    icon = 'ban', iconColor = '#C53030' })

    -

    custom_notification


    Overextended
    \ No newline at end of file +

    custom_notification


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/progress.html b/ox_lib/Modules/Interface/Client/progress.html index f7520fa5c4..9e3bd6e91d 100644 --- a/ox_lib/Modules/Interface/Client/progress.html +++ b/ox_lib/Modules/Interface/Client/progress.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Progress

    Progress

    +
    Modules
    Client
    Progress

    Progress

    lib.progressBar

    Displays a running progress bar.

    lib.progressBar(data)
    @@ -251,4 +251,4 @@

    lib.cancelProgress

    If there is a progress bar active and the progress bar can be cancelled then it cancels it.

    -
    lib.cancelProgress()

    Overextended
    \ No newline at end of file +
    lib.cancelProgress()

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/radial.html b/ox_lib/Modules/Interface/Client/radial.html index a436f29870..2ef76fae7d 100644 --- a/ox_lib/Modules/Interface/Client/radial.html +++ b/ox_lib/Modules/Interface/Client/radial.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Radial Menu

    Radial Menu

    +
    Modules
    Client
    Radial Menu

    Radial Menu

    • Radial menu has a global menu that's by default accessed with z and only displays when there is at least one item.
    • You can add and remove items from the global menu using lib.addRadialItem and lib.removeRadialItem.
    • @@ -28,7 +28,17 @@

      Id that is used for removing options.

    -
  • icon: string
  • +
  • icon: string +
      +
    • Either a font awesome or a custom URI.1
    • +
    +
  • +
  • iconWidth?: number
  • +
  • iconHeight?: number +
      +
    • In the case of a custom URI, adjust the size of the icon.
    • +
    +
  • label: string
    • Label uses \n to insert a newline
    • @@ -184,4 +194,4 @@

      lib.removeRadialItem('garage_access') end

  • radial1 -radial2


    Overextended
    \ No newline at end of file +radial2


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/skillcheck.html b/ox_lib/Modules/Interface/Client/skillcheck.html index 395efecec3..ab490cf87d 100644 --- a/ox_lib/Modules/Interface/Client/skillcheck.html +++ b/ox_lib/Modules/Interface/Client/skillcheck.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    Skill Check

    Skill Check

    +
    Modules
    Client
    Skill Check

    Skill Check

    lib.skillCheck

    Runs a skill check with the defined difficulty.

    lib.skillCheck(difficulty, inputs)
    @@ -56,4 +56,4 @@

    Usage Example

    local success = lib.skillCheck({'easy', 'easy', {areaSize = 60, speedMultiplier = 2}, 'hard'}, {'w', 'a', 's', 'd'})
    -

    skillcheck_example


    Overextended
    \ No newline at end of file +

    skillcheck_example


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Interface/Client/textui.html b/ox_lib/Modules/Interface/Client/textui.html index 6ce4b348d1..536b44f599 100644 --- a/ox_lib/Modules/Interface/Client/textui.html +++ b/ox_lib/Modules/Interface/Client/textui.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Client
    TextUI

    TextUI

    +
    Modules
    Client
    TextUI

    TextUI

    lib.showTextUI

    Show the TextUI window.

    ⚠️

    DO NOT run this function every tick, it's intended to be used as a toggle.

    @@ -57,4 +57,4 @@

    color = 'white' } })

    -

    custom_example


    Overextended
    \ No newline at end of file +

    custom_example


    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Locale/Shared.html b/ox_lib/Modules/Locale/Shared.html index 5388232af1..59a52ab8a9 100644 --- a/ox_lib/Modules/Locale/Shared.html +++ b/ox_lib/Modules/Locale/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Locale
    Shared

    Allows servers to set a preferred language and attempt to load locale files in any resources using the module. +

    Modules
    Locale
    Shared

    Allows servers to set a preferred language and attempt to load locale files in any resources using the module. Locale files should use the ISO Language Code (opens in a new tab) and be saved as ./locales/langcode.json

    Setup

    To change the preferred language from English, add the convar to your server.cfg and change en to the desired language code.

    @@ -64,4 +64,4 @@

  • resource: string
  • key: string
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Logger/Server.html b/ox_lib/Modules/Logger/Server.html index 59385aa6fa..fbc5a9eaba 100644 --- a/ox_lib/Modules/Logger/Server.html +++ b/ox_lib/Modules/Logger/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Logger
    Server

    Server

    +
    Modules
    Logger
    Server

    Server

    lib.logger

    lib.logger(source, event, message, ...)
      @@ -59,4 +59,4 @@

      set ox:logger "loki"
       set loki:user "<insert your user>"
       set loki:password "<insert the api key or password>"
      -set loki:endpoint "<insert loki url without http:// or https://>"


    Overextended
    \ No newline at end of file +set loki:endpoint "<insert loki url without http:// or https://>"

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Marker/Client.html b/ox_lib/Modules/Marker/Client.html new file mode 100644 index 0000000000..a7c7f2e02b --- /dev/null +++ b/ox_lib/Modules/Marker/Client.html @@ -0,0 +1,80 @@ +Client - Ox Lib
    Modules
    Marker
    Client

    Client

    +

    lib.marker

    +

    Simple way to create markers

    +

    Marker Class

    +

    A table representing a marker with the following properties.

    +
      +
    • type: number or string +
        +
      • This field accepts either a numerical value representing the marker ID or a string containing the name of a marker as documented on FiveM Docs (opens in a new tab).
      • +
      +
    • +
    • coords?: vector3
    • +
    • width?: number
    • +
    • height?: number
    • +
    • color?: { r: number, g: number, b: number, a: number}
    • +
    • direction?: vector3
    • +
    • rotation?: vector3
    • +
    +

    lib.marker.new

    +
    lib.marker.new(options)
    +
      +
    • Returns: Marker
    • +
    +

    Usage Example

    +
    local marker = lib.marker.new({
    +	type = 1,
    +	coords = GetEntityCoords(cache.ped),
    +	color = { r = 255, g = 0, b = 0, a = 200 },
    +})
    + 
    +Citizen.CreateThread(function()
    +	while true do
    +		marker:draw()
    + 
    +		Citizen.Wait(1)
    +	end
    +end)
    +

    Interactive Example

    +
    local point = lib.points.new({
    +  coords = SharedConfig.Warehouse.coords,
    +  distance = 20,
    +})
    + 
    +local marker = lib.marker.new({
    +  coords = GetEntityCoords(SharedConfig.Warehouse.coords),
    +  type = 1,
    +})
    + 
    +function point:nearby()
    +  marker:draw()
    + 
    +  if self.currentDistance < 1.5 then
    +    if not lib.isTextUIOpen() then
    +      lib.showTextUI("Press [E] to get notified")
    +    end
    + 
    +    if IsControlJustPressed(0, 51) then
    +      lib.notify({
    +        description = "Hello, World!"
    +      })
    +    end
    +  else
    +    if lib.isTextUIOpen() then
    +      lib.hideTextUI()
    +    end
    +  end
    +end

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Math/Shared.html b/ox_lib/Modules/Math/Shared.html index a267da47d9..30e511afee 100644 --- a/ox_lib/Modules/Math/Shared.html +++ b/ox_lib/Modules/Math/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Math
    Shared

    Shared

    +
    Modules
    Math
    Shared

    Shared

    lib.math

    Extends the standard Lua math table with extra functions.

    math = lib.math
    @@ -115,4 +115,4 @@

    Return:

    • number: number
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Points/JavaScript/Client.html b/ox_lib/Modules/Points/JavaScript/Client.html index 76d7becf78..86397efeba 100644 --- a/ox_lib/Modules/Points/JavaScript/Client.html +++ b/ox_lib/Modules/Points/JavaScript/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Points
    JavaScript
    Client

    Client

    +
    Modules
    Points
    JavaScript
    Client

    Client

    Points

    Simple and centralised distance checking, supporting callbacks when entering, leaving, and standing in-range of set coordinates.

    Point<T>({coords, distance, onEnter, onExit, nearby, args})
    @@ -50,4 +50,4 @@

    point.onExit = () => { console.log('Left range of point', point.id) -}


    Overextended
    \ No newline at end of file +}

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Points/Lua/Client.html b/ox_lib/Modules/Points/Lua/Client.html index bd6500af9f..28f205e4f2 100644 --- a/ox_lib/Modules/Points/Lua/Client.html +++ b/ox_lib/Modules/Points/Lua/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Points
    Lua
    Client

    Client

    +
    Modules
    Points
    Lua
    Client

    Client

    Simple and centralised distance checking, supporting callbacks when entering, leaving, and standing in-range of set coordinates.

    CPoint Class

    A table representing a point with the following properties.

    @@ -106,4 +106,4 @@

    Return:

    • closestPoint?: CPoint
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Print/Shared.html b/ox_lib/Modules/Print/Shared.html index 2744087961..e3bbcc7328 100644 --- a/ox_lib/Modules/Print/Shared.html +++ b/ox_lib/Modules/Print/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Print
    Shared

    Shared

    +
    Modules
    Print
    Shared

    Shared

    Prints to console conditionally based on convars set. Different level prints are colored and labeled. Resource name is always included.

    @@ -70,4 +70,4 @@

    set ox:printlevel "info"
     set ox:printlevel:ox_inventory "warn"
    -set ox:printlevel:<resourceName> "<level>"


    Overextended
    \ No newline at end of file +set ox:printlevel:<resourceName> "<level>"

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Raycast/Client.html b/ox_lib/Modules/Raycast/Client.html index 9115d0a24d..b14505d559 100644 --- a/ox_lib/Modules/Raycast/Client.html +++ b/ox_lib/Modules/Raycast/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Raycast
    Client

    Client

    +
    Modules
    Raycast
    Client

    Client

    lib.raycast.cam

    Starts a shapetest originating from the camera, extending to ~10m by default.

    lib.raycast.cam(flags, ignore, distance)
    @@ -57,4 +57,4 @@

    materialHash: number -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Require/Shared.html b/ox_lib/Modules/Require/Shared.html index 8041bee398..d6f241b79b 100644 --- a/ox_lib/Modules/Require/Shared.html +++ b/ox_lib/Modules/Require/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Require
    Shared

    Shared

    +
    Modules
    Require
    Shared

    Shared

    This module is always loaded by default.

    require

    Loads the given module. The function starts by indexing the loaded table to determine whether modname is already loaded. If it is, then require returns the value stored at loaded[modname].

    @@ -22,6 +22,11 @@

    Modules can be loaded from external resources using @resource.modname.
    require 'modname'
    +
    ⚠️

    Client modules must be defined in the file section of the resource manifest.

    fxmanifest.lua
    file 'modname.lua'
    +-- or
    +files {
    +  'modname.lua'
    +}

    Usage Example

    - resources/
       - mylib/
    @@ -75,9 +80,9 @@ 

    Usage Example

    -
    myresource/import.lua
    local events = lib.load('data.events')
    +
    myresource/import.lua
    local events = lib.loadJson('data.events')
      
     print('Loaded events')
    myresource/data/events.json
    {
       "disconnect": "onPlayerDropped"
    -}

    Overextended
    \ No newline at end of file +}

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Streaming/Client.html b/ox_lib/Modules/Streaming/Client.html index b5bf6e7d7a..1f92186666 100644 --- a/ox_lib/Modules/Streaming/Client.html +++ b/ox_lib/Modules/Streaming/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Streaming
    Client

    Client

    +
    Modules
    Streaming
    Client

    Client

    Check if assets exist, such as models, and loads them into memory.
    Throws errors for invalid assets and returns true if the asset is loaded.

    lib.requestAnimDict

    @@ -115,4 +115,4 @@

    2 WEAPON_COMPONENT_SCOPE 4 WEAPON_COMPONENT_SUPP 8 WEAPON_COMPONENT_SCLIP2 -16 WEAPON_COMPONENT_GRIP


    Overextended
    \ No newline at end of file +16 WEAPON_COMPONENT_GRIP

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/String/Shared.html b/ox_lib/Modules/String/Shared.html index e367c052ed..72fff60e8e 100644 --- a/ox_lib/Modules/String/Shared.html +++ b/ox_lib/Modules/String/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    String
    Shared

    Shared

    +
    Modules
    String
    Shared

    Shared

    lib.string

    Extends the standard Lua string table with extra functions.

    string = lib.string
    @@ -35,4 +35,4 @@

    Return:

    • string: string
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Table/Shared.html b/ox_lib/Modules/Table/Shared.html index 2c12aa5e6c..e33314532d 100644 --- a/ox_lib/Modules/Table/Shared.html +++ b/ox_lib/Modules/Table/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Table
    Shared

    Shared

    +
    Modules
    Table
    Shared

    Shared

    Adds additional functions alongside the standard table library.

    lib.table.contains

    Checks if table contains the given value. Only intended for simple values and unnested tables.

    @@ -75,4 +75,4 @@

    Return:

    • isFrozen: boolean
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/VehicleProperties/Client.html b/ox_lib/Modules/VehicleProperties/Client.html index fddcd71cf0..d02e0b1f49 100644 --- a/ox_lib/Modules/VehicleProperties/Client.html +++ b/ox_lib/Modules/VehicleProperties/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    VehicleProperties
    Client

    Client

    +

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Version/Server.html b/ox_lib/Modules/Version/Server.html index 4c0d08e497..811698cddc 100644 --- a/ox_lib/Modules/Version/Server.html +++ b/ox_lib/Modules/Version/Server.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Version
    Server

    Server

    +

    Overextended
    \ No newline at end of file +
    lib.versionCheck('overextended/ox_lib')

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Version/Shared.html b/ox_lib/Modules/Version/Shared.html index 62a6f1aba9..1acf84a5c1 100644 --- a/ox_lib/Modules/Version/Shared.html +++ b/ox_lib/Modules/Version/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Version
    Shared

    Shared

    +
    Modules
    Version
    Shared

    Shared

    lib.checkDependency

    Check if a resource is using a specified version or higher, allowing for compatibility checks or throwing errors.

    lib.checkDependency(resource, version)
    @@ -19,4 +19,4 @@

    resource: string
  • version: string
  • -
    if not lib.checkDependency('ox_lib', '1.5.0') then error() end


    Overextended
    \ No newline at end of file +
    if not lib.checkDependency('ox_lib', '1.5.0') then error() end

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/WaitFor/Shared.html b/ox_lib/Modules/WaitFor/Shared.html index 06b3e74cf5..6cfcc9e5eb 100644 --- a/ox_lib/Modules/WaitFor/Shared.html +++ b/ox_lib/Modules/WaitFor/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    WaitFor
    Shared

    Shared

    +
    Modules
    WaitFor
    Shared

    Shared

    lib.waitFor

    Calls a function repeatedly until it receives a non-nil value, or it times out.
    The function result is then returned.

    @@ -35,4 +35,4 @@

    local value --[['abc']] = lib.waitFor(function()
         if math.random(0, 1) == 1 then return 'abc' end
    -end)


    Overextended
    \ No newline at end of file +end)

    Overextended
    \ No newline at end of file diff --git a/ox_lib/Modules/Zones/Shared.html b/ox_lib/Modules/Zones/Shared.html index fc7fef6417..bf6304433b 100644 --- a/ox_lib/Modules/Zones/Shared.html +++ b/ox_lib/Modules/Zones/Shared.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Modules
    Zones
    Shared

    Shared

    +
    Modules
    Zones
    Shared

    Shared

    Faster alternative to PolyZone utilising glm.polygon (opens in a new tab).

    💡

    Currently zones only have basic support on the server side. Some features will not work such as onEnter, onExit, and inside.

    @@ -163,4 +163,4 @@

    vec(446.3, -997.9, 25.8), }, thickness = 2, -})


    Overextended
    \ No newline at end of file +})

    Overextended
    \ No newline at end of file diff --git a/ox_target.html b/ox_target.html index 8a3347d584..a3ea53f57f 100644 --- a/ox_target.html +++ b/ox_target.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Ox Target

    Ox Target

    +

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_target/Functions/Client.html b/ox_target/Functions/Client.html index 03d57795dc..c1998de12c 100644 --- a/ox_target/Functions/Client.html +++ b/ox_target/Functions/Client.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    Client

    Client

    +

    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/ox_target/Options.html b/ox_target/Options.html index 33f0eead3b..a498a34061 100644 --- a/ox_target/Options.html +++ b/ox_target/Options.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Options

    Options

    +
    Options

    Options

    When creating a targetable option you must send an array of options with the following properties.

    Option Parameters


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/oxmysql.html b/oxmysql.html index c990bca705..cbe5fefd23 100644 --- a/oxmysql.html +++ b/oxmysql.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    OxMySQL

    OxMySQL

    +
    OxMySQL

    OxMySQL

    A replacement of mysql-async and ghmattimysql with expanded API and improved compatibility for MySQL 8.

    @@ -75,4 +75,4 @@

    When uncertain if a row should be inserted into the database, or an existing row should be updated, queries should check for duplicate keys.

    MySQL.prepare('INSERT INTO ox_inventory (owner, name, data) VALUES (?, ?, ?) ON DUPLICATE KEY UPDATE data = VALUES(data)', { owner, dbId, inventory })

    This is preferred over checking the existence of a row, then inserting or updating depending on the result.
    -Furthermore, unlike using 'REPLACE INTO', the row is not deleted and re-inserted.


    Overextended
    \ No newline at end of file +Furthermore, unlike using 'REPLACE INTO', the row is not deleted and re-inserted.


    Overextended
    \ No newline at end of file diff --git a/oxmysql/Functions/insert.html b/oxmysql/Functions/insert.html index d0a5f8a1eb..0a944eda2e 100644 --- a/oxmysql/Functions/insert.html +++ b/oxmysql/Functions/insert.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    insert

    Insert

    +
    Functions
    insert

    Insert

    Inserts a new entry into the database and returns the insert id for the row, if valid.

    Promise

    local id = MySQL.insert.await('INSERT INTO `users` (identifier, firstname, lastname) VALUES (?, ?, ?)', {
    @@ -36,4 +36,4 @@ 

    MySQL.Async.insert
  • exports.ghmattimysql.execute
  • exports.oxmysql.insert
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/oxmysql/Functions/prepare.html b/oxmysql/Functions/prepare.html index d132862766..e4227cd2c0 100644 --- a/oxmysql/Functions/prepare.html +++ b/oxmysql/Functions/prepare.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    prepare

    Prepare

    +
    Functions
    prepare

    Prepare

    Prepare can be used to execute frequently called queries faster and accepts multiple sets of parameters to be used with a single query.

    • Date will not return the datestring commonly used in FiveM
    • @@ -39,4 +39,4 @@

      Aliases

      • exports.oxmysql.prepare
      • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/oxmysql/Functions/query.html b/oxmysql/Functions/query.html index c701b8d639..3e2ea3fbdc 100644 --- a/oxmysql/Functions/query.html +++ b/oxmysql/Functions/query.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    query

    Query

    +
    Functions
    query

    Query

    When selecting data, returns all matching rows and columns; otherwise, returns data like insertId, affectedRows, etc.

    Promise

    local response = MySQL.query.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ?', {
    @@ -46,4 +46,4 @@ 

    MySQL.Async.fetchAll
  • exports.ghmattimysql.execute
  • exports.oxmysql.query
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/oxmysql/Functions/rawExecute.html b/oxmysql/Functions/rawExecute.html index ee7cfe2197..f77fa5d9d2 100644 --- a/oxmysql/Functions/rawExecute.html +++ b/oxmysql/Functions/rawExecute.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    rawExecute

    RawExecute

    +
    Functions
    rawExecute

    RawExecute

    rawExecute can be used to execute frequently called queries faster and accepts multiple sets of parameters to be used with a single query.

    • Date will not return the datestring commonly used in FiveM
    • @@ -40,4 +40,4 @@

      Aliases

      • exports.oxmysql.rawExecute
      • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/oxmysql/Functions/scalar.html b/oxmysql/Functions/scalar.html index aa66a10701..5efdf9f086 100644 --- a/oxmysql/Functions/scalar.html +++ b/oxmysql/Functions/scalar.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    scalar

    Scalar

    +
    Functions
    scalar

    Scalar

    Returns the first column for a single row.

    Promise

    local firstName = MySQL.scalar.await('SELECT `firstname` FROM `users` WHERE `identifier` = ? LIMIT 1', {
    @@ -36,4 +36,4 @@ 

    MySQL.Async.fetchScalar
  • exports.ghmattimysql.scalar
  • exports.oxmysql.scalar
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/oxmysql/Functions/single.html b/oxmysql/Functions/single.html index 8d08963d64..20e5836b24 100644 --- a/oxmysql/Functions/single.html +++ b/oxmysql/Functions/single.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    single

    Single

    +
    Functions
    single

    Single

    Returns all selected columns for a single row.

    Promise

    local row = MySQL.single.await('SELECT `firstname`, `lastname` FROM `users` WHERE `identifier` = ? LIMIT 1', {
    @@ -36,4 +36,4 @@ 

    Aliases

    • exports.oxmysql.single
    • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/oxmysql/Functions/transaction.html b/oxmysql/Functions/transaction.html index 53a3b7f9b6..21e402ed1a 100644 --- a/oxmysql/Functions/transaction.html +++ b/oxmysql/Functions/transaction.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    transaction

    Transaction

    +
    Functions
    transaction

    Transaction

    A transaction executes multiple queries and commits them only if all succeed.
    If one fails, none of the queries are committed.

    The return value is a boolean, which is the result of the transaction.

    @@ -71,4 +71,4 @@

    Transaction Isolation Level

    This can be set through the convar mysql_transaction_isolation_level, and is an integer ranging from 1-4.
    The default value is 2.

    -
    Convar ValueResult
    1Repeatable Read
    2Read Committed
    3Read Uncommitted
    4Serializable

    Overextended
    \ No newline at end of file +
    Convar ValueResult
    1Repeatable Read
    2Read Committed
    3Read Uncommitted
    4Serializable

    Overextended
    \ No newline at end of file diff --git a/oxmysql/Functions/update.html b/oxmysql/Functions/update.html index a7de80b42e..f585367c65 100644 --- a/oxmysql/Functions/update.html +++ b/oxmysql/Functions/update.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Functions
    update

    Update

    +
    Functions
    update

    Update

    Returns the number of rows affected by the query.

    Promise

    local affectedRows = MySQL.update.await('UPDATE users SET firstname = ? WHERE identifier = ?', {
    @@ -36,4 +36,4 @@ 

    MySQL.Async.execute
  • exports.ghmattimysql.execute
  • exports.oxmysql.update
  • -


    Overextended
    \ No newline at end of file +

    Overextended
    \ No newline at end of file diff --git a/oxmysql/benchmark.html b/oxmysql/benchmark.html index 7004c7910f..8d106d9b2d 100644 --- a/oxmysql/benchmark.html +++ b/oxmysql/benchmark.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Benchmark

    Benchmark

    +
    Benchmark

    Benchmark

    Benchmarking is based on the time spent when to receive a response from exports.
    Real query speeds will be reported in the debug UI and in the server console with mysql_debug enabled.

    Speeds will vary greatly based on system hardware, database settings, database version, and the current workload.

    @@ -134,4 +134,4 @@

    [script:test] 10004 1 bobby {"identifier":"abcdef","username":"bobby","id":10004} [script:test] [script:test] query -[script:test] Executed 1 queries in 1.1588ms


    Overextended
    \ No newline at end of file +[script:test] Executed 1 queries in 1.1588ms

    Overextended
    \ No newline at end of file diff --git a/oxmysql/issues.html b/oxmysql/issues.html index 055109c7ee..cf1029a49b 100644 --- a/oxmysql/issues.html +++ b/oxmysql/issues.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Common Issues

    Common Issues

    +
    Common Issues

    Common Issues

    Unable to establish a connection

    This is usually the result of incorrect database settings or your password containing reserved characters.
    ; , / ? : @ & = + $ # are reserved.

    @@ -25,4 +25,4 @@

    Numbers treated as string

    To resolve this issue simply enable decimalNumbers in your connection string, ie. mysql://root@localhost/essentialmode?decimalNumbers=true.

    ⚠️

    JavaScript treats all numbers as floats, so a double or decimal value will be cast as a float with this setting. -Numbers will have less precision when this setting is enabled.


    Overextended
    \ No newline at end of file +Numbers will have less precision when this setting is enabled.


    Overextended
    \ No newline at end of file diff --git a/oxmysql/placeholders.html b/oxmysql/placeholders.html index 58db77a898..f36bbb0b83 100644 --- a/oxmysql/placeholders.html +++ b/oxmysql/placeholders.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Placeholders

    Placeholders

    +
    Placeholders

    Placeholders

    Placeholders allow for query parameters to be safely executed, preventing common SQL injection methods (opens in a new tab).

    Parameters can be passed an an array or map (referred to as named named parameters).

    local identifier = 'license:abc123'
    @@ -24,4 +24,4 @@
         group = group
         identifier = identifier
     })
    -

    These are distinct from prepared statements which are handled by the MySQL server; you can use MySQL.prepare for more optimised and secure queries.


    Overextended
    \ No newline at end of file +

    These are distinct from prepared statements which are handled by the MySQL server; you can use MySQL.prepare for more optimised and secure queries.


    Overextended
    \ No newline at end of file diff --git a/oxmysql/ui.html b/oxmysql/ui.html index d26badd7d1..2e2db0075f 100644 --- a/oxmysql/ui.html +++ b/oxmysql/ui.html @@ -11,7 +11,7 @@ --nextra-primary-hue: 200deg; --nextra-primary-saturation: 100%; } -
    Using the Debug UI

    Using the Debug UI

    +
    Using the Debug UI

    Using the Debug UI

    The debug UI lets you easily see all the queries that have been executed by resources, query response times, and per-resource statistics. You should only enable this during development, or with a small player count - for larger servers, look into builtin MySQL logging.

    @@ -29,4 +29,4 @@

    Columns can be sorted by ascending and descending order, and hovering over a query will display the full query inside a tooltip.

    Queries that exceed mysql_slow_query_warning (default 150ms) are displayed in orange.
    For demonstation purposes the mysql_slow_query_warning convar was set to 5 here.

    -

    oxmysql_ui_queries


    Overextended
    \ No newline at end of file +

    oxmysql_ui_queries


    Overextended
    \ No newline at end of file diff --git a/sitemap.xml b/sitemap.xml index 8f5d96e594..af55e54b07 100644 --- a/sitemap.xml +++ b/sitemap.xml @@ -1,109 +1,110 @@ -https://overextended.dev2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/guides/git2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/guides/nodejs2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/guides/pnpm2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/guides/types2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/guides/vscode2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Client/Player2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Client/Player/callbacks2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Client/Player/events2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Client/functions2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Server/Player2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Server/Player/events2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Server/Player/methods2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Server/Vehicle2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Server/Vehicle/callbacks2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Server/Vehicle/methods2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/Server/functions2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_core/concepts2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_doorlock2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_doorlock/Client/functions2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_doorlock/Server/events2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_doorlock/Server/functions2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_doorlock/settings2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_fuel2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_fuel/Client/functions2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_fuel/Server/functions2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_fuel/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Events/Client2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Events/Server2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Frameworks/esx2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Frameworks/qb2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Functions/Client2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Functions/Server2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Functions/Server/Hooks2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Guides/crafting2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Guides/creatingItems2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Guides/metadata2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Guides/shops2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/Guides/stashes2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_inventory/issues2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/ACL/Server2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/AddCommand/Server2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/AddKeybind/Client2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Cache/Client2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Cache/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Callback/JavaScript/Client2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Callback/JavaScript/Server2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Callback/Lua/Client2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Callback/Lua/Server2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Class/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Cron/Server2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/DisableControls/Client2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/GetClosestObject/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/GetClosestPed/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/GetClosestPlayer/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/GetClosestVehicle/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/GetNearbyObjects/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/GetNearbyPeds/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/GetNearbyPlayers/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/GetNearbyVehicles/Shared2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/alert2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/clipboard2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/context2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/input2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/menu2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/notify2024-01-20T17:00:10.538Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/progress2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/radial2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/skillcheck2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Interface/Client/textui2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Locale/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Logger/Server2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Math/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Points/JavaScript/Client2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Points/Lua/Client2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Print/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Raycast/Client2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Require/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Streaming/Client2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/String/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Table/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/VehicleProperties/Client2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Version/Server2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Version/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/WaitFor/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_lib/Modules/Zones/Shared2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_target2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_target/Functions/Client2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/ox_target/Options2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/Functions/insert2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/Functions/prepare2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/Functions/query2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/Functions/rawExecute2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/Functions/scalar2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/Functions/single2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/Functions/transaction2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/Functions/update2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/benchmark2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/issues2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/placeholders2024-01-20T17:00:10.539Zdaily0.7 -https://overextended.dev/oxmysql/ui2024-01-20T17:00:10.539Zdaily0.7 +https://overextended.dev2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/guides/git2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/guides/nodejs2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/guides/pnpm2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/guides/types2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/guides/vscode2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Client/Player2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Client/Player/callbacks2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Client/Player/events2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Client/functions2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Server/Player2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Server/Player/events2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Server/Player/methods2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Server/Vehicle2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Server/Vehicle/callbacks2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Server/Vehicle/methods2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/Server/functions2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_core/concepts2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_doorlock2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_doorlock/Client/functions2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_doorlock/Server/events2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_doorlock/Server/functions2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_doorlock/settings2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_fuel2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_fuel/Client/functions2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_fuel/Server/functions2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_fuel/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Events/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Events/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Frameworks/esx2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Frameworks/qb2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Functions/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Functions/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Functions/Server/Hooks2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Guides/crafting2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Guides/creatingItems2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Guides/metadata2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Guides/shops2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/Guides/stashes2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_inventory/issues2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/ACL/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/AddCommand/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/AddKeybind/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Cache/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Cache/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Callback/JavaScript/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Callback/JavaScript/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Callback/Lua/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Callback/Lua/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Class/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Cron/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/DisableControls/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/GetClosestObject/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/GetClosestPed/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/GetClosestPlayer/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/GetClosestVehicle/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/GetNearbyObjects/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/GetNearbyPeds/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/GetNearbyPlayers/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/GetNearbyVehicles/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/alert2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/clipboard2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/context2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/input2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/menu2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/notify2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/progress2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/radial2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/skillcheck2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Interface/Client/textui2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Locale/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Logger/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Marker/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Math/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Points/JavaScript/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Points/Lua/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Print/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Raycast/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Require/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Streaming/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/String/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Table/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/VehicleProperties/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Version/Server2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Version/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/WaitFor/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_lib/Modules/Zones/Shared2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_target2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_target/Functions/Client2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/ox_target/Options2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/Functions/insert2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/Functions/prepare2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/Functions/query2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/Functions/rawExecute2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/Functions/scalar2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/Functions/single2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/Functions/transaction2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/Functions/update2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/benchmark2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/issues2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/placeholders2024-02-07T03:15:44.742Zdaily0.7 +https://overextended.dev/oxmysql/ui2024-02-07T03:15:44.742Zdaily0.7 \ No newline at end of file