# Zyke Resources Documentation > Documentation for Zyke Resources' products. Source: Zyke-Resources/gitbook@6017f20 Generated: 2026-05-31T14:16:50.508Z ## Machine-Readable Exports - [llms.txt](https://docs.zykeresources.com/llms.txt) - [Structured docs export](https://docs.zykeresources.com/api/docs/export) - [Search index](https://docs.zykeresources.com/api/search) ## Table of Contents - [Introduction](#page-readme) - [Common Issues](#page-common-issues) - [Issues Regarding zyke_lib](#page-common-issues-zyke-lib-error) - [Lacking Entitlement](#page-common-issues-lacking-entitlement) - [Resource Starting Sequence](#page-common-issues-resource-starting-sequence) - [Item Not Usable](#page-common-issues-item-not-usable) - [Invalid Files](#page-common-issues-invalid-files) - [QB & ox_inv Issues](#page-common-issues-qb-and-ox-inv-issues) - [Dependency Override](#page-common-issues-dependency-override) - [UI Not Mounting](#page-common-issues-ui-not-mounting) - [Any other issues?](#page-common-issues-any-other-issues) - [FAQ](#page-faq) - [Miscellaneous](#page-faq-miscellaneous) - [Inventory Support](#page-faq-inventory-support) - [Target Support](#page-faq-target-support) - [Discord Webhooks / Logs](#page-faq-discord-webhooks-logs) - [Consumables](#page-paid-resources-consumables) - [Resource Description](#page-paid-resources-consumables-resource-description) - [Config](#page-paid-resources-consumables-config) - [Exports & Events](#page-paid-resources-consumables-exports-and-events) - [Dependencies](#page-paid-resources-consumables-dependencies) - [Changelog](#page-paid-resources-consumables-changelog) - [Guides](#page-paid-resources-consumables-guides) - [World- & Player Interaction](#page-paid-resources-consumables-guides-world-and-player-interaction) - [Packs](#page-paid-resources-consumables-guides-packs) - [Ingredient-based Items](#page-paid-resources-consumables-guides-ingredient-based-items) - [Conversions](#page-paid-resources-consumables-guides-conversions) - [Consumption Rewards](#page-paid-resources-consumables-guides-consumption-rewards) - [Setup](#page-paid-resources-consumables-setup) - [Caveats](#page-paid-resources-consumables-caveats) - [Smoking](#page-paid-resources-smoking) - [Resource Description](#page-paid-resources-smoking-resource-description) - [Config](#page-paid-resources-smoking-config) - [Exports & Events](#page-paid-resources-smoking-exports-and-events) - [Examples](#page-paid-resources-smoking-examples) - [Dependencies](#page-paid-resources-smoking-dependencies) - [Changelog](#page-paid-resources-smoking-changelog) - [Test Server](#page-paid-resources-smoking-test-server) - [Setup](#page-paid-resources-smoking-setup) - [Garages](#page-paid-resources-garages) - [Resource Description](#page-paid-resources-garages-resource-description) - [Config](#page-paid-resources-garages-config) - [Exports & Events](#page-paid-resources-garages-exports-and-events) - [Transfer Ownership](#page-paid-resources-garages-exports-and-events-transfer-ownership) - [Can-Check Hooks](#page-paid-resources-garages-exports-and-events-can-check-hooks) - [Dependencies](#page-paid-resources-garages-dependencies) - [Changelog](#page-paid-resources-garages-changelog) - [Guides](#page-paid-resources-garages-guides) - [Profession Vehicles](#page-paid-resources-garages-guides-profession-vehicles) - [Setup](#page-paid-resources-garages-setup) - [Common Issues](#page-paid-resources-garages-common-issues) - [Drugdealer](#page-paid-resources-drugdealer) - [Resource Description](#page-paid-resources-drugdealer-resource-description) - [Config](#page-paid-resources-drugdealer-config) - [Exports & Events](#page-paid-resources-drugdealer-exports-and-events) - [Dependencies](#page-paid-resources-drugdealer-dependencies) - [Changelog](#page-paid-resources-drugdealer-changelog) - [Crafting](#page-paid-resources-crafting) - [Resource Description](#page-paid-resources-crafting-resource-description) - [Config](#page-paid-resources-crafting-config) - [Exports & Events](#page-paid-resources-crafting-exports) - [Dependencies](#page-paid-resources-crafting-dependencies) - [Changelog](#page-paid-resources-crafting-changelog) - [Guides](#page-paid-resources-crafting-guides) - [Blueprints](#page-paid-resources-crafting-guides-blueprints) - [Plants](#page-paid-resources-plants) - [Resource Description](#page-paid-resources-plants-resource-description) - [Config](#page-paid-resources-plants-config) - [Exports & Events](#page-paid-resources-plants-exports) - [Dependencies](#page-paid-resources-plants-dependencies) - [Changelog](#page-paid-resources-plants-changelog) - [Mugging](#page-paid-resources-mugging) - [Resource Description](#page-paid-resources-mugging-resource-description) - [Config](#page-paid-resources-mugging-config) - [Exports & Events](#page-paid-resources-mugging-exports-and-events) - [Changelog](#page-paid-resources-mugging-changelog) - [Zyke Lib](#page-free-resources-zyke-lib) - [Resource Description](#page-free-resources-zyke-lib-resource-description) - [Dependencies](#page-free-resources-zyke-lib-dependencies) - [Config](#page-free-resources-zyke-lib-config) - [Setup](#page-free-resources-zyke-lib-setup) - [Changelog](#page-free-resources-zyke-lib-changelog) - [Guides](#page-free-resources-zyke-lib-guides) - [Missing GTX Label](#page-free-resources-zyke-lib-guides-missing-gtx-label) - [Interface API](#page-free-resources-zyke-lib-guides-interface-api) - [Status](#page-free-resources-status) - [Resource Description](#page-free-resources-status-resource-description) - [Exports & Events](#page-free-resources-status-exports-and-events) - [Dependencies](#page-free-resources-status-dependencies) - [Changelog](#page-free-resources-status-changelog) - [Guides](#page-free-resources-status-guides) - [Editing Statuses](#page-free-resources-status-guides-editing-statuses) - [Direct Effects](#page-free-resources-status-guides-direct-effects) - [Broken Values & HUD](#page-free-resources-status-guides-broken-values-and-hud) - [Setup](#page-free-resources-status-setup) - [Propaligner](#page-free-resources-propaligner) - [Resource Description](#page-free-resources-propaligner-resource-description) - [Exports & Events](#page-free-resources-propaligner-exports-and-events) - [Dependencies](#page-free-resources-propaligner-dependencies) - [Changelog](#page-free-resources-propaligner-changelog) - [Realistic Vehicles](#page-free-resources-realistic-vehicles) - [Resource Description](#page-free-resources-realistic-vehicles-resource-description) - [Config](#page-free-resources-realistic-vehicles-config) - [Exports & Events](#page-free-resources-realistic-vehicles-exports-and-events) - [Changelog](#page-free-resources-realistic-vehicles-changelog) - [Vending Machines](#page-free-resources-vending-machines) - [Resource Description](#page-free-resources-vending-machines-resource-description) - [Config](#page-free-resources-vending-machines-config) - [Dependencies](#page-free-resources-vending-machines-dependencies) - [Changelog](#page-free-resources-vending-machines-changelog) - [Sounds](#page-free-resources-sounds) - [Resource Description](#page-free-resources-sounds-resource-description) - [Config](#page-free-resources-sounds-config) - [Exports & Events](#page-free-resources-sounds-exports-and-events) - [Changelog](#page-free-resources-sounds-changelog) - [Key Minigame](#page-free-resources-key-minigame) - [Resource Description](#page-free-resources-key-minigame-resource-description) - [Exports & Events](#page-free-resources-key-minigame-exports-and-events) - [Changelog](#page-free-resources-key-minigame-changelog) - [Stabwheels](#page-free-resources-stabwheels) - [Resource Description](#page-free-resources-stabwheels-resource-description) - [Dependencies](#page-free-resources-stabwheels-dependencies) - [Changelog](#page-free-resources-stabwheels-changelog) - [Burncars](#page-free-resources-burncars) - [Resource Description](#page-free-resources-burncars-resource-description) - [Dependencies](#page-free-resources-burncars-dependencies) - [Changelog](#page-free-resources-burncars-changelog) ## Pages ### Introduction Canonical URL: https://docs.zykeresources.com/ Markdown URL: https://docs.zykeresources.com/readme.md # Introduction ## Links - [Discord Community](https://discord.zykeresources.com) - [Tebex Store](https://zykeresources.com/) - [YouTube](https://youtube.com/@zykeresources) - [FiveM Forum Profile](https://forum.cfx.re/u/zyke/summary) ### Common Issues Canonical URL: https://docs.zykeresources.com/common-issues Markdown URL: https://docs.zykeresources.com/common-issues.md # Common Issues ### Issues Regarding zyke_lib Canonical URL: https://docs.zykeresources.com/common-issues/zyke_lib-error Markdown URL: https://docs.zykeresources.com/common-issues/zyke_lib-error.md # Issues Regarding zyke\_lib ## No such export Fetch in resource zyke\_lib ### Starting zyke\_lib in the wrong place The most common issue when getting errors regarding zyke\_lib is that it's started in the wrong place. The simplest fix for this is to place it right under it's dependencies, which at the time of writing this is the framework file. Placing it above everything else ensures that you didn't miss anything. If you do however have other dependencies, placing "zyke\_lib" above "zyke\_x" scripts will be fine. Please note that simple mistakes can happen. If you for example placed "zyke\_drugdealer" inside of "\[qb]" folder, then you start "zyke\_lib" above starting "zyke\_drugdealer", but below starting "\[qb]", you will get an error because "zyke\_drugdealer" has been started above "zyke\_lib" since it existed inside of the "\[qb]" folder. ### Incorrect name for zyke\_lib When downloading from Github, your folder will automatically be named "x-master". This means that "zyke\_lib" will be named "zyke\_lib-master". When using exports, the server is looking for af older named "zyke\_lib", which means that it can't find the correct folder. Simply change the name of your folder and your issue should be resolved. ## Attempt to call a nil value ### What does this mean? When developing, Zyke Resources will use the latest versions available. This means that if you're running an older server your functions may not align with the newly available ones. Inside of "zyke\_x" scripts, we trigger functions inside of "zyke\_lib" which will then trigger the correct function for your framework. This means that if you're missing the function that is triggered by default, you can swap them out for functions that works for your version. Please note that this can also occur on newer servers that are running custom inventories, custom progressbars etc that are not default for your framework, following the same guide as above will also fix this. ### Lacking Entitlement Canonical URL: https://docs.zykeresources.com/common-issues/lacking-entitlement Markdown URL: https://docs.zykeresources.com/common-issues/lacking-entitlement.md # Lacking Entitlement ### Why does this happen? In order to use my resources you need a valid license to my resource connected to the [license key](https://keymaster.fivem.net/) you're using for your server. ### Just purchased the resource If you purchased a resource, dropped it in, refreshed and started it and this message appears, you have to restart the server. After restart, the issue should be resolved. ### My friend sent me the file As stated above, you need a valid license. This means that if you're sent my files, you would also be required to have the license transferred. ### Still having issues If you're still having issues, despite completing all of the steps above, please open a ticket in our [Discord](https://discord.gg/UaXtUFRr66). It is a possibility that FiveMs validators are currently down, so if you want to double check the payment and license, head over to the Discord. The link can be found in [introduction ](../)or [here](https://discord.gg/UaXtUFRr66). ### Resource Starting Sequence Canonical URL: https://docs.zykeresources.com/common-issues/resource-starting-sequence Markdown URL: https://docs.zykeresources.com/common-issues/resource-starting-sequence.md # Resource Starting Sequence To ensure our resources run smoothly, we have to explicitly verify that our resources are being correctly started. This is not always needed, it entirely depends on your server and the resources you are running. Below you will find various common issues and our fixes for your server.cfg structure. ## Starting Entire Directories First up, a very common practice to start a lot of resources. Starting an entire directory, also known as a folder, can prove problematic. It attempts to start the resources in an alphabetic order, meaning any resource alphabetically before the `l` in `zyke_lib` will attempt to start first. This can cause various issues. Make sure that you are starting every resource manually in the server.cfg. This means that if you are currently starting your resources something like this: ```lua ensure [zyke] ``` You have to instead run them like this: ```lua ensure zyke_lib ensure zyke_sounds ensure zyke_smoking ... ``` ## Starting Before Dependencies If you are using resources such as `ox_inventory` or perhaps some death system, such as `wasabi_ambulance`, our library needs to be started afterwards to ensure the dependencies are correctly recognized. Our best recommendation is that you start `zyke_lib` at the end of your starting sequence, and all of your other resources from us after that. This ensures that everything is propertly started before. ### Item Not Usable Canonical URL: https://docs.zykeresources.com/common-issues/item-not-usable Markdown URL: https://docs.zykeresources.com/common-issues/item-not-usable.md # Item Not Usable ### Universal * Item may be required to be unique / non-stackable. For example, blueprints, smokable packs, consumables packs, vapes, bongs. Any item that has to carry metadata (info inside the item) must be unique / non-stackable. ### ox\_inventory * If you are using ox\_inventory & QBCore, checkout [qb-and-ox\_inv-issues.md](/common-issues/qb-and-ox_inv-issues "mention") for the most common issues. * If you have an item with `consume = x` in the item config at `ox_inventory/data/items.lua`, remove that line. This is the most common reason for unusable items. ### Invalid Files Canonical URL: https://docs.zykeresources.com/common-issues/invalid-files Markdown URL: https://docs.zykeresources.com/common-issues/invalid-files.md # Invalid Files ### Incorrect Resource Name The most common issue with the UI not showing is because you renamed the script without going into the JavaScript file and matching that name in there. By default, everything is set up to work with the name that I sell the script as. If you do change the resource's name, make sure to also change it in the files. ### Downloading Source Files If you have been sent here, most likely you have incorrect files on your server. We build our UI files which means the source code is not ready to be ran on your server. This section specifically covers the fix for the console spamming about missing UI build. Another big reason for downloading the latest release is because that has been tested. We may have breaking changes in the latest files straight in the repository that are not guaranteed to work for all of our resources. #### Examples When downloading zyke\_propaligner, head into the release page and download the option with the exact name of the resource. If you download it from any other resource, it is not guaranteed that you have the correct files. Note that you need to download the `.zip`, and not the one named `Source code ...`. The `Source code ...` will give you the files without the built files.
#### Links * [Latest zyke\_lib](https://github.com/ZykeWasTaken/zyke_lib/releases) * [Latest zyke\_status](https://github.com/ZykeWasTaken/zyke_status/releases) * [Latest zyke\_propaligner](https://github.com/ZykeWasTaken/zyke_propaligner/releases) * [Latest zyke\_sounds](https://github.com/ZykeWasTaken/zyke_sounds/releases) * [Latest zyke\_keyminigame](https://github.com/ZykeWasTaken/zyke_keyminigame/releases) * [Latest zyke\_vehdeformation](https://github.com/ZykeWasTaken/zyke_vehdeformation/releases) * [Latest zyke\_burncars](https://github.com/ZykeWasTaken/zyke_burncars/releases) * [Latest zyke\_stabwheels](https://github.com/ZykeWasTaken/zyke_stabwheels) (No release download needed) ### Missing Files When uploading using FTP (WinSCP, FileZilla etc), some files may disappear. The easiest identifier of a missing file is the server console warning it could not find certain files. This error will show up right when you start the resource. If you are unsure if you are missing any files, simply restart the resource and the console will let you know. The fix is rather simple - reupload the missing file by itself and place it into the correct folder.
### QB & ox_inv Issues Canonical URL: https://docs.zykeresources.com/common-issues/qb-and-ox_inv-issues Markdown URL: https://docs.zykeresources.com/common-issues/qb-and-ox_inv-issues.md # QB & ox\_inv Issues This is an experimental fix that I put together after having repeated issues with users following outdated guides for this setup. This issue is not present for all servers with such setups, it depends on versioning and whatnot. We **do not** assist with fixing your inventory. QBCore & ox\_inventory has never been 100% compatible, and most guides out there are outdated and they got no clue what is going on. We are not going to put together a whole guide for the entire process. This snippet is simply intended to fix a specific broken link that users seem to stumble upon. ### The Fix: Navigate into `ox_inventory/modules/bridge/qb/server.lua` and find the `server.UseItem` function. Replace the entire function with the snippet below: ```lua function server.UseItem(source, itemName, data) local itemData = QBCore.Functions.CanUseItem(itemName) if type(itemData) == "table" and itemData.func then itemData.func(source, data) end end ``` ### Dependency Override Canonical URL: https://docs.zykeresources.com/common-issues/dependency-override Markdown URL: https://docs.zykeresources.com/common-issues/dependency-override.md # Dependency Override By default, `zyke_lib` automatically detects which systems you are running (framework, inventory, target, etc.). If auto-detection fails or you want to explicitly specify a system, you can configure this in `dependency_override.lua`. ### Common Issues First, we will cover common issues in case you were led here and don't want to submerge yourself in the configs. #### X is taking a long time to start... If you have a misconfigured system and keep a bunch of old files on your server, you may experience a wall of warnings in your consoles waiting for other systems to start. This issue could often arise if you keep two scripts that we both support, like two fuelsystems, in your server, even if you are just using one of them. Our lib will, by default, attempt to wait for the resource to start. ### Configurations Each system supports the following values: | Value | Description | | ------------------- | ---------------------------------------------------------------------- | | `"auto"` | Automatically detect which system to use **(default)** | | `""` | Use a specific resource (will wait for it to start) | | `"none"` | Skip detection entirely, fall back to your framework's built-in system | > [!WARNING] > `"none"` is only valid for **optional** systems (gang, fuel, death, banking). Setting it means the library will use your framework's default behavior instead. These must always resolve to a valid resource. | System | Options | | ----------- | ----------------------------------------------------------------------------------------------------------- | | `framework` | `"auto"`, `"es_extended"`, `"qb-core"` | | `inventory` | `"auto"`, `"qs-inventory"`, `"ox_inventory"`, `"tgiann-inventory"`, `"codem-inventory"`, `"core_inventory"` | | `target` | `"auto"`, `"ox_target"`, `"qb-target"` | #### Optional Systems These can be set to `"none"` to use your framework's built-in system. | System | Options | | --------- | ------------------------------------------------------------------------------------------ | | `gang` | `"auto"`, `"none"`, `"zyke_gangs"` | | `fuel` | `"auto"`, `"none"`, `"ox_fuel"`, `"LegacyFuel"`, `"cdn-fuel"`, `"lc_fuel"` | | `death` | `"auto"`, `"none"`, `"wasabi_ambulance"` | | `banking` | `"auto"`, `"none"`, `"Renewed-Banking"`, `"RxBanking"`, `"okokBanking"`, `"bablo-banking"` | #### Example > Full configuration example for `dependency_override.lua`:
> > ```lua > return { > framework = "auto", > inventory = "ox_inventory", > target = "auto", > > gang = "none", > fuel = "ox_fuel", > death = "auto", > banking = "none", > } > ``` ### **Troubleshooting** If your server gets stuck on the dependency loading step, set the appropriate system to the exact resource name you use instead of `"auto"`.
### UI Not Mounting Canonical URL: https://docs.zykeresources.com/common-issues/ui-not-mounting Markdown URL: https://docs.zykeresources.com/common-issues/ui-not-mounting.md # UI Not Mounting If you are attempting to open one of our UIs and get something along the lines of "UI Not Mounted" as feedback, something is stuck. You can have false alarms if the script is genuinely still loading, but if you wait for 10+ seconds, check your client (F8)- & server console for errors. If you have errors, the UI won't be able to fetch what it needs and will stay in this loading state. Create a ticket in our [Discord](https://discord.zykeresources.com) for assistance. ### Any other issues? Canonical URL: https://docs.zykeresources.com/common-issues/any-other-issues Markdown URL: https://docs.zykeresources.com/common-issues/any-other-issues.md # Any other issues? If you are having issues that are not listed in this section, please open a ticket in our [Discord](https://discord.gg/UaXtUFRr66). ### FAQ Canonical URL: https://docs.zykeresources.com/faq Markdown URL: https://docs.zykeresources.com/faq.md # FAQ Please visit the sub-pages. ### Miscellaneous Canonical URL: https://docs.zykeresources.com/faq/miscellaneous Markdown URL: https://docs.zykeresources.com/faq/miscellaneous.md # Miscellaneous ### Switch Language Language switches are made in `zyke_lib/config.lua` under the language value. Set this to the language you want to use, and if it doesn't exist, it will fall back to the `en.lua` file, so it is always safe to set this to a translation that exists in one resource but not in another. You can see a list of supported languages for each resource in the resource's `locales` directory. ### Are any of the files locked? In all of our resources we protect ourselves from unauthorized distribution by using Tebex's Escrow technology which allows us to lock the core functionalities. At the same time we are open for customization in our resource with various unlocked files, access to change various functions in zyke\_lib and large configuration files. If you have any questions about a specific resource, we are happy to help you in our [Discord](https://discord.zykeresources.com/). If you want to learn more about how Escrow works, you can read more [here](https://forum.cfx.re/t/introducing-asset-escrow-for-your-resources/4777151). ### Can I purchase the source code? No. We do not offer source code for any resources for the reason above. ### How do I claim my resource? First, head over to your [Keymaster](https://keymaster.fivem.net/) and log into the cfx.re (FiveM) account you purchased the script with. When you've logged in, head over to [Granted Assets](https://keymaster.fivem.net/asset-grants) and you will be shown a menu will all of your assets (resources, scripts, props etc). ### Do you take suggestions? Yes, we happily take suggestions, for both new resource ideas and feature ideas for older resources! All you have to do is head over to our [Discord](https://discord.zykeresources.com/), go into the [suggestions ](https://discord.com/channels/925195604068565003/1056209989590601809)channel and share your thoughts! ### Can I switch framework for the scripts I have purchased? Yes. This is because all of our resources are dependant on [zyke\_lib](https://github.com/ZykeWasTaken/zyke_lib). You can change all framework dependencies in our library. Since version 1.0.0 your framework gets fetched automatically. This allows for an easy drag-and-drop straight from one framework to another. ### What is a starting sequence? When script depend on eachother for functionality, you need to verify your resources are starting in the correct order. Sometimes you can run almost any starting sequence, but when you start including more advanced resources in your server, you may need to get more specific. The usual suspect is that you are starting entire folders at once, and your resources may start in the wrong sequence. One resource that depends on another is queued first, and it all breaks. When you start your server, the easiest way to tell if a dependency is not started is to have a look in the server console. It will explicitly tell you that your resource is missing dependencies. If a support is asking you to provide your resource starting sequence, what you need to provide is a part of your server.cfg file so we can analyze it. We do not need the entire file, none of your personal keys etc. All we need is the list of all of your resources starting. Additionally, we may ask for the structures of your folders to see where each resource starts. **Our recommendation** is that you start zyke\_lib at the bottom of your starting sequence, and all other zyke resources after that. This ensures that each resource is explicitly started in the correct order, and will not cause issues. ### Script Version To check a script version, open up the script folder and look for the fxmanifest.lua file. In this file, usually somewhere at the top, you will find a "version" text, describing what version your resource is. ### What VSCode extensions do you use? This is sort of unrelated, but after receiving this question a few times, I thought I would link the VSCode extensions that I use. I do exclude very unrelated ones from this list. Please keep in mind that some of these are mainly meant for developers, and won't really benefit the average person changing stuff in the config or making minor changes in some file. Another headsup, specifically for the FiveM related ones, some natives have bad data type definitions, and can require/return incorrect values, along with accepting values that seems incorrect. It may be that your code is warning you yet it still works. #### These are in random order and not based on importance: * [https://marketplace.visualstudio.com/items?itemName=usernamehw.errorlens](https://marketplace.visualstudio.com/items?itemName=usernamehw.errorlens) * [https://marketplace.visualstudio.com/items?itemName=dhawton.fivem-lua](https://marketplace.visualstudio.com/items?itemName=dhawton.fivem-lua) * [https://marketplace.visualstudio.com/items?itemName=thirst.cfxlua-typings](https://marketplace.visualstudio.com/items?itemName=thirst.cfxlua-typings) * [https://marketplace.visualstudio.com/items?itemName=sumneko.lua](https://marketplace.visualstudio.com/items?itemName=sumneko.lua) #### Extras - not related to Lua or FiveM: * [https://marketplace.visualstudio.com/items?itemName=johnpapa.vscode-peacock](https://marketplace.visualstudio.com/items?itemName=johnpapa.vscode-peacock) * For those that find tabbing between multiple instances confusing, I usually color code them. For ex. red overlay means my lib. Speeds up trying to find the correct tab. * [https://marketplace.visualstudio.com/items?itemName=zhuangtongfa.Material-theme](https://marketplace.visualstudio.com/items?itemName=zhuangtongfa.Material-theme) * The best theme collection, I use the "One Dark Pro Darker" theme from this collection. ### Inventory Support Canonical URL: https://docs.zykeresources.com/faq/inventory-support Markdown URL: https://docs.zykeresources.com/faq/inventory-support.md # Inventory Support > [!INFO] > If your inventory is not listed here, it may still work if it's backwards-compatible with one of the supported systems. Create a ticket in our Discord for assistance. There may be changes for specific resources, view each resource's dependencies carefully before purchasing. | Inventory | Support Level | Notes | | -------------------------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | Regular QBCore inventories | Full | Variations like ps or ak47 may be incompatible since they are no longer following the standard procedures. Please consult us in our [Discord](https://discord.zykeresources.com) before purchase if you are unsure. | | ox\_inventory | Full | | | qs-inventory | Full | | | TGIANN-inventory | Full | | | codem-inventory | Full | | | core\_inventory | Full | QBCore only | ### Target Support Canonical URL: https://docs.zykeresources.com/faq/target-support Markdown URL: https://docs.zykeresources.com/faq/target-support.md # Target Support | Target System | Support Level | Notes | | ------------- | ------------- | ----- | | ox\_target | Full | | | qb-target | Full | | We are now using a most-fitting approach for our releases, which means some features may require a target system if it fits the best. Not all resources require a target system — check each resource's dependencies page. ### Discord Webhooks / Logs Canonical URL: https://docs.zykeresources.com/faq/discord-webhooks-logs Markdown URL: https://docs.zykeresources.com/faq/discord-webhooks-logs.md # Discord Webhooks / Logs ### How does it work? All of our resources trigger logs for various actions. This entire system resides in zyke\_lib, and can be completely swapped out if wanted. All types, inputs and such that are used are documented, and you must work within these limits if you want to have a preditcible outcome if you swap out the system. We do not provide support for swapping this mechanic out for anything else, but you are free to do so by yourself. #### Relevant Files: * `zyke_lib/functions/log/server.lua` (Entire logging mechanic) * `zyke_lib/webhooks/*.lua` (Action routing list, this is where you put your Discord webhooks) ### Zyke Lib Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib.md # Zyke Lib ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib/resource-description.md # Resource Description ## Links * [Download](https://github.com/ZykeWasTaken/zyke_lib/releases) ## Information Yet another library you have to download from a script creator? Yes, but it has it's benefits. Zyke Lib is a dependency for all my resources released or updated after this was released. Thanks to zyke\_lib, the limitations of what framework you prefer are now gone. What does it actually do? Here's the breakdown: * It eliminates the need of copying snippets around from project to project, all you have to do is import zyke\_lib using it's export. This feature is for loading animations, displaying texts etc. * The script that uses zyke\_lib becomes totally framework independent. This means that you can, in theory, use any server for my resources as long as you adapt it to zyke\_lib. Of course you can't just plug in vRP and hope everything works, but you can switch out ESX/QBCore's version of, for example fetching the character identifier, for your own server's way of doing this. However, this is not a perfect solution as ESX/QBCore may have limitations that your custom framework does not, hence me never implementing a specific feature, but in most cases this solution helps both the script creator as well as the customer to make the script more available. * How does the statement above work? zyke\_lib is basically a "hub" for choosing the correct function based on your configuration. In my resources, I type "z.GetPlayer(x)" and pass in a source or identifier, zyke\_lib will then use the correct function based on my configuration, meaning that as long as you configure zyke\_lib to your framework, my script will work for any framework, no matter how custom it is. * You can use this in any resource. If you're creating your own scripts you can utilize zyke\_lib by using it's functions, a good example is drawing 3d texts. By using Zyke Lib's function you only have to change values in one location and it's changed in all your resources using it. You can find the repository [here](https://github.com/ZykeWasTaken/zyke_lib). ### Dependencies Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib/dependencies Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib/dependencies.md # Dependencies ### Click the names to be redirected * [ESX](https://github.com/esx-framework)/[QBCore](https://github.com/qbcore-framework)/[Qbox](https://github.com/Qbox-project) * [ox\_lib](https://github.com/overextended/ox_lib) (Optional) * [OxMySQL](https://github.com/overextended/oxmysql) ### Config Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib/config Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib/config.md # Config ### Debug > Debug should only be used for development and tracing issues. As a server owner you can ignore this value, unless told otherwise. Enabling debugging will allow transparency, printing the values you are using, and what might have went wrong.\ > \ > **Example:** > > ```lua > debug = false > ``` ### Language > The language translations to use throughout all of our resources.\ > \ > **Example:** > > ```lua > language = "en" > ``` ### Locale String > When translating values such as numbers and timestamps there are various approaches based on your language. Enter your language code in here for accurate translations throughout our resources.\ > \ > [https://en.wikipedia.org/wiki/IETF\_language\_tag#List\_of\_common\_primary\_language\_subtags](https://en.wikipedia.org/wiki/IETF_language_tag#List_of_common_primary_language_subtags)\ > \ > **Example:** > > ```lua > localeString = "en" > ``` ### Setup Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib/setup Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib/setup.md # Setup ## Information This guide will cover everything you need to know in order to set up your zyke\_lib resource. If you wish to have this guide expanded further or you need assistance, please open a ticket in our Discord. ## Config The first step is to head over to zyke\_lib/shared/config.lua. This file is your main configuration. If you wish to understand all values, they are explained in [config.md](/free-resources/zyke-lib/config "mention"). ## Fetching framework Your framework will fetch automatically, since the v1.0.0 release. However, if this doesn't work you may need to add your framework manually.\ \ Head into zyke\_lib/shared/framework.lua, in here you can configure the way your framework fetches as well as your file name. Note that the framework needs to be labeled either "QBCore" or "ESX", but you can change the way the framework fetches.\ \ If you need further assistance, please visit our \[Discord]\([https://discord.zykeresources.com](https://discord.zykeresources.com/)). ## Other If you are experiencing issues using any of our resources, we recommend going through our functions and syncing them with your server modifications. Servers that use custom inventories, progressbars etc may require other values, which you would need to add yourself. ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib/changelog Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib/changelog.md # Changelog
Changelog - Version 2.6.4 ## Changes * Improved the drawText function with new customization options and a fix for left justification. * Added an `rgba` parameter to set text color. * Added an `options.dropShadow` option to enable a drop shadow (off by default). * Added an `options.edge` option to disable the text edge (on by default). * Added an `options.outline` option to disable the text outline (on by default). * Added a clamp utility function to restrict a number within a given range. ## Files Affected * functions/drawText/client.lua * functions/numbers/shared.lua * fxmanifest.lua

2026-05-29 01:09 CET

Changelog - Version 2.6.3 ## Changes * Added a native DUI management module for safe creation and resource tracking of runtime DUIs. * Improved notification system with ox_lib routing support and new position parameter. * Notification translations now return an optional 'position' field to control UI placement. * Introduced a dependency override option to force a specific notification system (ox_lib, none, auto). ## Files Affected * nui/\* * README.md * dependency\_override.lua * functions/dui/client.lua * functions/notify/client.lua * functions/notify/server.lua * loader.lua * systems/notification.lua * translations.lua * fxmanifest.lua
Changelog - Version 2.6.2 ## Changes * Fixed context menu flickering when hovering over options that load images, by ensuring only the most recent hover request updates the selection. * Fixed context menu options losing hover state when an image fails to load; the metadata popup now continues to show without the broken image. * Fixed hover state not updating when context menu options change while the cursor is hovering over them. * Fixed stale hover metadata staying visible when navigating between context menus (e.g., opening a submenu or going back). * Improved image loading in the context menu: a placeholder icon is now shown while images load, replacing it only after a successful load to prevent empty spaces or abrupt appearances. * Fixed disabled and read-only context menu options not visually indicating their state; icons now display with muted colors and reduced opacity for clearer distinction. ## Files Affected * nui/\* * fxmanifest.lua
Changelog - Version 2.6.1 ## Changes * Fixed context menus not being scrollable when they contained many options. * Preserved submenu callbacks so they are no longer lost when navigating back from a submenu. * Added fallback icons for context menu options — options without a specified icon now show a default icon. * Added hover callback support for context menu options, allowing custom actions when hovering over an option. * Added a smoking icon to the icon registry for use in context menus. * Improved item matching in `getItem` by trying multiple string formats to reduce lookup failures. * Ensured webhook configurations now properly sync with the current selection. ## Files Affected * nui/\* * docs/context\_menu.md * functions/getItem/shared.lua * interfaces/context/client.lua * webhooks/blacksmith.lua * fxmanifest.lua
Changelog - Version 2.6.0 ## Changes * Added per-button onSelect callbacks to forms, allowing buttons to trigger custom actions without closing the form. * Added hint text support for form fields to provide guidance. * Added support for paragraph text and button timeouts in forms. * Added the ability to clear an entire stash. * Improved stash compatibility and integration with various inventory systems. * Added getter and setter methods for item durability, enabling scripts to read and modify durability easily. * Added a new context menu system with scrollable quantity selection, dynamic label updates, and optional hint text for user guidance. * Added webhook notifications for the blacksmith crafting system. * Fixed item name trimming to correctly handle underscores during imports. * Ensured item imports continue fetching until successful, improving reliability when loading resources. ## Files Affected * nui/\* * README.md * functions/\* * imports.lua * interfaces/context/client.lua * interfaces/form/client.lua * webhooks/blacksmith.lua * fxmanifest.lua
Changelog - Version 2.5.4 ### Changes * Added support for multiple custom action buttons in forms, replacing the previous single submit button. * A new `buttons` array accepts objects with `text`, optional `icon`, `color`, and an `action` string. * The clicked button’s `action` is returned as `_action` in the result, allowing the caller to distinguish which button was pressed. * The old `submitText`, `submitIcon`, and `submitColor` options are deprecated but still functional. * Improved the player selection dropdown to handle missing or invalid player data gracefully, preventing errors. * Added detailed type annotations for form inputs, options, buttons, and results to aid developers. ### Files Affected * nui/\* * interfaces/form/client.lua * fxmanifest.lua
Changelog - Version 2.5.3 ### Changes * Fixed an error by swapping the invoked method for a context-agnostic native. * Added explicit support for `wasabi_ambulance_v2` as a death check system (set `death = "wasabi_ambulance_v2"` in dependency overrides to use it). * Added a warning when `canCarryItem` is called with an item that doesn't exist in your inventory system. ### Files Affected * dependency\_override.lua * functions/canCarryItem/server.lua * functions/isPlayerDead/client.lua * loader.lua * systems/death.lua * fxmanifest.lua
Changelog - Version 2.5.2 ### Changes * Started proper version tracking. * Added a `getGender` method that returns the player's gender, with framework-aware support for ESX and QB and a native fallback. * Fixed the textarea icon position to align to the top left instead of centering to the full height. * Added a missing icon to the textarea component. ### Files Affected * nui/\* * functions/getGender/client.lua * fxmanifest.lua
### Guides Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib/guides Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib/guides.md # Guides ## Dedicated Pages Take note that there are dedicated pages for longer guides, you can find them here: * [missing-gtx-label.md](/free-resources/zyke-lib/guides/missing-gtx-label "mention") * [interface-api.md](/free-resources/zyke-lib/guides/interface-api "mention") ### Missing GTX Label Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib/guides/missing-gtx-label Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib/guides/missing-gtx-label.md # Missing GTX Label ## Intro You **can** ignore these warnings. Our resources still work, we are just creating a warning that the labels may look botched in the menus because they are missing, and we are forced to use a fallback. ## Vehicle Labels Every vehicle has a **display name** (e.g. `SULTAN2`) and a **GXT label** (e.g. `Sultán RS`). We use the GXT label to show a clean, human-readable name throughout our resources. ### Why this warning appears ``` [WARNING] Invalid label for model 1234567890 using display name "MYADDON", using fallback "Myaddon" ``` Your addon vehicle has a display name in its `vehicles.meta`, but no GXT label has been registered for it. We fall back to title-casing the raw display name, which usually doesn't look great. ### How to fix it Register a GXT label using `AddTextEntry` in a client-side script in your addon vehicle resource. The first argument must match the `` from your `vehicles.meta`: ```lua AddTextEntry("MYADDON", "My Addon Car") ``` Once registered, the label will be picked up automatically and the warning will disappear. > [!SUCCESS] > If you install vehicles, check whether it ships with a `labels.lua` or `textentries.lua` file. Many well-made packs already include these GTX labels. ## Creating a label file If your addon vehicle doesn't already have labels set up, you can create one yourself. Here's a typical addon vehicle resource structure: ``` my_addon_car/ ├── fxmanifest.lua ├── data/ │ └── vehicles.meta ├── stream/ │ └── my_addon_car.yft └── labels.lua <-- Add this file ``` #### 1. Create `labels.lua` Create a new file called `labels.lua` in the root of your vehicle resource. Add an `AddTextEntry` call for each vehicle, where the first argument matches the `` in your `vehicles.meta`: ```lua -- labels.lua AddTextEntry("MYADDON", "My Addon Car") AddTextEntry("MYADDON2", "My Addon Car MK2") ``` #### 2. Register it in `fxmanifest.lua` Make sure the file is included as a client script: ```lua -- fxmanifest.lua fx_version 'cerulean' game 'gta5' client_script 'labels.lua' files { 'data/vehicles.meta', } data_file 'VEHICLE_METADATA_FILE' 'data/vehicles.meta' ``` #### 3. Find the display name If you're not sure what display name to use, check the `` field in your `vehicles.meta`: ```xml myaddon MYADDON ``` The `` value is what you pass as the first argument to `AddTextEntry`. ### Interface API Canonical URL: https://docs.zykeresources.com/free-resources/zyke-lib/guides/interface-api Markdown URL: https://docs.zykeresources.com/free-resources/zyke-lib/guides/interface-api.md # Interface API ## Forms The form system provides a way to open modal dialogs with dynamic input fields from Lua. Forms are blocking, the calling thread yields until the player submits or cancels. The return value is a table of input values keyed by name, or `nil` if cancelled. ### Usage ```lua local result = Z.openForm(title, inputs, options) ``` * `title` (string, required) -- text displayed in the modal header. * `inputs` (table\[], required) -- array of input definitions. * `options` (table, optional) -- modal-level configuration. Returns a `table` of values keyed by each input's `name`, or `nil` if cancelled. ### Helpers ```lua Z.isFormOpen() -- returns true if a form is currently open Z.getOpenFormId() -- returns the active form's ID, or nil Z.closeForm() -- close the active form (resolves as nil) Z.closeFormById(formId) -- close a specific form by ID (resolves as nil) ``` *** ### Options The third parameter controls the modal itself. All fields are optional. * `icon` (string) -- icon shown in the header next to the title. * `width` (string, default `"30rem"`) -- CSS width of the modal. * `showCancel` (boolean, default `true`) -- whether to show a cancel button. * `disableClickOutside` (boolean, default `false`) -- prevent closing by clicking the backdrop. * `buttons` (table\[]) -- array of submit buttons to render in the footer (see Buttons). Pressing Enter submits the form with the first button's action. Pressing Escape cancels it. *** #### Buttons The `buttons` array defines one or more submit buttons rendered in the form footer. Each entry is a table: * `text` (string, required) -- button label. * `icon` (string) -- icon rendered before the label. * `color` (string, default `"var(--blue1)"`) -- CSS color for the button. * `action` (string) -- identifier forwarded to the caller via `result._action`. When a button is clicked, the returned table will contain `_action` matching that button's `action` field. This lets you branch on which button the player chose: ```lua local result = Z.openForm("Import", inputs, { buttons = { { text = "Import", icon = "confirm", color = "var(--blue1)", action = "import" }, { text = "Generate Blank", icon = "copy", color = "var(--green1)", action = "blank" }, }, }) if (not result) then return end -- cancelled if (result._action == "import") then -- handle import elseif (result._action == "blank") then -- handle blank generation end ``` **Legacy submit fields** > **Deprecated** -- prefer `buttons[]` for new code. The following fields are kept for backward compatibility. If `buttons` is not provided, a single submit button is generated from these: * `submitText` (string, default `"Confirm"`) -- label on the submit button. * `submitIcon` (string) -- icon on the submit button. * `submitColor` (string, default `"var(--blue1)"`) -- CSS color for the submit button. These are ignored when `buttons` is present. *** ### Input Types Each entry in the `inputs` array is a table with a `type` field and additional properties depending on the type. #### Common Properties These apply to all input types. * `type` (string, required) -- one of: `text`, `number`, `select`, `select-player`, `checkbox`, `slider`, `textarea`. * `name` (string, required) -- key used in the returned values table. * `label` (string) -- label shown above the input. * `description` (string) -- secondary text below the label. * `icon` (string) -- icon displayed in the input (select and text types). * `disabled` (boolean) -- prevent interaction. * `defaultValue` (any) -- initial value. *** #### text Standard single-line text input. * `placeholder` (string) -- placeholder text when empty. ```lua { type = "text", name = "plate", label = "License Plate", placeholder = "ABC 123", icon = "label" } ``` Returns `string`. *** #### number Numeric input. * `placeholder` (string) -- placeholder text. * `min` (number) -- minimum allowed value. * `max` (number) -- maximum allowed value. ```lua { type = "number", name = "amount", label = "Amount", min = 1, max = 100, icon = "money" } ``` Returns `number`. *** #### select Dropdown selection with optional search filtering. * `content` (table\[]) -- array of `{ label = "...", value = "..." }` options. * `searchable` (boolean) -- enable search filtering. * `multiselect` (boolean) -- allow multiple selections. * `placeholder` (string) -- placeholder text. ```lua { type = "select", name = "garage", label = "Garage", icon = "garage", searchable = true, content = { { label = "Legion Square", value = "legion" }, { label = "Pillbox", value = "pillbox" }, }, defaultValue = "legion", } ``` Returns `string` (selected value) or `table` (array of values if multiselect). *** #### select-player A select dropdown automatically populated with all connected players. Each entry renders as `(id) Firstname Lastname` with the player's identifier as the value. Searchable by default. Defaults to the `person` icon if none is specified. All standard select properties (`searchable`, `multiselect`, `placeholder`, `defaultValue`) are supported. ```lua { type = "select-player", name = "target", label = "Target Player" } ``` Returns `string` (player identifier). *** #### checkbox Boolean toggle with a label. ```lua { type = "checkbox", name = "agree", label = "I agree to the terms" } ``` Returns `boolean`. *** #### slider Range slider with optional step marks. * `min` (number) -- minimum value. * `max` (number) -- maximum value. * `step` (number) -- step increment. * `marks` (table\[]) -- array of `{ value = n, label = "..." }` tick marks. ```lua { type = "slider", name = "rating", label = "Rating", min = 0, max = 10, step = 1 } ``` Returns `number`. *** #### textarea Multi-line text input with auto-resize. * `placeholder` (string) -- placeholder text. * `minRows` (number, default `3`) -- minimum visible rows. * `maxRows` (number, default `6`) -- maximum visible rows. * `maxLength` (number) -- character limit. ```lua { type = "textarea", name = "notes", label = "Notes", placeholder = "Write here...", maxLength = 500 } ``` Returns `string`. *** ### Icons Icons can be specified by name as a string on any `icon` field (inputs and options). Resolution works in two layers: 1. **Icon Registry** -- SVG icons from MUI and react-icons. These are the same icons used throughout zyke\_garages and render as crisp vector graphics. 2. **Material Icons** (fallback) -- if the name is not found in the registry, it is treated as a [Material Icons](https://fonts.google.com/icons) font name. #### Registry Icons
View all registry icons | Name | Source | Description | | -------------- | ----------- | -------------------------------------- | | `confirm` | react-icons | Standard confirm/submit icon (SiAuthy) | | `check` | MUI | Checkmark | | `save` | MUI | Floppy disk | | `edit` | MUI | Pencil | | `delete` | MUI | Trash can | | `add` | MUI | Plus sign | | `close` | MUI | X mark | | `refresh` | MUI | Circular arrows | | `restore` | MUI | Restore clock | | `copy` | MUI | Clipboard copy | | `search` | MUI | Magnifying glass | | `back` | MUI | Left arrow | | `person` | MUI | Person silhouette | | `accounts` | MUI | Person with gear | | `garage` | MUI | Garage door | | `warehouse` | MUI | Warehouse | | `car` | MUI | Car | | `car_alt` | react-icons | Car (alternate) | | `commute` | MUI | Two cars | | `engine` | react-icons | Engine block | | `fuel` | react-icons | Jerry can | | `gas` | react-icons | Gas pump | | `wheel` | react-icons | Car wheel | | `suspension` | react-icons | Spring coil | | `transmission` | react-icons | Manual gearbox | | `turbo` | react-icons | Lightning bolt | | `propane` | MUI | Propane tank | | `receipt` | MUI | Receipt document | | `label` | MUI | Tag label | | `info` | MUI | Info circle | | `info_alt` | react-icons | Info circle (alternate) | | `warning` | MUI | Warning triangle | | `error` | MUI | Error circle | | `help` | MUI | Question mark circle | | `gitbook` | react-icons | Gitbook logo | | `key` | MUI | Key | | `key_alt` | react-icons | Key (alternate) | | `lock` | MUI | Locked padlock | | `unlock` | MUI | Open padlock | | `settings` | MUI | Gear | | `build` | MUI | Wrench | | `construction` | MUI | Construction hat | | `wrench` | react-icons | Wrench (alternate) | | `work` | MUI | Briefcase | | `gavel` | MUI | Judge's gavel | | `keyboard` | MUI | Keyboard | | `location` | MUI | Map pin | | `time` | MUI | Clock | | `color` | MUI | Paint palette | | `money` | MUI | Dollar sign | | `cart` | MUI | Shopping cart |
#### Material Icons Fallback Any string not found in the registry is treated as a Material Icons font name. Browse the available icons at [fonts.google.com/icons](https://fonts.google.com/icons). ```lua icon = "directions_boat" -- not in registry, renders via Material Icons font ``` *** ### Full Example ```lua local result = Z.openForm("Report Player", { { type = "select-player", name = "target", label = "Player", }, { type = "select", name = "reason", label = "Reason", icon = "warning", searchable = true, content = { { label = "Cheating", value = "cheating" }, { label = "Harassment", value = "harassment" }, { label = "Bug Abuse", value = "bug_abuse" }, }, }, { type = "textarea", name = "details", label = "Details", placeholder = "Describe what happened...", maxLength = 500, }, }, { icon = "info", buttons = { { text = "Submit Report", icon = "confirm", action = "submit" }, { text = "Save as Draft", icon = "save", color = "var(--green1)", action = "draft" }, }, }) if (not result) then return end if (result._action == "submit") then print("Submitted:", result.target, result.reason, result.details) elseif (result._action == "draft") then print("Saved as draft:", result.target, result.reason, result.details) end ```
### Status Canonical URL: https://docs.zykeresources.com/free-resources/status Markdown URL: https://docs.zykeresources.com/free-resources/status.md # Status ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/status/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/status/resource-description.md # Resource Description ## Links * [Download](https://github.com/ZykeWasTaken/zyke_status) ## Information To briefly describe this resource, it is a backwards compatible status system for ESX, QBCore & Qbox. It offers the exact same events, data structures and other operations executed. This allows for an easy drag-and-drop solution with just a basic and univeral SQL needing to be ran, and it will seamlessly work with your old systems. However, that is not all this resource offers. In addition to the basic statuses, our resource can also support custom statuses easily, along with a subset of statuses to your primary. For example, we can manage multiple different highs, such as THC, coke, meth etc, all individually, with different values and effects. We boast an easy-to-use system where you can dynamically create and use sub-statuses without additional setup. Simply run an export and we will use the default parameters. We also offer a wide range of customizable settings, even allowing you to completely override and create custom effects for those that are slightly more advanced. ### Exports & Events Canonical URL: https://docs.zykeresources.com/free-resources/status/exports-and-events Markdown URL: https://docs.zykeresources.com/free-resources/status/exports-and-events.md # Exports & Events > [!INFO] > ### Types & Classes > > All types & classes can be found in types.lua. > [!INFO] > ### Suggestions? > > If you wish to have any exports and or events added, please head over to our [Discord](https://discord.zykeresources.com/) and create a suggestion post. We are happy to allow for easier integration within other resources. > [!WARNING] > ## Status Names > > When refering to a primary status name, it is the base name of the status.\ > \ > For multi statuses like being high on thc, the primary is "high" and the secondary is "thc".\ > \ > For non-multi statuses like "hunger", both the primary & secondary is "hunger". This is why a secondary name is not always required as input. ## Client Sided Exports ### Get All Statuses > If you want to grab all initialized & cached statuses straight from our cache, you can use this export.\ > \ > **Example:** > > ```lua > ---@return table | nil @nil when unloaded > local statuses = exports["zyke_status"]:GetAllRawStatuses() > ``` ### Shorthands (Hunger, thirst, stress & drunk) > We have created a set of shorthands for common statuses. These are very basic to implement and always returns a number value, 0.0 if not initialized to avoid errors.\ > \ > **Example:** > > ```lua > local hunger = exports["zyke_status"]:GetHunger() > local thirst = exports["zyke_status"]:GetThirst() > local stress = exports["zyke_status"]:GetStress() > local drunk = exports["zyke_status"]:GetDrunk() > ``` ### Get Raw Status > This export allows you to grab any status, even non-initialized ones in a error-handled environment. It always return a table with a value, 0.0 if not initialized. The second return value indicates if the status you grabbed was initialized or not.\ > \ > **Example:** > > ```lua > ---@return {value: number} | PlayerStatus | AddictionStatus, boolean > local status = exports["zyke_status"]:GetRawStatus() > ``` ## Server Sided Exports ### Get All Statuses > If you want to grab all initialized & cached statuses for a player, you can use this export.\ > \ > **Example:** > > ```lua > ---@param plyId integer > ---@return table > local statuses = exports["zyke_status"]:GetAllRawStatuses(plyId) > ``` ### Shorthands (Hunger, thirst, stress & drunk) > We have created a set of shorthands for common statuses. These are very basic to implement and always returns a number value, 0.0 if not initialized to avoid errors.\ > \ > **Example:** > > ```lua > local hunger = exports["zyke_status"]:GetHunger(plyId) > local thirst = exports["zyke_status"]:GetThirst(plyId) > local stress = exports["zyke_status"]:GetStress(plyId) > local drunk = exports["zyke_status"]:GetDrunk(plyId) > ``` ### Get Raw Status > This export allows you to grab any status for a player, even non-initialized ones in a error-handled environment. It always return a table with a value, 0.0 if not initialized. The second return value indicates if the status you grabbed was initialized or not.\ > \ > **Example:** > > ```lua > ---@param plyId integer > ---@param statusNames {[1]: PrimaryName, [2]?: SecondaryName} > ---@return {value: number} | PlayerStatus | AddictionStatus, boolean > local status, isInitialized = exports["zyke_status"]:GetRawStatus(plyId, {"stress", "stress"}) > ``` ### Get Status > Returns just the number value of a status for a player. Returns 0.0 if not initialized.\ > \ > **Example:** > > ```lua > ---@param plyId integer > ---@param statusNames {[1]: PrimaryName, [2]?: SecondaryName} > ---@return number > local value = exports["zyke_status"]:GetStatus(plyId, {"hunger", "hunger"}) > ``` ### Add To Status > Adds an amount to a status.\ > \ > **Example:** > > ```lua > ---@param plyId integer > ---@param statusNames {[1]: PrimaryName, [2]?: SecondaryName} > ---@param amount number > ---@param skipEnsuring? boolean @Only skip if you have a pool with ensured players > exports["zyke_status"]:AddToStatus(plyId, statusNames, amount, skipEnsuring) > ``` ### Remove From Status > Removes an amount from a status.\ > \ > **Example:** > > ```lua > ---@param plyId integer > ---@param statusNames {[1]: PrimaryName, [2]?: SecondaryName} > ---@param amount number > ---@param skipEnsuring? boolean @Only skip if you have a pool with ensured players > exports["zyke_status"]:RemoveFromStatus(plyId, statusNames, amount, skipEnsuring) > ``` ### Auto To Status > Automatically choose add/remove based on amount\ > \ > **Example:** > > ```lua > ---@param plyId integer > ---@param statusNames {[1]: PrimaryName, [2]?: SecondaryName} > ---@param amount number > ---@param skipEnsuring? boolean @Only skip if you have a pool with ensured players > exports["zyke_status"]:AutoToStatus(plyId, statusNames, amount, skipEnsuring) > ``` ### Freeze Status For Player > Freezes the status for a player to avoid drain and effects.\ > \ > **Example:** > > ```lua > ---@param plyId PlayerId @ (integer) > exports["zyke_status"]:FreezeStatus(plyId) > ``` ### Unfreeze Status For Player > Unfreezes the status for a player to avoid drain and effects. Reset for [#freeze-status-for-player](/free-resources/status/exports-and-events#freeze-status-for-player "mention").\ > \ > **Example:** > > ```lua > ---@param plyId PlayerId @ (integer) > exports["zyke_status"]:UnfreezeStatus(plyId) > ``` ### Get Frozen Players > If you want a list of all frozen players, this export will do just that.\ > \ > **Example:** > > ```lua > ---@class FrozenPlayer > ---@field plyId PlayerId @ (integer) > ---@field frozenAt OsTime @ (integer) > > ---@return table @ (integer) > exports["zyke_status"]:GetFrozenPlayers() > ``` ### Is Player Statuses Frozen > Return if a player has their statuses frozen or not.\ > \ > **Example:** > > ```lua > ---@param plyId PlayerId @ (integer) > ---@return boolean > exports["zyke_status"]:IsPlayerFrozen(plyId) > ``` ### Dependencies Canonical URL: https://docs.zykeresources.com/free-resources/status/dependencies Markdown URL: https://docs.zykeresources.com/free-resources/status/dependencies.md # Dependencies ### Click the names to be redirected * [zyke\_lib](https://github.com/ZykeWasTaken/zyke_lib) ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/status/changelog Markdown URL: https://docs.zykeresources.com/free-resources/status/changelog.md # Changelog
Changelog - Version 0.4.4 ## Changes * Added a basic starter list for high effects with pre-configured presets for easier setup. * Added global effect toggles in the config to enable or disable all effects. * Added a small delay before initializing the status system to prevent timing issues with other resources on startup. * Fixed the `/status_clear` command to support targeting other players by ID or using `me`/`self`; also shows a success notification. * Improved handling of server-console commands: they now print status messages instead of failing with player notifications, and admins with permission can execute them directly from console. ## Files Affected * server/direct\_effects/functions.lua * server/initialize.lua * shared/config.lua * shared/functions.lua * README.md * dev/server/main.lua * effect\_manager/main.lua * effect\_manager/queue.lua * locales/\* * statuses/high/config.lua * fxmanifest.lua

2026-05-20 22:09 CET

Changelog - Version 0.4.3 ### Changes * Added compatibility support for wasabi\_ambulance\_v2, so players are properly healed on revive. * Fixed walking style reset using an incorrect gender check, which could cause the wrong default walk style to be applied. * Fixed the stumble effect not accepting boolean values when triggering it. * Fixed an issue in the effect queue where threshold indexes weren't resolved correctly, which could cause errors or failed effect applications. ### Files Affected * server/events.lua * shared/functions.lua * effect\_manager/effects/stumble.lua * effect\_manager/effects/walkingStyle.lua * effect\_manager/queue.lua * fxmanifest.lua
Changelog - Version 0.4.2 ### Changes * Updated the camera shaking effect to support boolean values. * Setting camera shaking to true will now automatically apply the default shake type and intensity. ### Files Affected * effect\_manager/effects/cameraShaking.lua * fxmanifest.lua
Changelog - Version 0.4.1 ### Changes * Added Lithuanian localization support for all notifications and status messages. * Added new server-side functionality for other scripts to retrieve player status information. * Allows other resources to check a player's specific levels for stress, hunger, thirst, and drunkness. * Provides access to all raw status data for a player. ### Files Affected * server/functions.lua * locales/lt.lua * shortcuts/server.lua * fxmanifest.lua
Changelog - Version 0.4.0 ### Changes * Migrated to a new "rich effects" system for more immersive status feedback. * Added threshold-based reactions that trigger specific behaviors when a status reaches a certain level. * Added custom animations and sounds that play upon hitting thresholds. * Added the ability to trigger screen effects, blurry vision, and camera shaking. * Added movement-based effects including speed modifiers, walking style changes, and stumbling. * Added physical limitations such as blocking the ability to jump or sprint based on status. * Added strength modifiers that can be tied to player status. * Added support for notifications to appear when a status threshold is reached. * Status updates now apply to the player instantly rather than waiting for the next sync cycle. * Added comprehensive translation support for over 15 languages, including Arabic, German, Spanish, French, Japanese, and more. * Added new functionality to perform a "Soft Reset" or a full "Reset" on player statuses. * Added a developer command to manually trigger a status save. * Adjusted the default stress effects and multipliers for better gameplay balance. * Fixed an issue where screen effects would not properly clear if the resource was stopped. * Fixed the debug mode being enabled by default in the configuration. * Improved error handling to prevent issues when duplicate status IDs are detected. ### Files Affected * client/events.lua * server/direct\_effects/functions.lua * server/freeze\_status.lua * server/functions.lua * server/reaction\_sounds.lua * shared/config.lua * shared/functions.lua * .vscode/settings.json * compatibility/client.lua * compatibility/server.lua * dev/server/main.lua * effect\_manager/\* * locales/\* * statuses/hunger/config.lua * statuses/stress/config.lua * statuses/thirst/config.lua * types.lua * fxmanifest.lua
Changelog - Version 0.3.17 ## Changes * Instantly syncing your stats to the client after being reset, i.e remove effects right after being revived. * Added various debug logs throughout the resource. ## Files Affected * Replace all.
Changelog - Version 0.3.16 ## Changes * Fixed a faulty check when getting a sub-status using `GetStatus`. ## Files Affected * server/functions.lua * fxmanifest.lua
Changelog - Version 0.3.15 ## Changes * Ignore catching txadmin events if you have wasabi\_ambulance on your server, as that script already handles it. We just catch whatever wasabi dispatches. ## Files Affected * server/events.lua * shared/functions.lua * fxmanifest.lua
Changelog - Version 0.3.14 ## Changes * Fixed incorrect logic that would block the shooting stress inducer. * Added in various events for better wasabi\_ambulance healing support. ## Files Affected * compatibility/client.lua * client/small\_resources/shooting.lua * fxmanifest.lua
Changelog - Version 0.3.13 ## Changes * Fixed an accidental double-registering of the tx healing event. ## Files Affected * compatibility/server.lua * fxmanifest.lua
Changelog - Version 0.3.12 ## Changes * Added version checker. * Adjusted the logic for the ESX compatibility to better mirror their process. * Corrected the value for non-reversed items for dummyReturn, ex. food at 100%, drunk at 0% and so on. * Freezing statuses * Freezes the "onTick" that is ran. * Freezes all effects on the client. * Available via command. * See your config for available commands. * Available via exports. * [Freeze Status For Player](/free-resources/status/exports-and-events#freeze-status-for-player) * [Unfreeze Status For Player](/free-resources/status/exports-and-events#unfreeze-status-for-player) * [Get Frozen Players](/free-resources/status/exports-and-events#get-frozen-players) * [Is Player Statuses Frozen](/free-resources/status/exports-and-events#is-player-statuses-frozen) * Check command length to register singular heal command correctly. * Target id parser for commands, refactored the heal command to use this system. ## Files Affected * server/commands/freeze\_status.lua * server/freeze\_status.lua * server/utils/command\_utils.lua * client/events.lua * client/main.lua * compatibility/client.lua * compatibility/server.lua * dev/client/hud.lua * effect\_manager/main.lua * server/commands/heal.lua * server/main.lua * shared/config.lua * locales/en.lua * fxmanifest.lua
Changelog - Version 0.3.11 ## Changes * Fixed incorrect target when using the healing command. * Simplified the dev hud drawing for new elements. * Forcefully floor the max amount passed into the stat decimal manager. * Added better ESX compatibility for grabbing a status via the standard event. ## Files Affected * client/small\_resources/stat\_decimals.lua * compatibility/client.lua * dev/client/hud.lua * server/commands/heal.lua * locales/en.lua * fxmanifest.lua
Changelog - Version 0.3.10 ## Changes * Added a missing check to avoid always ensuring the base value. ## Files Affected * server/initialize.lua * fxmanifest.lua
Changelog - Version 0.3.9 ## Changes * Fallback value to ensure one is always sent for QB events. ## Files Affected * server/functions.lua * fxmanifest.lua
Changelog - Version 0.3.8 ## Changes * Fixed an accidental table reference that would share status data, it is now copying content instead. ## Files Affected * server/initialize.lua * fxmanifest.lua
Changelog - Version 0.3.7 ## Changes * Generating & setting base values for new characters. * Added `envi-hud` to the hudOverriding list. ## Files Affected * server/functions.lua * server/initialize.lua * shared/functions.lua * shared/config.lua * fxmanifest.lua
Changelog - Version 0.3.6 ## Changes * Nullish check during compatibility translation. ## Files Affected * compatibility/client.lua * compatibility/server.lua * fxmanifest.lua
Changelog - Version 0.3.5 ## Changes * Properly checking if value is missing. ## Files Affected * client/functions.lua * fxmanifest.lua
Changelog - Version 0.3.4 * Pre-define value to avoid weird nullish chaining error. ## Files Affected * server/main.lua * fxmanifest.lua
Changelog - Version 0.3.3 * Ensure pathing exists before setting values ## Files Affected * server/initialize.lua * fxmanifest.lua
Changelog - Version 0.3.2 ## Changes * Added fallback value for Qbox/QBCore. * Added fentanyl high effects. ## Files Affected * server/functions.lua * statuses/high/config.lua * Config.Statuses.high\["fentanyl"] * fxmanifest.lua
Changelog - Version 0.3.1 ## Changes * Avoid error when healing after de-registering. * Run onStart for queued effects that are not being ran, and no longer when just the value changes. * Stumble effect, random change to fall. * Diffearent multipliers for your high, and if you're standing/walking/running. * n2o/whippet high. * Overhauled server-sided thread interval to handle priority players, to allow quicker intervals when needed. * GetStatusSettings now relies on primitive types for input. * Properly reset values, instead of setting to 0.0, avoids excess looping. ## Files Affected * Replace all files.
Changelog - Version 0.3.0 ## Changes * Fixed reversed statuses, like hunger, executing incorrect threshold indexes for effects. * Inserting key correctly to allow batch calls to client sync. * Instantly sync status to client on heal. * Instantly sync status to client on player status initialization, which is usually just character selection. * Using stat decimal helper for damage effects for statuses, you can now use decimals to specify the damage a player should receive. * Adjusted the default configs for hunger & thirst. * Finalized direct effects, you can now trigger effects without tying them to a status effect. ## Files Affected * client/events.lua * effect\_manager/main.lua * effect\_manager/queue.lua * server/functions.lua * server/direct\_effects/functions.lua * shared/functions.lua * shared/initialize.lua * statuses/hunger/config.lua * statuses/thirst/config.lua * types.lua * fxmanifest.lua
Changelog - Version 0.2.6 ## Changes * Moved to the new zyke\_lib loader. * Gain stress when shooting. * Verify a "max" value exists when using the "stat decimal" feature. * Added `mHud` to list of huds overriding player instance update interval. * Defined T as global. * Make sure value exists when grabbing from a player's direct effects. ## Files Affected * .vscode/settings.json * client/main.lua * client/small\_resources/shooting.lua * client/small\_resources/stat\_decimals.lua * dev/hud.lua * dev/client/hud.lua * dev/server/main.lua * server/direct\_effects/functions.lua * shared/config.lua * Config.Settings.smallResources.shooting * Config.Settings.playerInstanceUpdate.hudOverriding * fxmanifest.lua
Changelog - Version 0.2.5 ## Changes * Handle a `max` parameter for the stat manager, to set a "cap" of what you can add to a stat. For example, smoking x will only allow you to get 20 armor at most, any addition past it is rejected. * Fixed some mismatched names when checking "if" statements & registering events. * Added `vms_hud` to list of huds overriding player instance update interval. * Catching & handling txAdmin heal event. * Creates sub-files for each command. * Registering healing function, not overwriting by default. Files Affected * server/commands.lua * server/commands/heal.lua * server/events.lua * shared/config.lua * Config.Settings.commands * fxmanifest.lua
Changelog - Version 0.2.4 ## Changes * Added more client exports to integrate our script easier. * [Get All Statuses](/free-resources/status/exports-and-events#get-all-statuses) * [Shorthands (Hunger, thirst, stress & drunk)](/free-resources/status/exports-and-events#shorthands-hunger-thirst-stress-and-drunk) * [Get Raw Status](/free-resources/status/exports-and-events#get-raw-status) ## Files Affected * client/functions.lua * shortcuts/client.lua * fxmanifest.lua
Changelog - Version 0.2.3 ## Changes * Added `izzy-hudv6`, `17mov_hud` & `ts_hud` to list of huds overriding player instance update interval. * Changed the warning for grabbing uninitialized values from error to debug. * Exported `AddDirectEffect`. * Added direct effect calls for string effect values. * Stat decimal manager - basically a primitive manager simplifying the process of adding small values in many iterations, like health & armor that doesn't support decimals. * Added `AutoToStatus` which automatically triggers `AddToStatus` or `RemoveFromStatus` depending on the value being positive or negative. * Simplified add/remove status command by also allowing +/- symbol. [@iSentrie](https://github.com/iSentrie) ## Files Affected * client/small\_resources/stat\_decimals.lua * compatibility/client.lua * server/direct\_effects/functions.lua * server/functions.lua * shared/config.lua * fxmanifest.lua
Changelog - Version 0.2.2 ## Changes * Basics for direct effect calls. This allows you to run our effects directly instead of relying on a status to trigger the effect. * Better thread lifetime management for client idle performance. * Configurable player instance updating intervals, to support certain huds not relying on events for information update. * Modified some default values. * Fixed incorrect links. * Removed unused files. ## Files Affected * client/events.lua * client/main.lua * dev/client.lua * effect\_manager/queue.lua * server/database.lua * server/direct\_effects/README.md * server/direct\_effects/events.lua * server/direct\_effects/functions.lua * server/functions.lua * server/initialize.lua * server/main.lua * shared/config.lua * statuses/caffeine/config.lua * statuses/hunger/config.lua * statuses/thirst/config.lua * types.lua * fxmanifest.lua ## SQL Modifications ```sql ALTER TABLE `zyke_status` ADD COLUMN `direct_effects` MEDIUMTEXT NOT NULL DEFAULT "{}"; ```
Changelog - Version 0.2.1 ## Changes * Massively simplified the setup process. * Only tracking active effects to have less load on your client when idling. * Changed some default values for gaining & relieving stress. * Updated some docstrings. ## Files Affected * effect\_manger/queue.lua * compatibility/server.lua * shared/config.lua * fxmanifest.lua
Changelog- Version 0.2.0 ## Changes * Moved from "pre-release" to official release as the resource has been tested without issues for a while. * The database now runs automatically. * Some internal re-structuring. * Added `blockJumping` effect. * Added `blockSprinting` effect. ## Files Affected * client/main.lua * effect\_manager/effects/blockJumping.lua * effect\_manager/effects/blockSprinting.lua * effect\_manager/effects/blurryVision.lua * effect\_manager/effects/cameraShaking.lua * effect\_manager/effects/movementSpeed.lua * effect\_manager/effects/screenEffect.lua * effect\_manager/effects/strength.lua * effect\_manager/effects/walkingStyle.lua * effect\_manager/main.lua * effect\_manager/queue.lua * server/database.lua * server/initialize.lua * fxmanifest.lua * extras/zyke\_status.sql
Changelog - Version 0.1.5 ## Changes * Qbox compatibility. * Changed default decimal accuracy from 3 to 6. * Removed unused `ClearEffectQueueKey` client export. * Added `RemoveFromQueue` & `RemoveFromQueueBulk` client exports. ## Files Affected * effects/queue.lua * server/functions.lua * server/main.lua * shared/config.lua * README.md * fxmanifest.lua
Changelog - Version 0.1.4 ## Changes * More versatile ESX compatibility. * Ensuring walking style and avoid overriding crouching. * Refactored a confusing debug message. * Configurable stress gain when driving fast. * Base for caffeine status. ## Files Affected * client/small\_resources/driving.lua * compatibility/client.lua * compatibility/server.lua * effects/queue.lua * effects/walkingStyle.lua * server/register\_statuses.lua * shared/config.lua * statuses/caffeine/config.lua * statuses/caffeine/server.lua * fxmanifest.lua
Changelog - Version 0.1.3 ## Changes * Smarter timeouts for syncing server to client. Bundles & processes first request instantly, but delays sequential requests to avoid overload. * Better threshold management to space update intervals from drain. * Properly ordering the tresholds for effects so the correct index is grabbed. * Listed zyke\_lib as dependency. * Ensure status is valid to add/remove/set. * Reset status command for admins. * New structure for passing primary and secondary status names. * Some misc changes. ## Files Affected * compatibility/server.lua * dev/server.lua * effects/main.lua * effects/queue.lua * server/events.lua * server/functions.lua * server/initialize.lua * server/main.lua * shared/config.lua * shared/functions.lua * statuses/addiction/config.lua * statuses/addiction/server.lua * statuses/drunk/server.lua * statuses/high/config.lua * statuses/high/server.lua * statuses/hunger/server.lua * statuses/stress/server.lua * statuses/thirst/server.lua * types.lua * fxmanifest.lua
Changelog -. Version 0.1.2 ## Changes * Spacing the main thread interval for passive drain to preserve performance. * Limit the value to ceiling when using the setter function. * Executing qb actions instantly (not just stress) to keep the QB player object up to date. * Smarter client syncing queue, now executing instantly and limiting consecutive requests, and bundling those updates to execute after a set threshold. Ensures up-to-date data whilst preserving performance if needed. * Catching QB events `consumables:server:addThirst` & `consumables:server:addHunger`. * Updated setup to remove `consumables:server:addThirst` & `consumables:server:addHunger` for QB in qb-smallresources. ## Files Affected * compatibility/server.lua * server/functions.lua * server/main.lua * statuses/addiction/server.lua * statuses/drunk/server.lua * statuses/high/server.lua * statuses/hunger/server.lua * statuses/stress/server.lua * statuses/thirst/server.lua * fxmanifest.lua
Changelog - Version 0.1.1 ## Changes * More universal SQL query. * Miscellaneous cleanup. * Ignore invalid events. * Return the new status value after onSet. * Set metadata instantly on stress update for QBCore. * Provide primary & secondary when using `GetStatus` to avoid separating it. * Catch common stress addition & removal events. * Fixed ceiling typo for stress when setting. ## Files Affected * client/events.lua * extras/zyke\_status.sql * notes.md * server/events.lua * server/functions.lua * shared/config.lua * shared/functions.lua * statuses/hunger/server.lua * statuses/stress/server.lua * fxmanifest.lua
Changelog - Version 0.1.0 Pre-release for ESX & QBCore.
### Guides Canonical URL: https://docs.zykeresources.com/free-resources/status/guides Markdown URL: https://docs.zykeresources.com/free-resources/status/guides.md # Guides ## Dedicated Pages Take note that there are dedicated pages for longer guides, you can find them here: * [editing-statuses.md](/free-resources/status/guides/editing-statuses "mention") ## Passive Drain This is a guide for changing the passive drain, or "amount lowered over time". 1. Navigate into the status you want to change, ex. `zyke_status/statuses/drunk/config.lua`. 2. In here you will find the `drain` setting. For the normal statuses, all you have to do is change the `drain` value in the `base` configuration. 1. The value you put in here will be removed every second. Example: if we set it to 0.005 , it takes 200 seconds to drain 1%, which is \~320 minutes/\~5h for 100%. If you set it to 1.0, it will take 100 seconds to drain 100%. 2. **TECHNICAL:** If your drain value is set to more than 0.1, it will count as "high priority" & update more frequently, this allows us both slow and rapid drains without performance implications or a sluggish experience. **If you are adjusting a status with multiple dynamic statuses**, like our "high" status, you can tweak each status independently. The `base` configuration will cover all sub-statuses that don't have explicit configurations made. If you do define a sub-status, the drain value within it will be prioritized. If you are confused about sub-statuses, you can see an example in the default high config. ## Editing Effects (Thresholds) All of our effects within zyke\_status are based on thresholds. When a status is modified, we dispatch a check to see if we should run a loop to keep managing an effect based on your status levels. These thresholds declaring if an effect should be ran are very simple to modify. 1. Navigate into the status you want to change, ex. `zyke_status/statuses/drunk/config.lua`. 2. In here you will find the `effect` attribute. * If you quickly want to remove all of it, simply set `effect = {}`. * You can add/remove/edit these thresholds as you wish, as long as you are using respected values. * _We automatically re-order the thresholds during runtime in case of any misalignments._ * You can find respected values in `zyke_status/effect_manager/effects`. As I am writing this, we are currently in the middle of a re-write of the script, so specifics will come later. Values are easy to figure out if you know what you are doing. ### Editing Statuses Canonical URL: https://docs.zykeresources.com/free-resources/status/guides/editing-statuses Markdown URL: https://docs.zykeresources.com/free-resources/status/guides/editing-statuses.md # Editing Statuses ### Effect Manager The effect manager controls what happens to a player on the **client side** when a status crosses a threshold. Blurry vision, camera shaking, walking styles, screen overlays, stumbling, reactions - all of these are configured through the effect system. Effects are driven by your **status configs**. You define thresholds, attach effect keys with values, and the system takes care of the rest. When multiple effects compete (e.g. two different walking styles from stress and alcohol), the system automatically resolves which one wins. *** #### Table of Contents * [How It Works](/free-resources/status/guides/editing-statuses#how-it-works) * [Configuring Effects](/free-resources/status/guides/editing-statuses#configuring-effects) * [Effect Keys](/free-resources/status/guides/editing-statuses#effect-keys) * [Notifications](/free-resources/status/guides/editing-statuses#notifications) * [Reactions (Animations & Sounds)](/free-resources/status/guides/editing-statuses#reactions-animations-and-sounds) * [Damage](/free-resources/status/guides/editing-statuses#damage) * [FAQ](/free-resources/status/guides/editing-statuses#faq) *** #### How It Works 1. **Each status** has an `effect` array in its config file (`statuses//config.lua`). 2. **Each entry** in that array has a `threshold` and one or more effect keys. 3. **Every second**, the system checks each status value against its thresholds. When a threshold is crossed, the effects attached to it activate. When the value drops back below, they deactivate. 4. **If multiple statuses** try to control the same effect key (e.g. two different `walkingStyle` values), the system picks the most severe one automatically. You configure everything in the status config. No code changes are needed. *** #### Configuring Effects Effects live inside the `effect` table of a status config. Each entry is a threshold with one or more effect keys attached to it. **Basic Example (Drunk)** ```lua Config.Status.drunk = { ["base"] = { value = { drain = 0.1 }, effect = { {threshold = 10.0, walkingStyle = "move_m@buzzed"}, {threshold = 20.0, screenEffect = "BeastLaunch02", walkingStyle = "move_m@drunk@slightlydrunk"}, {threshold = 30.0, screenEffect = "BikerFilter", walkingStyle = "move_m@drunk@a", blurryVision = true}, {threshold = 50.0, screenEffect = "DaxTrip03", walkingStyle = "move_m@drunk@verydrunk"}, }, } } ``` * At `10.0`, the player starts walking wobbly. * At `20.0`, a screen effect kicks in and the walk gets worse. * At `30.0`, blur effects start on top. * At `50.0`, the screen effect gets more intense and the walking style is heavily impaired. When the value drops below a threshold, its effects are automatically cleaned up. **Threshold Stacking** Thresholds are cumulative. When a player is at value `35.0` with the config above, thresholds at `10`, `20`, and `30` are **all** active simultaneously. The system picks the dominant value per effect key, so only one `walkingStyle` plays at a time (the highest threshold wins). **Combining Multiple Effects** You can attach as many effect keys as you want to a single threshold: ```lua {threshold = 30.0, screenEffect = "BikerFilter", walkingStyle = "move_m@drunk@a", blurryVision = true, cameraShaking = "DRUNK_SHAKE"} ``` **Simple vs Rich Values** Some effect keys accept either a simple value or a table with extra options: ```lua -- Simple: just the name, uses default settings screenEffect = "BarryFadeOut" -- Rich: name with an intensity value screenEffect = {value = "BarryFadeOut", intensity = 0.3} ``` ```lua -- Simple cameraShaking = "DRUNK_SHAKE" -- Rich cameraShaking = {value = "DRUNK_SHAKE", intensity = 0.05} ``` Both forms work. The simple form just uses a default intensity of `1.0`. *** #### Effect Keys Here are all the available effect keys you can use in your threshold configs: | Key | Value Type | Description | | ---------------- | -------------------------------- | -------------------------------------------------------- | | `screenEffect` | `string` or `{value, intensity}` | Applies a timecycle modifier as a screen overlay | | `cameraShaking` | `string` or `{value, intensity}` | Shakes the gameplay camera | | `walkingStyle` | `string` | Changes the player's movement clipset (walk animation) | | `blurryVision` | `boolean` | Periodically fades a blur overlay in and out | | `blockJumping` | `boolean` | Prevents the player from jumping | | `blockSprinting` | `boolean` | Prevents the player from sprinting | | `movementSpeed` | `number` | Scales run/sprint speed (`1.0` = normal, lower = slower) | | `strength` | `number` | Scales unarmed melee damage (`1.0` = normal) | | `stumble` | `number` | Chance-based stumbling/ragdoll (higher = more frequent) | | `reaction` | `table` | Synchronized animation + sound (see below) | | `damage` | `number` | Deals damage per tick (see below) | | `notification` | `table` | Shows a notification once (see below) | **Notes** * **`movementSpeed`**: We recommend not going below `0.8` as it starts to look weird. * **`stumble`**: The value is a multiplier on the base chance. Running and sprinting significantly increase the stumble chance. * **`walkingStyle`**: Won't override crouching. *** #### Notifications Notifications fire **once** when a threshold is first crossed. They are not queued effects, so they don't compete for dominance. ```lua { threshold = 10.0, notification = {value = "stress1", play = "start"}, } ``` | Field | Type | Description | | ------- | ---------- | ------------------------------------------------------------------------ | | `value` | `string` | Translation key (from `locales/`) or a raw message string | | `play` | `string` | When to show it. Use `"start"` (when the threshold is hit) | | `type` | `string?` | Optional notification type (e.g. `"warning"`) | | `force` | `boolean?` | If `true`, always shows even when surpassing multiple thresholds at once | **Anti-Spam** When a player jumps past multiple thresholds at once (e.g. from 0 to 60), only the **highest** threshold's notification plays. Use `force = true` on a specific notification if it should always play regardless: ```lua notification = {value = "stress1", play = "start", force = true} ``` **Translation Keys vs Direct Messages** If the `value` matches a key in your locale files, the translation is used. Otherwise the string is shown directly: ```lua -- Uses the "stress1" translation notification = {value = "stress1", play = "start"} -- Shows this exact text notification = {value = "You are feeling critically stressed.", type = "warning", play = "start"} ``` *** #### Reactions (Animations & Sounds) Reactions combine animations and/or sounds into one synchronized effect. They can play once or loop continuously. **Full Example (Stress Coughing)** ```lua { threshold = 10.0, reaction = { animation = { dict = "timetable@gardener@smoking_joint", clip = "idle_cough", flag = 49, start = 800, stop = 2000, blendInSpeed = 4.0, blendOutSpeed = 1.0, }, sound = { name = { male = {"cough_m1.wav", "cough_m2.ogg", "cough_m3.ogg"}, female = {"cough_f1.wav", "cough_f2.wav", "cough_f3.wav"}, }, volume = 0.2, distance = 2.0, }, loop = { delay = 13500, } } } ``` You don't need both `animation` and `sound`, either one on its own works fine. **Animation Fields** | Field | Type | Default | Description | | --------------- | --------- | ------- | ------------------------------------------------ | | `dict` | `string` | | Animation dictionary | | `clip` | `string` | | Animation clip name | | `flag` | `integer` | `49` | Animation flag (49 = upper body, doesn't freeze) | | `start` | `integer` | `nil` | Start time in ms (skip the beginning) | | `stop` | `integer` | `nil` | Stop time in ms (cut the animation short) | | `blendInSpeed` | `number` | `1.0` | How fast the animation blends in | | `blendOutSpeed` | `number` | `1.0` | How fast the animation blends out | | `forceAnim` | `boolean` | `false` | Force replay even if already playing | | `speed` | `number` | `1.0` | Playback speed | **Sound Fields** | Field | Type | Default | Description | | ---------- | -------------------------------- | ------- | ----------------------------------------------------------------------- | | `name` | `string`, `string[]`, or `table` | | Sound file(s). Supports `{male = ..., female = ...}` for gendered audio | | `volume` | `number` | `0.3` | Playback volume | | `distance` | `number` | `10.0` | How far other players can hear it | > Sounds require `zyke_sounds` to be running. If it's not available, the sound part is silently skipped. **Loop Settings** | Field | Type | Description | | ------- | ------------------------- | ------------------------------------------------------------ | | `delay` | `integer` or `{min, max}` | Delay in ms before repeating. Use a table for a random range | ```lua loop = {delay = 5000} -- Fixed 5 second delay loop = {delay = {3000, 7000}} -- Random between 3 and 7 seconds ``` If `loop` is not defined, the reaction plays once and does not repeat. **Anti-Spam** Same as notifications. When surpassing multiple thresholds at once, only the highest threshold's reaction plays. You can override this on the threshold entry with `force = true`. *** #### Damage Damage is not queued and **does** stack. If two statuses both deal damage, the player takes both. ```lua effect = { {threshold = 50.0, damage = 0.5}, {threshold = 80.0, damage = 1.5}, } ``` At value `85.0`, both thresholds are active, so the player takes `0.5 + 1.5 = 2.0` damage per tick. The value is automatically scaled by time so it stays consistent. *** #### FAQ **Q: Where do I configure effects?** In the status config file at `statuses//config.lua`, inside the `effect` array. **Q: Can one threshold have multiple effect keys?** Yes. Combine as many as you want on a single threshold. **Q: What happens when two statuses use the same effect key?** The system picks the most severe value automatically. They don't stack, only one `walkingStyle` or `screenEffect` plays at a time. **Q: Does damage work the same way?** No. Damage is the exception, it stacks across all active thresholds and all statuses. **Q: Do I need to restart after changing a config?** Yes. Restart the resource for config changes to take effect. **Q: What if I set `movementSpeed` to a very low value?** Anything below `0.8` starts to look and feel weird. We recommend staying at `0.8` or above. **Q: How does the `intensity` field work on `screenEffect` and `cameraShaking`?** Higher intensity = stronger visual effect. If you don't specify it, it defaults to `1.0`. Use lower values for subtle effects at early thresholds and ramp it up at higher ones. ### Direct Effects Canonical URL: https://docs.zykeresources.com/free-resources/status/guides/direct-effects Markdown URL: https://docs.zykeresources.com/free-resources/status/guides/direct-effects.md # Direct Effects #### Overview Direct effects let you apply temporary client-side effects to a player on-demand from any **server-side** script. Unlike status-driven effects (which activate automatically based on thresholds), direct effects are triggered explicitly by you through an export. Use cases include: * A drug script applying screen effects and stumbling for 60 seconds * A flashbang applying blurry vision and camera shake * An injury system slowing the player down * A food item giving a temporary strength boost Direct effects use the **same effect system** as statuses. They share the same queue, the same dominance resolution, and the same effect keys. If a status and a direct effect both try to control `walkingStyle`, the system picks the most severe one automatically. *** ### Table of Contents * [Adding Effects](/free-resources/status/guides/direct-effects#adding-effects) * [Real-World Examples](/free-resources/status/guides/direct-effects#real-world-examples) * [Effect Keys](/free-resources/status/guides/direct-effects#effect-keys) * [Simple vs Rich Values](/free-resources/status/guides/direct-effects#simple-vs-rich-values) * [Reactions](/free-resources/status/guides/direct-effects#reactions) * [Duration & Stacking](/free-resources/status/guides/direct-effects#duration-and-stacking) * [Activation Threshold](/free-resources/status/guides/direct-effects#activation-threshold) * [FAQ](/free-resources/status/guides/direct-effects#faq) *** ### Adding Effects Use the `AddDirectEffect` export from **any server-side script**: ```lua exports["zyke_status"]:AddDirectEffect(playerId, effects, activationThreshold) ``` | Parameter | Type | Required | Description | | --------------------- | --------- | -------- | ------------------------------------------------ | | `playerId` | `integer` | Yes | The server-side player ID | | `effects` | `table[]` | Yes | Array of effect entries (see below) | | `activationThreshold` | `integer` | No | Seconds of total duration before effects kick in | Each entry in the `effects` array has three fields: | Field | Type | Description | | ---------- | ----------------------------------------- | -------------------------------- | | `name` | `string` | The effect key (see table below) | | `value` | `string`, `number`, `boolean`, or `table` | The effect value | | `duration` | `number` | How long it lasts in seconds | **Basic Example** ```lua -- Slow the player and shake their camera for 30 seconds exports["zyke_status"]:AddDirectEffect(playerId, { {name = "movementSpeed", value = 0.7, duration = 30}, {name = "cameraShaking", value = {value = "DRUNK_SHAKE", intensity = 0.3}, duration = 30}, }) ``` *** ### Real-World Examples These examples show how you'd call `AddDirectEffect` from your own server scripts. All of them go inside a server-side event, callback, or item use handler. **Energy Drink — Temporary Speed Boost** A player drinks an energy drink and gets a short burst of speed and extra punch strength. ```lua -- Inside your item use handler (server side) exports["zyke_status"]:AddDirectEffect(playerId, { {name = "movementSpeed", value = 1.2, duration = 120}, {name = "strength", value = 1.5, duration = 120}, }) ``` The player runs faster and hits harder for 2 minutes, then everything returns to normal automatically. **Smoking Weed — Trippy Visuals** A player smokes a joint. They get a screen overlay, wobbly walking, and a slight stumble for a few minutes. ```lua exports["zyke_status"]:AddDirectEffect(playerId, { {name = "screenEffect", value = {value = "Dax_TripBlend01", intensity = 0.4}, duration = 180}, {name = "walkingStyle", value = "move_m@drunk@slightlydrunk", duration = 180}, {name = "stumble", value = 1.0, duration = 180}, }) ``` If they smoke another one while the first is still active, the durations stack. They'll be stumbling around for even longer. **Flashbang — Intense Short Burst** A player gets hit by a flashbang. Heavy screen effect, blurry vision, and camera shake — but it only lasts a few seconds. ```lua exports["zyke_status"]:AddDirectEffect(playerId, { {name = "screenEffect", value = {value = "BarryFadeOut", intensity = 1.5}, duration = 8}, {name = "blurryVision", value = true, duration = 8}, {name = "cameraShaking", value = {value = "DRUNK_SHAKE", intensity = 1.0}, duration = 8}, {name = "blockSprinting", value = true, duration = 5}, }) ``` **Leg Injury — Slowed Down** A player gets injured and can't run properly. Combine reduced speed with blocked sprinting and jumping. ```lua exports["zyke_status"]:AddDirectEffect(playerId, { {name = "movementSpeed", value = 0.6, duration = 300}, {name = "blockSprinting", value = true, duration = 300}, {name = "blockJumping", value = true, duration = 300}, {name = "walkingStyle", value = "move_m@drunk@a", duration = 300}, }) ``` The player limps around for 5 minutes. If they receive medical treatment, the effects expire naturally (or you can avoid adding them in the first place based on your logic). **Poisoned Food — Coughing Reaction** A player eats something dodgy. They start coughing with a looping animation and sound, plus a subtle screen tint. ```lua exports["zyke_status"]:AddDirectEffect(playerId, { {name = "screenEffect", value = {value = "InchPurple02", intensity = 0.3}, duration = 90}, { name = "reaction", value = { animation = { dict = "timetable@gardener@smoking_joint", clip = "idle_cough", flag = 49, start = 800, stop = 2000, }, sound = { name = {"cough_m1.wav", "cough_m2.ogg"}, volume = 0.2, distance = 5.0, }, loop = { delay = {8000, 15000}, }, }, duration = 90, }, }) ``` The player coughs every 8–15 seconds with a random sound pick, while a subtle purple tint sits on their screen for 90 seconds. *** ### Effect Keys These are the same keys used in status configs. All of them work with direct effects: | Key | Value Type | Description | | ---------------- | -------------------------------- | -------------------------------------------------------- | | `screenEffect` | `string` or `{value, intensity}` | Applies a timecycle modifier as a screen overlay | | `cameraShaking` | `string` or `{value, intensity}` | Shakes the gameplay camera | | `walkingStyle` | `string` | Changes the player's movement clipset (walk animation) | | `blurryVision` | `boolean` | Periodically fades a blur overlay in and out | | `blockJumping` | `boolean` | Prevents the player from jumping | | `blockSprinting` | `boolean` | Prevents the player from sprinting | | `movementSpeed` | `number` | Scales run/sprint speed (`1.0` = normal, lower = slower) | | `strength` | `number` | Scales unarmed melee damage (`1.0` = normal) | | `stumble` | `number` | Chance-based stumbling/ragdoll (higher = more frequent) | | `reaction` | `table` | Synchronized animation + sound (see below) | *** ### Simple vs Rich Values Some effect keys accept either a simple value or a table with extra options. Both forms are valid: ```lua -- Simple: just the effect name, uses default intensity of 1.0 {name = "screenEffect", value = "BarryFadeOut", duration = 30} -- Rich: with explicit intensity {name = "screenEffect", value = {value = "BarryFadeOut", intensity = 0.3}, duration = 30} ``` ```lua -- Simple {name = "cameraShaking", value = "DRUNK_SHAKE", duration = 30} -- Rich {name = "cameraShaking", value = {value = "DRUNK_SHAKE", intensity = 0.5}, duration = 30} ``` For `walkingStyle`, `blurryVision`, `blockJumping`, `blockSprinting`, `movementSpeed`, `strength`, and `stumble`, the simple value is all you need. *** ### Reactions Reactions combine animations and/or sounds. They work the same way as in status configs, but you pass the full reaction table as the `value`: ```lua exports["zyke_status"]:AddDirectEffect(playerId, { { name = "reaction", value = { animation = { dict = "timetable@gardener@smoking_joint", clip = "idle_cough", flag = 49, start = 800, stop = 2000, }, sound = { name = "stomach_growl.ogg", volume = 0.2, distance = 2.0, }, loop = { delay = {5000, 10000}, }, }, duration = 60, } }) ``` You don't need both `animation` and `sound`, either one on its own works fine. **Animation Fields** | Field | Type | Default | Description | | --------------- | --------- | ------- | ------------------------------------------------ | | `dict` | `string` | | Animation dictionary | | `clip` | `string` | | Animation clip name | | `flag` | `integer` | `49` | Animation flag (49 = upper body, doesn't freeze) | | `start` | `integer` | `nil` | Start time in ms (skip the beginning) | | `stop` | `integer` | `nil` | Stop time in ms (cut the animation short) | | `blendInSpeed` | `number` | `1.0` | How fast the animation blends in | | `blendOutSpeed` | `number` | `1.0` | How fast the animation blends out | | `forceAnim` | `boolean` | `false` | Force replay even if already playing | | `speed` | `number` | `1.0` | Playback speed | **Sound Fields** | Field | Type | Default | Description | | ---------- | -------------------------------- | ------- | ----------------------------------------------------------------------- | | `name` | `string`, `string[]`, or `table` | | Sound file(s). Supports `{male = ..., female = ...}` for gendered audio | | `volume` | `number` | `0.3` | Playback volume | | `distance` | `number` | `10.0` | How far other players can hear it | > Sounds require `zyke_sounds` to be running. If it's not available, the sound part is silently skipped. **Loop Settings** | Field | Type | Description | | ------- | ------------------------- | ------------------------------------------------------------ | | `delay` | `integer` or `{min, max}` | Delay in ms before repeating. Use a table for a random range | If `loop` is not defined, the reaction plays once and does not repeat. *** ### Duration & Stacking **Duration** is in seconds. The server counts down each effect's duration automatically. When it reaches zero, the effect is removed and the client is updated. **Stacking** works intelligently: * **Same effect key, same value**: Durations are merged (added together). Calling `AddDirectEffect` twice with `movementSpeed = 0.7` for 30 seconds gives you 60 seconds total. * **Same effect key, different value**: Both are tracked separately. The system uses the most dominant value. When the stronger one expires, the weaker one takes over automatically. * **Number values close together**: If two numeric values are within `0.1` of each other (configurable via `Config.Settings.directEffects.accuracyMerge`), they are merged to keep things efficient. ```lua -- First call: speed 0.7 for 30s exports["zyke_status"]:AddDirectEffect(playerId, { {name = "movementSpeed", value = 0.7, duration = 30}, }) -- Second call: same speed, durations add up (now 60s total) exports["zyke_status"]:AddDirectEffect(playerId, { {name = "movementSpeed", value = 0.7, duration = 30}, }) -- Third call: different speed, tracked separately -- 0.5 is more severe, so it plays first. When it expires, 0.7 takes over. exports["zyke_status"]:AddDirectEffect(playerId, { {name = "movementSpeed", value = 0.5, duration = 10}, }) ``` **Boolean effects** (like `blockJumping`) always merge into a single entry with the combined duration. *** ### Activation Threshold The optional `activationThreshold` parameter delays when effects actually start playing. The value is in **seconds of total accumulated duration** across all direct effects. ```lua -- Effects won't kick in until the player has at least 15 seconds of total direct effect duration exports["zyke_status"]:AddDirectEffect(playerId, { {name = "screenEffect", value = "BikerFilter", duration = 30}, }, 15) ``` This is useful for gradual build-up effects, where you don't want a single small dose to trigger visuals, but repeated doses should. The timer ticks in the background even before the threshold is met. Most of the time you can ignore this parameter and effects will start immediately. *** ### FAQ **Q: Is this a server-side or client-side export?**\ Server-side only. The system handles syncing to the client automatically. **Q: Are direct effects saved to the database?**\ Yes. They persist across reconnects and restarts. The remaining duration picks up where it left off. **Q: Do direct effects conflict with status effects?**\ They share the same queue. If both a status and a direct effect control the same key, the most severe value wins. They don't stack (except `damage`). **Q: Can I apply multiple effects in one call?**\ Yes. Pass multiple entries in the `effects` array and they are all applied at once. **Q: What happens when duration runs out?**\ The effect is automatically removed and the client is updated. If there is another effect of the same type still active (from stacking), it takes over seamlessly. **Q: Can I remove a direct effect early?**\ There is currently no dedicated export for early removal. The duration-based expiry handles cleanup automatically. **Q: Can I use effect keys that aren't listed here?**\ Only the keys listed above are supported. Custom keys require registering a new queue key in the effect manager. ### Broken Values & HUD Canonical URL: https://docs.zykeresources.com/free-resources/status/guides/broken-values-and-hud Markdown URL: https://docs.zykeresources.com/free-resources/status/guides/broken-values-and-hud.md # Broken Values & HUD #### Slow Updates If you are experiencing slow updates to your hud, the first thing you should try is going into `zyke_status/shared/config.lua` and add your exact hud resource name into the `hudOverriding` list. Just follow the format to add yours at the bottom. For those technical, this is because your hud isn't catching the standard events, so we must force an update to the player object more often. This is not the default because events are more performant. If your hud was fixed by changing this, you should reach out to the creator to correct it. > **Example:** > > ```lua > hudOverriding = { > ["example_hud"] = 1, > ["some_hud"] = 1, > ["your_hud_name"] = 1, -- Add your exact hud resource name here > } > ``` #### Value Inconsistencies If your hud is bouncing around in values, and the overall experience is that your consumables aren't working as expected, make sure that you have followed the [setup.md](/free-resources/status/setup "mention") guide. ### Setup Canonical URL: https://docs.zykeresources.com/free-resources/status/setup Markdown URL: https://docs.zykeresources.com/free-resources/status/setup.md # Setup ## ESX Guide > [!STEP] > ### Remove Old Status > > Remove your old esx\_status resource from the server and server.cfg. > > We replicate everything this resource does within zyke\_status and more! > [!STEP] > ### Remove Basic Needs > > Remove your old esx\_basicneeds resource from the server files, and optionally server.cfg. > > We replicate everything that happens in this resource within zyke\_status, no need for it anymore. *** ## QBCore Guide ### Basic Compatibility To get the basic compatibility going, you will need to modify the SetMetaData function. This allows us to catch any attempts to modify your status, which then dispatch it to our system to handle the rest. Our system will execute everything needed for the rest of your server to proceed as normal. > [!STEP] > ### Modify Player Method > > Navigate [here](https://github.com/qbcore-framework/qb-core/blob/main/server/player.lua#L274) and replace the entire function with the code provided below (L274-L281). > > ```lua > -- Modified to execute our export when triggered > -- Also blocks duplicate requests that will occur when we dispatch > function self.Functions.SetMetaData(meta, value) > if (not meta or type(meta) ~= "string") then return end > > local invoker = GetInvokingResource() > > -- If the request was not made by our resource, dispatch it to us and block the rest > -- Our system will re-trigger this event after updating all of our values and sync qb-core > if (invoker ~= "zyke_status") then > if (meta == "hunger" or meta == "thirst" or meta == "stress") then > if (value > 100.0) then value = 100.0 end > if (value < 0.0) then value = 0.0 end > > return exports["zyke_status"]:SetStatusValue(self.PlayerData.source, {meta, meta}, value) > end > end > > self.PlayerData.metadata[meta] = value > self.Functions.UpdatePlayerData() > end > ``` > [!STEP] > ### Full Control (Optional, Recommended) > > The instructions below removes all draining/additions/effects from the core. > > * **\[Hunger & Thirst Drain]** Navigate [here](https://github.com/qbcore-framework/qb-core/blob/main/server/events.lua#L151) and replace the entire event with the code provided below (L151-167). > > ```lua > -- Modified to remove hunger & thirst drain > RegisterNetEvent('QBCore:UpdatePlayer', function() > local ply = QBCore.Functions.GetPlayer(source) > if (not ply) then return end > > ply.Functions.Save() > end) > ``` > > * **\[Stress Effects]** Navigate [here](https://github.com/qbcore-framework/qb-hud/blob/main/client.lua#L977) and remove the entire thread (L977-L1011) *** ## Qbox Guide ### Basic Compatibility To get the basic compatibility going, you will need to modify the SetMetaData function. This allows us to catch any attempts to modify your status, which then dispatch it to our system to handle the rest. Our system will execute everything needed for the rest of your server to proceed as normal. > [!STEP] > ### Modify SetMetadata > > Replace the `SetMetadata` function inside of `qbx_core/server/player.lua` with the snippet below. > > ```lua > function SetMetadata(identifier, metadata, value) > if type(metadata) ~= 'string' then return end > > local player = type(identifier) == 'string' and (GetPlayerByCitizenId(identifier) or GetOfflinePlayer(identifier)) or GetPlayer(identifier) > > if not player then return end > > local oldValue > > if metadata:match('%.') then > local metaTable, metaKey = metadata:match('([^%.]+)%.(.+)') > > if metaKey:match('%.') then > lib.print.error('cannot get nested metadata more than 1 level deep') > end > > oldValue = player.PlayerData.metadata[metaTable] > > player.PlayerData.metadata[metaTable][metaKey] = value > > metadata = metaTable > else > oldValue = player.PlayerData.metadata[metadata] > if (metadata == "hunger" or metadata == "thirst" or metadata == "stress") then > if (GetInvokingResource() ~= "zyke_status") then > -- We don't support changing these values offline at the moment > if (player.Offline) then return end > > if (value > 100.0) then value = 100.0 end > if (value < 0.0) then value = 0.0 end > > local source = player.PlayerData.source > > return exports["zyke_status"]:SetStatusValue(source, {metadata, metadata}, value) > end > end > > player.PlayerData.metadata[metadata] = value > end > > UpdatePlayerData(identifier) > > if not player.Offline then > local playerState = Player(player.PlayerData.source).state > > TriggerClientEvent('qbx_core:client:onSetMetaData', player.PlayerData.source, metadata, oldValue, value) > TriggerEvent('qbx_core:server:onSetMetaData', metadata, oldValue, value, player.PlayerData.source) > > if (metadata == 'hunger' or metadata == 'thirst' or metadata == 'stress') then > value = lib.math.clamp(value, 0, 100) > > if playerState[metadata] ~= value then > playerState:set(metadata, value, true) > end > end > > if (metadata == 'dead' or metadata == 'inlaststand') then > playerState:set('canUseWeapons', not value, true) > end > end > > if metadata == 'inlaststand' or metadata == 'isdead' then > if player.Offline then > SaveOffline(player.PlayerData) > else > Save(player.PlayerData.source) > end > end > end > ``` > [!STEP] > ### Full Control (Optional, Recommended) > > The instructions below removes all draining/additions/effects from the core. > > * **\[Hunger & Thirst Drain]** Navigate [here](https://github.com/Qbox-project/qbx_core/blob/main/server/loops.lua#L15) and remove the entire thread (L15-L23). > * **\[Stress Effects]** Navigate [here](https://github.com/Qbox-project/qbx_hud/blob/main/client/main.lua#L884) and remove the entire thread (L884-L918) ### Propaligner Canonical URL: https://docs.zykeresources.com/free-resources/propaligner Markdown URL: https://docs.zykeresources.com/free-resources/propaligner.md # Propaligner ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/propaligner/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/propaligner/resource-description.md # Resource Description ## Links * [Download](https://github.com/ZykeWasTaken/zyke_propaligner) ## Information This is an easy-to-use solution to your prop alignment hell. With our sleek UI you can utilize inputs, history & presets to speed up your alignment for your props. The entire project is the first effort to make a great alignment menu, and more updates to streamline the process will come in the future once I am available to work on it. ## Features * Sleek & modern UI for all inputs along with smart validation. * Supports multiple props. * Offset & rotation to player. * Particle alignments offset from the prop. * Possible to integrate into resources using exports, provide & return alignments with ease. * Plays animation for realistic interactions, with different speeds. * Server-wide presets to load pre-defined configurations. * Export & import presets to share. * Client-sided history to save your recent configurations. * Visualize the data in Lua & JSON format for easy implementation. ## Get Started * Open the menu via the command in the config, `/palign` by default. * Start filling out the information, or go to `Presets` to import a base to get started from. ### Demo Presets You can paste these presets into the import input, press the import button and try them out. #### Plate With Curry ```json { "label": "Curry (Dual Prop)", "data": { "dict": "anim@scripted@island@special_peds@pavel@hs4_pavel_ig5_caviar_p1", "clip": "base_idle", "props": [ {"rotation": {"x": 0, "y": 0, "z": -50}, "prop": "prop_cs_plate_01", "bone": 60309, "offset": {"x": 0, "y": 0, "z": 0}}, {"rotation": {"x": 180, "y": 180, "z": 0}, "prop": "prop_cs_fork", "bone": 28422, "offset": {"x": 0, "y": 0, "z": 0}} ] } } ``` #### Water Bottle ```json { "label": "Water Bottle", "data": { "dict": "mp_player_intdrink", "clip": "loop_bottle", "props": [ {"rotation": {"x": -103.202, "y": -68.066, "z": 2.814}, "prop": "prop_ld_flow_bottle", "bone": 18905, "offset": {"x": 0.122, "y": -0.038, "z": 0.033}} ] } } ``` #### Burger ```json { "label": "Burger", "data": { "dict": "mp_player_inteat@burger", "clip": "mp_player_int_eat_burger", "props":[ {"bone": 18905, "model": "prop_cs_burger_01", "rotation": {"x": 31.162, "y": 136.033, "z": -13.003}, "prop": "prop_cs_burger_01", "offset": {"x": 0.144, "y": 0.027, "z": 0.040}} ] } } ``` #### Soda Can (Sprunk) ```json { "label":"Soda Can", "data": { "dict":"mp_player_intdrink", "clip":"loop_bottle", "props": [ {"bone": 18905,"model": "prop_ld_can_01b", "rotation": {"x":-103.202,"y":-68.066,"z":2.814}, "prop": "prop_ld_can_01b", "offset":{"x": 0.122, "y": -0.007, "z": 0.035}} ] } } ``` #### Cigarette ```json { "label": "Cigarette & Particles", "data": { "dict": "amb@world_human_aa_smoke@male@idle_a", "clip": "idle_a", "props": [ {"bone": 64097, "prop": "ng_proc_cigarette01a", "rotation": {"x": 100, "y": 0, "z": 100}, "offset": {"x": 0.02, "y": 0.02, "z": -0.008}, "particles": [ {"clip": "exp_grd_bzgas_smoke", "size": 1, "dict": "core", "offset": {"x": -0.068, "y": 0.0, "z": 0.0}} ] } ] } } ``` ## Showcase ![](https://github.com/user-attachments/assets/9d91ec51-8fb7-40cb-bf23-59148d8c36f0) ![](https://github.com/user-attachments/assets/543885d7-ca03-4374-b473-83085684f182) ![](https://r2.fivemanage.com/mS9apQyi6ahmBBRtVnQAv/PropalignerShowcaseAlignment.png) ![](https://github.com/user-attachments/assets/05c04642-e1ec-4eea-b534-17ccbec75dc3) ## Development Details * We use a rotation order of 1, see [native documentation](https://docs.fivem.net/natives/?_0xAFBD61CC738D9EB9) for more info. ## Dependencies * [zyke\_lib](https://github.com/ZykeWasTaken/zyke_lib) ## Credits * [https://github.com/DemiAutomatic/object\_gizmo](https://github.com/DemiAutomatic/object_gizmo) * [https://github.com/TGIANN/tgiann-attachproptoplayereditor](https://github.com/TGIANN/tgiann-attachproptoplayereditor) ### Exports & Events Canonical URL: https://docs.zykeresources.com/free-resources/propaligner/exports-and-events Markdown URL: https://docs.zykeresources.com/free-resources/propaligner/exports-and-events.md # Exports & Events > [!INFO] > **Types & Classes** > > All types & classes can be found in types.lua. > [!INFO] > **Suggestions?** > > If you wish to have any exports and or events added, please head over to our Discord and create a suggestion post. We are happy to allow for easier integration within other resources. ## Client Exports ### Configure Alignments > Opens the menu and inserts the data you provided, and returns all configured alignments when you close the menu.\ > \ > This is mainly meant to be used within other resources where you want to grab alignments.\ > \ > In here you can also enable a back button, to void confusion when loading & then returning safely.\ > \ > **Example:** > > ```lua > ---@param data AlignmentData > ---@param backButton? boolean > exports["zyke_propaligner"]:ConfigureAlignments(data, backButton) > ``` ### Set Alignment Data > If you have pre-defined data you want to insert, use this. In here you can also enable a back button, to void confusion when loading & then returning safely.\ > \ > **Example:** > > ```lua > ---@param data AlignmentData > ---@param backButton? boolean | "prev" @If "prev", use the previous setting > exports["zyke_propaligner"]:SetAlignmentData(bones) > ``` ### Set Bones > Sets the available bones in the select menu. This is mainly meant to filter out tons of uncommon bones.\ > \ > Is using `"default"`, it will reset the bones to our base config in `shared/bones.lua`.\ > Id & idx are bone values.\ > \ > **Example:** > > ```lua > ---@param bones {name: string, id: integer, idx: integer}[] | "default" > exports["zyke_propaligner"]:SetBones(bones) > ``` ### Dependencies Canonical URL: https://docs.zykeresources.com/free-resources/propaligner/dependencies Markdown URL: https://docs.zykeresources.com/free-resources/propaligner/dependencies.md # Dependencies ### Click the names to be redirected * [zyke\_lib](https://github.com/ZykeWasTaken/zyke_lib) ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/propaligner/changelog Markdown URL: https://docs.zykeresources.com/free-resources/propaligner/changelog.md # Changelog
Changelog - Version 1.5.2 ## Changes * Fixed an issue where editing particles would cause your prop to disappear. * Added support for locking prop alignment editing controls via the `restrictedFields` config, so server owners can restrict which fields players are allowed to modify. ## Files Affected * nui/\* * README.md * fxmanifest.lua

2026-05-24 15:27 CET

Changelog - Version 1.5.1 ## Changes * Rotation order conversion is now applied in the visualizer for accurate preview of rotation values. * Added field restriction support: hosts can now disable specific alignment inputs and provide custom tooltips via `restrictedFields`. * Collection fields (e.g., particles) now support a configurable maximum entry count through restrictions. * Dropdown menus now support nested sub-lists, making it easier to navigate grouped options. * Improved the data visualizer to prioritize vector format over table format when both are present. * Fixed visualization of empty tables, which are now truncated to avoid empty or confusing entries. * Fixed disabled buttons in the UI to show tooltips, clarifying why they are unavailable. * Adjusted the save button color for better visual consistency. ## Files Affected * client/alignment.lua * shared/types.lua * nui/\* * README.md * fxmanifest.lua
Changelog - Version 1.5.0 ### Changes * Updated the gizmo to be more 3D-aware, making adjustments relative to your ped's orientation. * Added animation timeline UI with draggable playhead for precise control. * Replaced scaleform keybind prompts with a new NUI keybind display. * Moved the "current position" entry to the top of the alignment position list for quicker access. * Fixed an issue where cancelling an animation while paused would not work correctly. * Improved toggle animation sync to better match the new system. * Added support for aligning props without playing an animation (standalone alignment). * Added an option to disable idle animations when using the menu. * Added export to retrieve bone data for use by external resources. * Fixed history panel showing invalid data and incorrect entry lengths. * Added helper tooltip in the prop list for easier object identification. * Added 16 new language translations: Arabic, Czech, German, Spanish, French, Italian, Japanese, Lithuanian, Dutch, Polish, Portuguese, Romanian, Swedish, Thai, Turkish, and Chinese. ### Files Affected * Replace all.
Changelog - Version 1.4.4 ### Changes * Fixed an issue retrieving the loaded state. ### Files Affected * nui/\* * fxmanifest.lua
Changelog - Version 1.4.3 ### Changes * Moved to the new zyke\_lib loader. * Removed loading from incorrect button. ### Files Affected * client/events.lua * nui/\* * fxmanifest.lua
Changelog - Version 1.4.2 ### Changes * Fixed animations with no set duration breaking the player. ### Files Affected * client/alignment.lua * client/functions.lua * fxmanifest.lua
Changelog - Version 1.4.1 ### Changes * Selactable pre-defined base animations to get started quicker. ### Files Affected * client/events.lua * shared/animations.lua * nui/\* * locales/en.lua * fxmanifest.lua
Changelog - Version 1.4.0 ### Changes * Removing internal values from the data that is returned & inserted into the history. * Prohibiting attempting to open the UI before it has mounted. * Visualizing current data & preset data. * Optional positioning for ped during alignment. * Extended the README.md with examples. ### Files Affected * client/alignment.lua * client/commands.lua * client/events.lua * nui/\* * shared/config.lua * shared/types.lua * locales/en.lua * README.md * fxmanifest.lua
Changelog - Version 1.3.0 ### Changes * Started proper version tracking. * Re-structured several nui source components. * Changed prop accordions into buttons and moved the alignments into a modal. * Added the ability to configure particles for each prop. Mainly to expedite adding new smokeables in zyke\_smoking. Files Affected * client/alignment.lua * nui/\* * shared/types.lua * locales/en.lua * README.md * fxmanifest.lua
### Realistic Vehicles Canonical URL: https://docs.zykeresources.com/free-resources/realistic-vehicles Markdown URL: https://docs.zykeresources.com/free-resources/realistic-vehicles.md # Realistic Vehicles ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/realistic-vehicles/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/realistic-vehicles/resource-description.md # Resource Description ## Links * [Download](https://github.com/Zyke-Resources/zyke_realisticvehicles) ## Information This resource was made to more accurately capture vehicle deformation and stripped of all unnecessary functions. And recently, modifying vehicle damage multipliers. Specifically, this resource manages the following: * Vehicle body deformation. * Vehicle health damage multipliers (engine, body, petrol tank). * Torque reduction during engine damage. * Vehicle flip prevention. All options are practically opt-in/out, with presets ranging from arcade to balanced to hardcore. ### Configuration You can find all of the configuration you need in [config.md](/free-resources/realistic-vehicles/config "mention"). ### Config Canonical URL: https://docs.zykeresources.com/free-resources/realistic-vehicles/config Markdown URL: https://docs.zykeresources.com/free-resources/realistic-vehicles/config.md # Config ### Settings > General resource settings that affect development and diagnostics. #### debug > Enables debug behavior for the resource. Only enable this in development environments because it exposes dangerous commands.\ > \ > **Example:** > > ```lua > debug = false > ``` ### DamageSystem > Configures the realistic vehicle damage system. The selected preset is loaded from `shared/presets.lua`, then any values in `overrides` are applied on top of that preset. #### enabled > Master toggle for the entire damage system. When set to `false`, all damage-related logic is disabled and the resource skips damage processing entirely. Visual deformation syncing continues to work independently regardless of this setting.\ > \ > **Example:** > > ```lua > enabled = true > ``` #### preset > Selects the preset level that defines the default values for all damage-related settings. Valid levels are `1` for Arcade, `2` for Casual, `3` for Balanced, `4` for Realistic, and `5` for Hardcore. Balanced is the recommended default. If an invalid level is configured, the resource falls back to Balanced.\ > \ > **Example:** > > ```lua > preset = 3 > ``` #### overrides > A table of key-value pairs that override individual damage settings after the preset is applied. Each key must match a valid damage system key from `shared/presets.lua`; for example, `{ limpMode = true, damageFactorEngine = 5.0 }` changes only those values while keeping the rest of the selected preset.\ > \ > **Example:** > > ```lua > overrides = {} > ``` **Choosing Between Presets And Overrides** Use `preset` when you want a complete difficulty profile. Use `overrides` when you like a preset overall but want to tune one or more values. The resource resolves the damage system in this order: 1. Reads `Config.DamageSystem.preset`. 2. Loads that preset from `shared/presets.lua`. 3. Falls back to preset `3` if the selected preset does not exist. 4. Copies every value from the preset into `Config.DamageSystem`. 5. Applies every value from `Config.DamageSystem.overrides` on top. You normally should not edit `shared/presets.lua`. Edit it only if you want to permanently change the built-in preset definitions for the whole resource. If you only want to customize your server, keep using `shared/config.lua` and place changed values inside `overrides`. After changing preset definitions and restarting the resource, players should re-enter their vehicle so the new handling values are applied. ```lua Config.DamageSystem = { enabled = true, preset = 3, overrides = { limpMode = true, damageFactorEngine = 5.0, }, } ``` **Preset Values** | Key | Arcade | Casual | Balanced | Realistic | Hardcore | | ----------------------------- | ------------: | ------------: | ------------: | ------------: | ------------: | | `damageFactorEngine` | `0.4` | `0.8` | `1.2` | `1.6` | `3.2` | | `damageFactorBody` | `0.5` | `1.5` | `2.0` | `3.0` | `5.0` | | `damageFactorPetrolTank` | `10.0` | `30.0` | `48.0` | `64.0` | `100.0` | | `deformationExponent` | `0.6` | `0.5` | `0.45` | `0.4` | `0.3` | | `collisionDamageExponent` | `0.8` | `0.7` | `0.65` | `0.6` | `0.5` | | `engineDamageExponent` | `0.8` | `0.7` | `0.65` | `0.6` | `0.5` | | `deformationMultiplier` | `4.2` | `5.6` | `7.0` | `8.4` | `11.2` | | `weaponsDamageMultiplier` | `0.5` | `1.0` | `1.5` | `2.0` | `3.0` | | `degradingFailureThreshold` | `240.0` | `360.0` | `420.0` | `480.0` | `540.0` | | `cascadingFailureThreshold` | `150.0` | `250.0` | `300.0` | `360.0` | `450.0` | | `engineSafeGuard` | `200.0` | `150.0` | `120.0` | `100.0` | `80.0` | | `degradingHealthSpeedFactor` | `0.4` | `1.0` | `1.6` | `2.0` | `3.0` | | `cascadingFailureSpeedFactor` | `0.4` | `0.8` | `1.2` | `1.6` | `2.4` | | `torqueMultiplierEnabled` | `false` | `true` | `true` | `true` | `true` | | `torqueDegradationThreshold` | `200` | `400` | `500` | `600` | `700` | | `limpMode` | `true` | `true` | `false` | `false` | `false` | | `limpModeMultiplier` | `0.4` | `0.25` | `0.19` | `0.19` | `0.15` | | `preventVehicleFlip` | `false` | `false` | `true` | `true` | `true` | | `classDamageMultiplier` | default table | default table | default table | default table | default table | **Override Keys** | Key | What It Controls | Notes / Range | | ----------------------------- | ------------------------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------- | | `damageFactorEngine` | Multiplies engine health damage. | Higher values make engine damage harsher. | | `damageFactorBody` | Multiplies body health damage. | Higher values make body damage harsher. Also affects weapon damage handling normalization. | | `damageFactorPetrolTank` | Multiplies petrol tank health damage. | Higher values make petrol tank damage harsher. | | `weaponsDamageMultiplier` | Sets weapon damage handling for vehicles. | Use `0.0`-`10.0`, or `-1` to leave weapon damage handling untouched. | | `deformationExponent` | Compresses each vehicle's original deformation handling before applying `deformationMultiplier`. | Lower preset values make deformation tuning more aggressive. | | `collisionDamageExponent` | Compresses each vehicle's original collision damage handling toward `1.0`. | Used when applying `fCollisionDamageMult`. | | `engineDamageExponent` | Compresses each vehicle's original engine damage handling toward `1.0`. | Used when applying `fEngineDamageMult`. | | `deformationMultiplier` | Multiplies visual deformation handling. | For manual overrides, use `0.0`-`10.0`, or `-1` to leave deformation handling untouched. The Hardcore preset uses `11.2`. | | `degradingFailureThreshold` | Engine health threshold where slow passive degradation starts. | Higher values make degradation start earlier. | | `cascadingFailureThreshold` | Engine health threshold where rapid cascading failure starts. | Higher values make severe failure start earlier. | | `engineSafeGuard` | Minimum engine health floor while not in fire mode. | Lower values allow the engine to degrade further. If limp mode is disabled, vehicles below this point become undriveable. | | `degradingHealthSpeedFactor` | Speed of slow passive engine degradation. | Higher values drain engine health faster between the degrading and cascading thresholds. | | `cascadingFailureSpeedFactor` | Speed of rapid engine degradation. | Higher values drain engine health faster below the cascading threshold. | | `torqueMultiplierEnabled` | Enables torque loss as engine health drops. | Boolean. Uses `torqueDegradationThreshold`. | | `torqueDegradationThreshold` | Engine health below which torque starts degrading. | Higher values make torque loss begin earlier. | | `limpMode` | Allows a damaged vehicle to keep moving at reduced power near the safeguard threshold. | Boolean. Uses `limpModeMultiplier`. | | `limpModeMultiplier` | Torque multiplier used during limp mode. | The override guidance in `presets.lua` recommends `0.05`-`0.25`; higher values make limp mode less restrictive. The Arcade preset uses `0.4`. | | `preventVehicleFlip` | Helps prevent upside-down vehicles from being flipped back over by throttle input. | Boolean. | | `classDamageMultiplier` | Per-class damage multiplier table for vehicle classes `0`-`21`. | Higher values make that class take more damage. Classes not listed use `1.0`. | **Default Class Multipliers** `classDamageMultiplier` lets you tune damage by GTA vehicle class. For example, the default table makes motorcycles weaker than most cars and makes industrial vehicles tougher. | Class | Vehicle Type | Default | | ----: | --------------- | ------: | | `0` | Compacts | `1.0` | | `1` | Sedans | `1.0` | | `2` | SUVs | `1.0` | | `3` | Coupes | `1.0` | | `4` | Muscle | `1.0` | | `5` | Sports Classics | `1.0` | | `6` | Sports | `1.0` | | `7` | Super | `1.0` | | `8` | Motorcycles | `1.25` | | `9` | Off-road | `0.7` | | `10` | Industrial | `0.25` | | `11` | Utility | `1.0` | | `12` | Vans | `1.0` | | `13` | Cycles | `1.0` | | `14` | Boats | `0.5` | | `15` | Helicopters | `1.0` | | `16` | Planes | `1.0` | | `17` | Service | `0.75` | | `18` | Emergency | `0.75` | | `19` | Military | `0.75` | | `20` | Commercial | `1.0` | | `21` | Trains | `1.0` | Cycles, helicopters, planes, and trains are excluded from the damage loop, so their default multipliers are listed for completeness but are not used by normal damage processing. ```lua overrides = { classDamageMultiplier = { [0] = 1.0, -- Compacts 1.0, -- Sedans 1.0, -- SUVs 1.0, -- Coupes 1.0, -- Muscle 1.0, -- Sports Classics 1.0, -- Sports 1.0, -- Super 1.25, -- Motorcycles 0.7, -- Off-road 0.25, -- Industrial 1.0, -- Utility 1.0, -- Vans 1.0, -- Cycles 0.5, -- Boats 1.0, -- Helicopters 1.0, -- Planes 0.75, -- Service 0.75, -- Emergency 0.75, -- Military 1.0, -- Commercial 1.0, -- Trains }, } ``` ### Exports & Events Canonical URL: https://docs.zykeresources.com/free-resources/realistic-vehicles/exports-and-events Markdown URL: https://docs.zykeresources.com/free-resources/realistic-vehicles/exports-and-events.md # Exports & Events > [!INFO] > **Types & Classes** > > The public data shapes used by these exports are documented below in [#data-types](/free-resources/realistic-vehicles/exports-and-events#data-types "mention"). > [!INFO] > **Suggestions?** > > If you wish to have any exports and or events added, please head over to our Discord and create a suggestion post. We are happy to allow for easier integration within other resources. ## Data Types > These are the public data shapes used by the exports below. Internal debug and runtime-only classes are not part of the public API. > > ```lua > ---@class NativeDeformationEntry > ---@field [1] number @ Local x offset > ---@field [2] number @ Local y offset > ---@field [3] number @ Local z offset > ---@field [4] number @ Deformation strength > > ---@class VectorDeformationEntry > ---@field [1] vector3 @ Local offset > ---@field [2] number | vector3 @ Deformation strength or native deformation vector > > ---@alias VehicleDeformationEntry NativeDeformationEntry | VectorDeformationEntry > > ---@class WheelLossStateEntry > ---@field index integer @ Wheel index detached from the vehicle > ---@field reason? string @ Detach reason stored for repair/debug flows > ---@field time? integer @ Server os.time timestamp when the wheel detached > > ---@class WheelLossStateData > ---@field entries? WheelLossStateEntry[] @ Detached wheel entries in the vehicle state bag > ---@field integrity? table @ Wheel integrity keyed by wheel index > > ---@class VehicleDamageData > ---@field version integer @ Data format version > ---@field deformation VehicleDeformationEntry[] | nil @ Saved vehicle body deformation > ---@field wheelLoss WheelLossStateData | nil @ Saved wheel-loss and wheel-integrity state > ``` ## Client Exports ### Get Vehicle Damage Data > Grabs all custom damage data managed by this resource in one master table. Use this in framework vehicle-property or garage save functions so future damage data can be added without changing integrations again.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@return VehicleDamageData | nil > local damageData = exports["zyke_realisticvehicles"]:GetVehicleDamageData(veh) > ``` > \ > **Example Data:** > > ```lua > { > version = 1, > deformation = { > {1.20, -2.40, 0.00, 0.18}, > }, > wheelLoss = { > entries = {}, > integrity = { > [0] = 100.0, > [1] = 74.5, > }, > }, > } > ``` ### Set Vehicle Damage Data > Applies custom damage data that was previously saved with [#get-vehicle-damage-data](/free-resources/realistic-vehicles/exports-and-events#get-vehicle-damage-data "mention"). Run this after the framework has applied its normal vehicle properties.\ > \ > This is the preferred integration export for garages and framework vehicle-property functions. The lower-level deformation and wheel-loss exports remain available for custom tools.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@param damageData VehicleDamageData > ---@return boolean > local success = exports["zyke_realisticvehicles"]:SetVehicleDamageData(veh, damageData) > ``` > \ > **Example Result:** > > ```lua > true > ``` ### Set Deformation > Sets the deformation of a vehicle. This should be triggered right when it is spawned, like in a garage script.\ > \ > This shouldn't be triggered all by itself, it should only set the deformation that has been captured by the [#get-deformation](/free-resources/realistic-vehicles/exports-and-events#get-deformation "mention") export.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@param deformation VehicleDeformationEntry[] > exports["zyke_realisticvehicles"]:SetDeformation(veh, deformation) > ``` > \ > **Example Data:** > > ```lua > local deformation = { > {1.20, -2.40, 0.00, 0.18}, > {-1.20, -2.40, 0.00, 0.11}, > } > ``` ### Get Deformation > Grabs the deformation of a vehicle. This should be used when you want to save the current state to apply later, like when parking your vehicle in a garage.\ > \ > This, by itself, does nothing. It should be used in combination with [#set-deformation](/free-resources/realistic-vehicles/exports-and-events#set-deformation "mention") to retrieve & apply deformation.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@return NativeDeformationEntry[] | nil > local deformation = exports["zyke_realisticvehicles"]:GetDeformation(veh) > ``` > \ > **Example Data:** > > ```lua > { > {1.20, -2.40, 0.00, 0.18}, > {-1.20, -2.40, 0.00, 0.11}, > } > ``` ### Fix Deformation > Fixes the deformation on a car. As this is written, all the export does is run the [SetVehicleDeformationFixed](https://docs.fivem.net/natives/?_0x953DA1E1B12C0491) native, but this may be changed in a future update. So if you want stability, trigger this export, even if it's not necessary right now.\ > \ > **Example:** > > ```lua > ---@param veh integer > exports["zyke_realisticvehicles"]:FixDeformation(veh) > ``` ### Wheel Index Reference > A wheel index is the number used to choose which wheel you want to check, damage, repair, or detach. Cars and bikes use different numbers.\ > \ > **Cars:** > - `0` = Front left > - `1` = Front right > - `2` = Back left > - `3` = Back right > \ > **Bikes:** > - `0` = Back wheel > - `1` = Front wheel > \ > For example, `0` means front left on a car, but back wheel on a bike. ### Get Detached Wheels > Grabs the wheels currently tracked as detached on a vehicle. This is useful when another resource needs to save, inspect, or display the wheel-loss state.\ > \ > Each entry contains the wheel index, the stored reason, and the server `os.time()` timestamp from when the wheel was detached. If the vehicle does not have detached wheels, this returns an empty table.\ > \ > See [#wheel-index-reference](/free-resources/realistic-vehicles/exports-and-events#wheel-index-reference "mention") before displaying or manually using the returned `index` value.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@return WheelLossStateEntry[] > local detachedWheels = exports["zyke_realisticvehicles"]:GetDetachedWheels(veh) > ``` > \ > **Example Data:** > > ```lua > { > { > index = 0, > reason = "landing_integrity_failure", > time = 1747382400, > }, > { > index = 3, > reason = "direct_hit", > time = 1747382442, > }, > } > ``` ### Get Wheel Integrity > Grabs the current wheel integrity values for a vehicle. This is useful when a garage, repair, or inspection resource needs to show or save the current condition of each wheel.\ > \ > The returned table is keyed by wheel index. A higher value means a healthier wheel. `0` means the wheel has fully failed, or has been detached by the wheel-loss system.\ > \ > See [#wheel-index-reference](/free-resources/realistic-vehicles/exports-and-events#wheel-index-reference "mention") before turning the table keys into player-facing wheel labels.\ > \ > If the vehicle is not valid, this returns an empty table.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@return table > local integrity = exports["zyke_realisticvehicles"]:GetWheelIntegrity(veh) > > for wheelIndex, value in pairs(integrity) do > print(("Wheel %d integrity: %.1f"):format(wheelIndex, value)) > end > ``` > \ > **Example Data:** > > ```lua > { > [0] = 100.0, > [1] = 74.5, > [2] = 0.0, > [3] = 92.0, > } > ``` ### Open Wheel Integrity Menu > Opens the zyke_lib context menu overview for wheel integrity. If a vehicle is passed, that vehicle is inspected. If no vehicle is passed, the export inspects the vehicle the player is in, or the closest supported vehicle within `Config.DamageSystem.wheelLossIntegrityMenu.maxDistance`.\ > \ > This is meant for overview-style inspection tools. If `Config.DamageSystem.wheelLossIntegrityMenu.enabled` is `false`, this export returns `false` and does not open the menu.\ > \ > **Example:** > > ```lua > ---@param veh? integer > ---@return boolean > local opened = exports["zyke_realisticvehicles"]:OpenWheelIntegrityMenu(veh) > ``` > \ > **Example Result:** > > ```lua > true > ``` ### Toggle Wheel Integrity Menu > Toggles the zyke_lib context menu overview for wheel integrity. If the overview is already open, it closes it. If it is closed, it behaves like [#open-wheel-integrity-menu](/free-resources/realistic-vehicles/exports-and-events#open-wheel-integrity-menu "mention").\ > \ > This is useful for keybinds, radial menu entries, or inspection tools that should use one action to open and close the overview.\ > \ > **Example:** > > ```lua > ---@param veh? integer > ---@return boolean > local toggled = exports["zyke_realisticvehicles"]:ToggleWheelIntegrityMenu(veh) > ``` > \ > **Example Result:** > > ```lua > true > ``` ### Detach Vehicle Wheel > Detaches a wheel from a vehicle and stores that wheel as detached in the vehicle state. This should be used when another resource wants to force a wheel-loss event, such as a mechanic tool, scripted crash, or admin/debug action.\ > \ > The export also sets the wheel integrity to `0`, stores the detach reason, and prevents the same wheel from being detached twice.\ > \ > See [#wheel-index-reference](/free-resources/realistic-vehicles/exports-and-events#wheel-index-reference "mention") before choosing the `wheelIndex`, especially when supporting both cars and bikes.\ > \ > This returns `true` when the wheel was detached and persisted. It returns `false` if the export fails for any reason.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@param wheelIndex integer > ---@param reason? string > ---@return boolean > local success = exports["zyke_realisticvehicles"]:DetachVehicleWheel(veh, wheelIndex, "mechanic_tool") > ``` > \ > **Example Result:** > > ```lua > true > ``` ### Clear Wheel Loss Data > Clears only the wheel-loss data from a vehicle. This removes the stored detached wheels and resets the stored wheel integrity state, so the wheel-loss system no longer treats the vehicle as having broken wheels.\ > \ > This does not repair, reattach, or visually fix any wheels by itself. Use this when another resource has already repaired the vehicle and you only need to clear this resource's saved wheel-loss data.\ > \ > This returns `true` when the data was cleared. It returns `false` if the export fails for any reason.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@return boolean > local success = exports["zyke_realisticvehicles"]:ClearWheelLossData(veh) > ``` > \ > **Example Result:** > > ```lua > true > ``` ### Repair Vehicle Wheels > Fixes the vehicle tyres and wheel health, then clears the wheel-loss data for that vehicle. This should be used by repair flows that are meant to reset wheel-loss tracking, not by save/load logic that only wants to clear stored data.\ > \ > This returns `true` when the repair/reset ran. It returns `false` if the export fails for any reason.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@return boolean > local success = exports["zyke_realisticvehicles"]:RepairVehicleWheels(veh) > ``` > \ > **Example Result:** > > ```lua > true > ``` ### Repair Vehicle Damage > Clears this resource's custom repair state for a vehicle. This fixes deformation, clears saved deformation data, repairs wheel-loss damage, and clears wheel-loss data. Use this after another resource has already run its normal vehicle repair, such as `SetVehicleFixed(vehicle)`.\ > \ > This returns `true` when the repair/reset ran. It returns `false` or `nil` if no valid vehicle was provided or found.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@return boolean? > local success = exports["zyke_realisticvehicles"]:RepairVehicleDamage(veh) > ``` > \ > **Example Result:** > > ```lua > true > ``` ### Get Wheel Loss Data > Grabs all wheel-loss data in one table. This is the easiest export to use when saving vehicle properties in a garage or framework vehicle-property function.\ > \ > The returned table contains detached wheel entries and wheel integrity values. Store it together with the rest of the vehicle properties, then apply it later with [#set-wheel-loss-data](/free-resources/realistic-vehicles/exports-and-events#set-wheel-loss-data "mention").\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@return WheelLossStateData > local wheelLoss = exports["zyke_realisticvehicles"]:GetWheelLossData(veh) > ``` > \ > **Example Data:** > > ```lua > { > entries = { > { > index = 1, > reason = "direct_hit", > time = 1747382442, > }, > }, > integrity = { > [0] = 100.0, > [1] = 36.5, > [2] = 100.0, > [3] = 100.0, > }, > } > ``` ### Set Wheel Loss Data > Applies wheel-loss data that was previously saved with [#get-wheel-loss-data](/free-resources/realistic-vehicles/exports-and-events#get-wheel-loss-data "mention"). This is meant for vehicle spawn/load flows, especially garages that already apply framework vehicle properties.\ > \ > This restores detached wheels and partial wheel integrity. If `nil` is passed as the data, the stored wheel-loss data is cleared.\ > \ > This returns `true` when the data was applied or cleared. It returns `false` if the export fails for any reason.\ > \ > **Example:** > > ```lua > ---@param veh integer > ---@param wheelLoss? WheelLossStateData | WheelLossStateEntry[] > ---@return boolean > local success = exports["zyke_realisticvehicles"]:SetWheelLossData(veh, wheelLoss) > ``` > \ > **Example Result:** > > ```lua > true > ``` ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/realistic-vehicles/changelog Markdown URL: https://docs.zykeresources.com/free-resources/realistic-vehicles/changelog.md # Changelog
Changelog - Version 2.1.0 ## Changes * Vehicles now respond to different terrain materials (grass, dirt, sand, mud) with realistic handling changes, including suspension sink and traction adjustments. * Terrain sink visually lowers the vehicle on soft surfaces. * Acceleration, top speed and traction are affected based on surface material. * Introduced wheel integrity notifications and a wheel inspection tool. * Players receive warnings when wheel health drops below thresholds. * The 'wheel_scanner' item opens a wheel integrity overview menu. * Fixed vehicles becoming incorrectly undriveable at low fuel levels. * The resource now prevents the native engine stalling bug and properly disables the engine when fuel runs out. * Added an export for repair scripts to properly clear wheel and deformation damage after full repairs. * RepairVehicleDamage export resets synced damage data to prevent detached wheels from reappearing. * Integration instructions for popular mechanic scripts like JG Mechanic are included in the documentation. ## Files Affected * client/\* * server/unlocked/main.lua * shared/config.lua * shared/unlocked/config.lua * shared/unlocked/presets.lua * AGENTS.md * README.md * fxmanifest.lua

2026-05-30 01:29 CET

Changelog - Version 2.0.0 ## Changes * Added a wheel loss system: wheels can detach on hard landings and impacts, with integrity checked per wheel. * Fixed vehicle damage multiplier stacking that could cause excessive damage after reloading or exiting vehicles. Damage multipliers (including weapon damage) are now properly saved and restored, resetting correctly on vehicle entry. * Improved deformation handling to prevent deformity from progressively accumulating after repairs and made deformation calculations more reliable by caching target data. * Realistic presets now restrict airborne tilting, preventing vehicles from flipping unrealistically in the air. * Added a wheel scanner item for checking wheel integrity, with inventory definitions and images for ox_inventory and qb-core. * Added full locale support for 16 languages (ar, cs, de, en, es, fr, it, ja, nl, pl, pt, ro, sv, th, tr, zh). * The resource now requires the zyke_lib dependency. Ensure it is installed for the resource to function. * Added server exports GetVehicleDamageData and SetVehicleDamageData, enabling frameworks to persist vehicle damage data. Integration instructions for ESX, QBCore and Qbox are provided in the README. ## Files Affected * client/\* * server/main.lua * shared/config.lua * shared/presets.lua * README.md * extras/items/images/wheel\_scanner.png * extras/items/ox\_inventory.lua * extras/items/qb-core.lua * fxmanifest.lua
Changelog - Version 1.1.2 ## Changes * Double-check type mismatch that can be caused when switching deformation scripts. ## Files Affected * client/deformation.lua * fxmanifest.lua
Changelog - Version 1.1.1 ## Changes * Slower intervals for checking if your vehicle is flipped. * Refactored the process to ensure the vehicle isn't being reset when you enter it & it's almost destroyed. * Added a debug hud for the vehicle health. * Limit debug prints. * Adjusted some defaults for the presets to make vehicles last longer on average. * Replaced the frame-loop native to set the vehicle torque to simulate the vehicle dying with editing the entities' handling data for better performance. ## Files Affected * Replace all
Changelog - Version 1.1.0 ## Changes * Renamed the script from zyke\_vehdeformation to zyke\_realisticvehicles. * Added damage multipliers to engine, body & petrol tank. ## Files Affected * Replace all
Changelog - Version 1.0.0 Initial release
### Vending Machines Canonical URL: https://docs.zykeresources.com/free-resources/vending-machines Markdown URL: https://docs.zykeresources.com/free-resources/vending-machines.md # Vending Machines ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/vending-machines/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/vending-machines/resource-description.md # Resource Description ## Links * [Download](https://github.com/ZykeWasTaken/zyke_vending) ## Information A refurbished and very simplistic in-game interaction for acquiring items from vending machine with smooth animations & prop interactions. This resource was meant to be included inside of our upcoming zyke\_consuambles, but was made into it's own resource as I believe others may be interested in it. ### Config Canonical URL: https://docs.zykeresources.com/free-resources/vending-machines/config Markdown URL: https://docs.zykeresources.com/free-resources/vending-machines/config.md # Config ### Settings > Groups the main configuration options for this resource. The child sections below document each nested setting. #### props > Defines a keyed collection of `props` entries. The child sections below document the fields available for each entry.\ > \ > **Example:** > > ```lua > props = { > ["default"] = { > model = "prop_ld_flow_bottle", > offset = vector3(0.123, -0.039, 0.033), > rotation = vector3(-103.202, -68.066, 2.815), > bone = 18905, > }, > ... > } > ``` #### props\[x].model > Model name spawned for this prop template before it is attached to the player during the vending purchase animation.\ > \ > **Example:** > > ```lua > model = "prop_ld_flow_bottle" > ``` #### props\[x].offset > Attachment offset for this prop template. The `vector3` value is passed into the prop attachment step as the X, Y, and Z offset.\ > \ > **Example:** > > ```lua > offset = vector3(0.123, -0.039, 0.033) > ``` #### props\[x].rotation > Attachment rotation for this prop template. The `vector3` value is passed into the prop attachment step as the X, Y, and Z rotation.\ > \ > **Example:** > > ```lua > rotation = vector3(-103.202, -68.066, 2.815) > ``` #### props\[x].bone > Ped bone ID used when attaching this prop template to the player during the vending purchase animation.\ > \ > **Example:** > > ```lua > bone = 18905 > ``` #### machines > Defines a keyed collection of `machines` entries. The child sections below document the fields available for each entry.\ > \ > **Example:** > > ```lua > machines = { > [`ch_chint10_vending_smallroom_01`] = { > interactOffset = vector3(0.0, -0.97, 0.05), > items = { > {name = "sprunk", prop = "sprunk", price = 2}, > {name = "ecola", prop = "ecola", price = 2}, > {name = "orango_tang", prop = "orango_tang", price = 2}, > {name = "junk", prop = "junk", price = 2} > } > }, > ... > } > ``` #### machines\[x].interactOffset > Offset from the vending machine entity used to calculate where the player should stand for the purchase animation.\ > \ > **Example:** > > ```lua > interactOffset = vector3(0.0, -0.97, 0.05) > ``` #### machines\[x].items > Defines a list of `items` entries. The child sections below document the fields available for each entry.\ > \ > **Example:** > > ```lua > items = { > {name = "sprunk", prop = "sprunk", price = 2}, > ... > } > ``` #### machines\[x].items\[x].name > Inventory item name sold by this vending machine option.\ > \ > **Example:** > > ```lua > name = "sprunk" > ``` #### machines\[x].items\[x].prop > Prop template key from `props` used to display the purchased item during the vending animation.\ > \ > **Example:** > > ```lua > prop = "sprunk" > ``` #### machines\[x].items\[x].price > Cash price removed from the player when this vending machine item is purchased.\ > \ > **Example:** > > ```lua > price = 2 > ``` ### Dependencies Canonical URL: https://docs.zykeresources.com/free-resources/vending-machines/dependencies Markdown URL: https://docs.zykeresources.com/free-resources/vending-machines/dependencies.md # Dependencies ### Click the names to be redirected * [zyke\_lib](https://github.com/ZykeWasTaken/zyke_lib) ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/vending-machines/changelog Markdown URL: https://docs.zykeresources.com/free-resources/vending-machines/changelog.md # Changelog
Changelog - Version 1.0.3 ## Changes * Reverted early check that would infinitely lock the loader. ## Files Affected * client/main.lua * server/main.lua * fxmanifest.lua
Changelog - Version 1.0.2 ## Changes * Moved to the new zyke\_lib loader. * Some misc fixes like formatting. ## Files Affected * client/main.lua * server/main.lua * extras/items/qs-inventory.lua * .luarc.json * fxmanifest.lua
Changelog - Version 1.0.1 ## Changes * Added documentation link. * Removing from auth list if character logs out. ## Files Affected * server/main.lua * README.md * fxmanifest.lua
Changelog - Version 1.0.0 Official release.
### Sounds Canonical URL: https://docs.zykeresources.com/free-resources/sounds Markdown URL: https://docs.zykeresources.com/free-resources/sounds.md # Sounds ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/sounds/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/sounds/resource-description.md # Resource Description ## Links * [Download](https://github.com/ZykeWasTaken/zyke_sounds) ## Information This is a work-in-progress resource that I created to bring zyke\_smoking to life. When adding sounds to my resource I noticed several issues such as volume based on distance to the audio source, 0.5-1s delays and whatnot in popular alternatives. This resource solves that, allowing me to develop more immersive resources. ### Config Canonical URL: https://docs.zykeresources.com/free-resources/sounds/config Markdown URL: https://docs.zykeresources.com/free-resources/sounds/config.md # Config ### Settings > Times are in milliseconds. 1000ms = 1 second. Master settings table controlling sound system behavior and performance. #### debug > Shows debug markers for active sound positions and logs loaded sound files when enabled.\ > \ > **Example:** > > ```lua > debug = false > ``` #### volumeUpdateInterval > Controls how frequently clients update active sound volume by distance. Lower values make volume changes smoother, while higher values reduce update cost. Changing this value too much can drastically affect performance, so only adjust it if you understand the implications.\ > \ > **Example:** > > ```lua > volumeUpdateInterval = 100 > ``` #### commandName > The chat command that players type to open the sound volume configuration menu.\ > \ > **Example:** > > ```lua > commandName = "sounds" > ``` #### kvpKey > The key used to store per-sound volume multipliers in the client's persistent key-value storage. This value is read on resource start to restore saved volume settings and written whenever volumes are updated. Change this key only if you want to reset all saved volume multipliers for every player.\ > \ > **Example:** > > ```lua > kvpKey = "zyke_sounds:volumeMultiplier" > ``` #### routingBucketUpdateInterval > Controls how frequently the server checks whether players have moved to a different routing bucket for location-based sounds. This setting is intended for advanced users who understand the implications of modifying it.\ > \ > **Example:** > > ```lua > routingBucketUpdateInterval = 1000 > ``` #### unknownSoundDurationMs > The fallback duration in milliseconds used for sounds whose actual audio length has not yet been determined. This value is applied as a temporary placeholder until the correct duration is available.\ > \ > **Example:** > > ```lua > unknownSoundDurationMs = 300000 > ``` #### maxCachedSoundDurationMs > The maximum sound duration in milliseconds that the server will trust and cache from a client report. The server ignores any client-reported sound duration longer than this value. The default is 600000 ms (10 minutes). The comment advises not changing this value unless you need to play sounds longer than 10 minutes.\ > \ > **Example:** > > ```lua > maxCachedSoundDurationMs = 600000 > ``` #### soundDurationToleranceMs > Defines the tolerance in milliseconds for sound duration reports from clients. When a client reports a sound file's duration, the server compares it against any previously cached duration for that sound. If the difference between the new report and the cached value exceeds this tolerance, the new report is discarded as invalid. This prevents incorrect duration data from being cached.\ > \ > **Example:** > > ```lua > soundDurationToleranceMs = 500 > ``` #### soundCullingUpdateInterval > Controls how frequently the server checks whether players have moved into or out of range of active location sounds.\ > \ > **Example:** > > ```lua > soundCullingUpdateInterval = 1000 > ``` #### stateBagEntityStaleMs > Controls how long muted entity sounds continue playing after the associated entity or player leaves the local client's scope. If the entity remains out of scope for longer than this duration, the sound is stopped. The value is in milliseconds.\ > \ > **Example:** > > ```lua > stateBagEntityStaleMs = 2500 > ``` #### stateBagStopTtlMs > Controls how long stop payloads remain in state bags after a sound stops. This allows scoped clients that join late to still receive fade-out or force-full stop data.\ > \ > **Example:** > > ```lua > stateBagStopTtlMs = 2000 > ``` #### stateBagEmitSlots > Controls how many temporary sync slots are available per entity for quick entity sounds. Each player entity gets its own pool of slots, so multiple players contributing sounds do not share the same pool.\ > \ > **Example:** > > ```lua > stateBagEmitSlots = 4 > ``` #### oneShotStateBagTtlMs > Controls how long one-shot entity sound synchronization data remains available in state bags before being cleaned up. Higher values can help slower clients receive the data, but also keep stale data in memory longer.\ > \ > **Example:** > > ```lua > oneShotStateBagTtlMs = 10000 > ``` ### Exports & Events Canonical URL: https://docs.zykeresources.com/free-resources/sounds/exports-and-events Markdown URL: https://docs.zykeresources.com/free-resources/sounds/exports-and-events.md # Exports & Events ## Server Sided Exports ### Play Sound On Entity > This export will play a sound on an entity, and regulate the volume based on your distance from it. It is dynamic and keeps following the entity.\ > \ > **Example:** > > ```lua > ---@param entity integer > ---@param id? string @Only needed if you want to manually stop the sound > ---@param soundName string | string[] @Sound name, or list of them, will choose randomly from list every time PlaySound(JS) executes > ---@param maxVolume number @0.0-1.0, the max volume for the sound, usually ~0.2 > ---@param maxDistance number @0.0-x, the max distance to hear your sound, usually ~2.0 > ---@param looped boolean | number | {[1]: number, [2]: number} @Basic looping, loop with time between, loop with random time between > ---@param playCount? integer @If not looping, you can decide how many times the audio will play > ---@return string @Sound id > exports["zyke_sounds"]:PlaySoundOnEntity(entity, id, soundName, maxVolume, maxDistance, looped, playCount) > ``` ### Stop Sound > Manually stop a sound playing. Allows you to fade it out or keep playing it until it ends. We do un-register the audio when fading or forcing the full to be played, so the same id can be re-used.\ > \ > **Example:** > > ```lua > ---@param soundId string > ---@param fade? number @In milliseconds, how long to fade the sound out for to avoid abrupt interruption > ---@param forceFull? boolean @Force the audio to play out fully instead of cutting off, ignores fade > exports["zyke_sounds"]:StopSound(soundId, fade, forceFull) > ``` ### Does File Exist > Verify the existence of the sound file in zyke\_sounds. This is more expensive than DoesSoundExist since we are fetching the actual file instead of a quick table lookup.\ > \ > **Example:** > > ```lua > ---@param fileName string > ---@return boolean > exports["zyke_sounds"]:DoesFileExist(fileName) > ``` ### Does Sound Exist > Lightweight export to quickly validate if a sound has been loaded into memory on script start.\ > \ > **Example:** > > ```lua > ---@param fileName string > ---@return boolean > exports["zyke_sounds"]:DoesSoundExist(fileName) > ``` ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/sounds/changelog Markdown URL: https://docs.zykeresources.com/free-resources/sounds/changelog.md # Changelog
Changelog - Version 0.5.0 ## Changes * Overhauled sound synchronization to improve reliability and consistency across all players. * Server-side caching ensures sounds are reliable long-term, expanding the capabilities of this resource past simple one-offs that run for a few second. * Utilizing statebags for entities, sounds are now scoped better and are more reliable. * Added Lithuanian language support. ## Files Affected * Replace all.

2026-05-07 02:12 CET

Changelog - Version 0.4.0 ## Changes * Added a sounds menu for players to individually change the volume with a multiplier. Primarily to let people disable certain sounds they despise hearing, like eating sounds. ## Files Affected * Replace all.
Changelog - Version 0.1.0 Pre-release.
### Key Minigame Canonical URL: https://docs.zykeresources.com/free-resources/key-minigame Markdown URL: https://docs.zykeresources.com/free-resources/key-minigame.md # Key Minigame ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/key-minigame/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/key-minigame/resource-description.md # Resource Description ## Links * [Download](https://github.com/ZykeWasTaken/zyke_keyminigame) ## Information A non/semi-intrusive & lightweight minigame for matching keys. This was created in the spirits of needing a minigame that does not automatically limit gameplay & requires a focus toggle, along with wanting something fresh. This resource hasn't had a proper release, but can expand based on suggested features. It was just a smaller minigame that was for zyke\_consumables, made into it's separate project for others to use. ### Exports & Events Canonical URL: https://docs.zykeresources.com/free-resources/key-minigame/exports-and-events Markdown URL: https://docs.zykeresources.com/free-resources/key-minigame/exports-and-events.md # Exports & Events ## Client Sided Exports ### Start Minigame > Simply starts a minigame for the client executing it. Default time limit will be 10 if nothing is provided. Will throw an error if started when a minigame is already in progress.\ > \ > **Example:** > > ```lua > ---@param keys string[] @Any keyboard keys except TAB & ESCAPE > ---@param randomizeKeys? integer @If a number, the `keys` param is sample size for randomization, and this is the amount > ---@param timeLimit? integer @In seconds, time to complete the minigame otherwise you fail > ---@return boolean, "success" | "fail" | "cancel" > exports["zyke_keyminigame"]:Start(keys, randomizeKeys, timeLimit) > ``` ### Start Non-Intrusive Minigame > Starts a similar minigame to our standard export, but without any UI focusing. The minigame spawns at the top of your screen and only accepts arrow key inputs. This approach allows decent variety forcing you to really pay attention without freezing your game rendering you unable to walk.\ > \ > In situations where the player still needs to be able to walk/drive, use this.\ > \ > **Example:** > > ```lua > ---@param keyCount integer @The amount of keys to press > ---@param timeLimit? integer @In seconds, time to complete the minigame otherwise you fail > ---@return boolean, "success" | "fail" | "cancel" > exports["zyke_keyminigame"]:StartNonIntrusive(keyCount, timeLimit) > ``` ### Stop Minigame > Stops the ongoing minigame.\ > \ > **Example:** > > ```lua > exports["zyke_keyminigame"]:Stop() > ``` ### Is Active > Returns if there's an active minigame.\ > \ > **Example:** > > ```lua > ---@return boolean > exports["zyke_keyminigame"]:IsActive() > ``` ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/key-minigame/changelog Markdown URL: https://docs.zykeresources.com/free-resources/key-minigame/changelog.md # Changelog
Changelog - Version 1.1.1 ## Changes * Moved to the new zyke\_lib loader. ## Files Affected * client.lua * nui/\* * fxmanifest.lua
Changelog - Version 1.1.0 ## Changes * Added a non-intrusive alternative to allow movement when you are still participating in the minigame. Uses arrows for all inputs & no focusing. ## Files Affected * client.lua * nui\_source/src/App.tsx * nui\_source/src/components/KeyDisplay.tsx * nui\_source/src/components/Modal.tsx * nui\_source/src/components/NonIntrusiveText.tsx * nui\_source/src/components/PressKeys.tsx * nui\_source/src/components/TranslateArrowKey.tsx * nui/\* * fxmanifest.lua
Changelog - Version 1.0.0 Official release.
### Stabwheels Canonical URL: https://docs.zykeresources.com/free-resources/stabwheels Markdown URL: https://docs.zykeresources.com/free-resources/stabwheels.md # Stabwheels ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/stabwheels/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/stabwheels/resource-description.md # Resource Description ## Links * [Download](https://github.com/ZykeWasTaken/zyke_stabwheels) * [Showcase](https://youtu.be/lRR8RcyFLWw) ## Features * Stab wheels to burst them. * High performance. * Future integration for my gang script. * Completely free and open source. * Uses zyke\_lib for framework or custom functions, my public repository, meaning custom inventories, progressbars, notifications etc won't be a problem as they can all easily be changed once, and work for all my resources. ### Dependencies Canonical URL: https://docs.zykeresources.com/free-resources/stabwheels/dependencies Markdown URL: https://docs.zykeresources.com/free-resources/stabwheels/dependencies.md # Dependencies #### Click the names to be redirected * [zyke\_lib](https://github.com/ZykeWasTaken/zyke_lib) ([QBCore](https://github.com/qbcore-framework)/[ESX](https://github.com/esx-framework)) _Please note that this resource uses minimal framework dependencies and can easily be swapped out to be ran standalone_ ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/stabwheels/changelog Markdown URL: https://docs.zykeresources.com/free-resources/stabwheels/changelog.md # Changelog
Changelog - Version 1.0.4 ## Changes * Moved to the new zyke\_lib loader. ## Files Affected * fxmanifest.lua
Changelog - Version 1.0.3 ## Changes * Moved to zyke\_lib v2. ## Files Affected * All
Changelog - Version 1.0.2 ### Changes * Added future objective support for zyke\_gangs once it releases. ### Files affected * fxmanifest.lua (Version) * client/main.lua * shared/config.lua
Changelog - Version 1.0.1 ### Changes * The wheel you stabbed will now deflate instead of bursting instantly, same effect as if you would shoot the wheel. ### Files affected * fxmanifest.lua (Version) * client/main.lua
Changelog - Version 1.0.0 Official release for ESX and QBCore.
### Burncars Canonical URL: https://docs.zykeresources.com/free-resources/burncars Markdown URL: https://docs.zykeresources.com/free-resources/burncars.md # Burncars ### Resource Description Canonical URL: https://docs.zykeresources.com/free-resources/burncars/resource-description Markdown URL: https://docs.zykeresources.com/free-resources/burncars/resource-description.md # Resource Description ## Links * [Download](https://github.com/ZykeWasTaken/zyke_burncars) * [Showcase](https://youtu.be/897XqCYc6ZI) ## Features * Burn vehicles. * Blacklist singular vehicles or entire vehicle classes. * Requires items. * Configurable requirements such vehicle being empty. * Quality made with performance and security in mind. * Future integration for my gang script. * Completely free and open source. ### Dependencies Canonical URL: https://docs.zykeresources.com/free-resources/burncars/dependencies Markdown URL: https://docs.zykeresources.com/free-resources/burncars/dependencies.md # Dependencies #### Click the names to be redirected * [zyke\_lib](https://github.com/ZykeWasTaken/zyke_lib) ([QBCore](https://github.com/qbcore-framework)/[ESX](https://github.com/esx-framework)) ### Changelog Canonical URL: https://docs.zykeresources.com/free-resources/burncars/changelog Markdown URL: https://docs.zykeresources.com/free-resources/burncars/changelog.md # Changelog
Changelog - Version 1.0.2 ## Changes * Moved to the new zyke\_lib loader. ## Files Affected * fxmanifest.lua
Changelog - Version 1.0.1 ## Changes * Moved to zyke\_lib v2. ## Files Affected * All
Changelog - Version 1.0.0 Official release for ESX and QBCore.