Commit Graph
810 Commits
Author SHA1 Message Date
Mustache Dom b96a64f371 feature Prints now auto formats json to go downwards in prints so its easier to read
`useCase`


```lua
Prints.Debug('GTA', 5, {is = true, cool = true})
```
2025-09-29 01:31:46 -07:00
MrNewb d7c58b6bf4 Merge pull request #159 from ONyambura/dev
FIX - QB-Core - Framework/Inventory - Item properties fix
2025-09-26 14:27:47 -04:00
ONyambura a4959882b3 FIX - QB-Core - Framework/Inventory - Item properties fix
QB-Core Framework.
Some inventories has item property `count` instead of `amount`.
+/- Added fallback to `count` if `amount` doesn't exists.
2025-09-26 19:02:30 +03:00
Mr.Crowley c985261cf3 Fix SetEntityCoords last arg to false in UpdateEntity
Changed the last argument of SetEntityCoords from true to false in the UpdateEntity function to adjust entity movement behavior.
2025-09-18 23:47:03 -05:00
MrNewb 582ce9e640 Refactor item info retrieval in inventory modules
Updated Inventory.GetItemInfo to use the full items table for lookups instead of fetching individual items. Added Inventory.Items function to both client and server for consistent access to the items table. Improved handling of missing data and streamlined code for better maintainability.
2025-09-13 18:04:05 -04:00
MrNewb 41c90f9082 Add wasabi_mdt dispatch integration
Introduces client and server modules for dispatch integration with the wasabi_mdt resource. Provides functions to send alerts and retrieve the resource name, enabling compatibility with the wasabi_mdt dispatch system.
2025-09-11 17:34:54 -04:00
MrNewb 3dfbaa8573 Localize target menu and interaction prompts
Replaced hardcoded target menu titles, descriptions, and interaction prompts with localized strings from en.json. Updated client.lua to use Language.Locale for menu and help text, improving internationalization and consistency.
2025-09-10 21:47:58 -04:00
MrNewb a15a79603b **HOTFIX** 0.12.1 2025-09-10 18:53:33 -04:00
MrNewb 5e321867e6 Merge pull request #157 from TheOrderFivem/crowleys-branch
Add deprecated args field to Point.Register

**HOTFIX**
2025-09-10 18:53:05 -04:00
Mr.Crowley 8215a16c27 Add deprecated args field to Point.Register
Introduces a self.args field to the Point.Register function, marked as deprecated for future removal 2025-09-10. This change preserves compatibility for code relying on the args property.
2025-09-10 17:43:18 -05:00
MrNewb bc3558c622 Merge pull request #156 from TheOrderFivem/dev
Release v0.12.0 - Major Framework Enhancements and Entity System Overhaul
2025-09-10 13:46:59 -04:00
MrNewb 8bf18220a1 Merge pull request #155 from TheOrderFivem/crowleys-branch
Crowleys branch
2025-09-10 13:39:36 -04:00
MrNewb 96d311c4d3 Bump version to 0.12.0 in fxmanifest.lua
Updated the resource version from 0.11.2 to 0.12.0 to reflect new changes or improvements in the community_bridge project.
2025-09-10 13:23:02 -04:00
MrNewb d669f7ba16 Remove debug print from UpdateEntity event
Eliminated unnecessary json-encoded print statement from the UpdateEntity event handler to clean up console output.
2025-09-10 12:42:19 -04:00
MrNewb 3531349971 Merge pull request #153 from TheOrderFivem/GetResourceName
Add GetResourceName function to all modules
2025-09-10 12:31:39 -04:00
MrNewb 90c65dc55e Add GetResourceName function to all modules
Introduces a standardized GetResourceName function to banking, clothing, dispatch, doorlock, framework, fuel, helptext, housing, and other modules. This function returns the name of the in-use resource, improving resource identification and interoperability across the codebase.
2025-09-10 12:27:12 -04:00
Mr.Crowley e7de2972fd Add client/server entity examples and improve 3D help text
Added new example scripts for client and server entity creation, demonstrating features like clothing, particles, scenarios, and targets. Enhanced Utility.Draw3DHelpText to support multi-line text and improved background rendering for better readability.
2025-09-10 10:45:10 -05:00
MrNewb cd16291038 Merge pull request #152 from TheOrderFivem/hunger/thirst
Hunger/thirst
2025-09-10 11:38:04 -04:00
MrNewb f4e5d9485f Refactor hunger and thirst retrieval methods
Simplified Framework.GetHunger and Framework.GetThirst functions in both qb-core and qbx_core by using Framework.GetPlayerMetaData instead of accessing player data directly. This improves code readability and consistency.
2025-09-10 11:29:42 -04:00
MrNewb 08c3d937d6 Round hunger and thirst values to nearest integer
Updated GetHunger and GetThirst functions to return rounded integer values using math.floor(value + 0.5) for consistency and to avoid floating point results.
2025-09-10 11:29:42 -04:00
MrNewb 8bf02f6372 Fix hunger and thirst status retrieval
Changed Framework.GetHunger and Framework.GetThirst to fetch the 'status' instead of 'hunger' or 'thirst' directly. This ensures the functions correctly iterate over the status table to find the relevant values.
2025-09-10 11:29:42 -04:00
MrNewb aae3d540ff Update server.lua 2025-09-10 11:29:42 -04:00
MrNewb 943f86d47b Add nil check for player data in GetStatusData
Prevents errors by returning 0 if player data is unavailable when calling Framework.GetStatusData.
2025-09-10 11:29:42 -04:00
MrNewb cfd746d889 Refactor hunger and thirst retrieval logic
Introduced Framework.GetStatusData to centralize status lookup. Updated GetHunger and GetThirst to use the new function, improving code reuse and maintainability.
2025-09-10 11:29:41 -04:00
MrNewb 87345fafce Add GetHunger and GetThirst functions to frameworks
Introduced GetHunger and GetThirst functions to client and server files for es_extended, qb-core, and qbx_core frameworks. These functions return the player's hunger and thirst values rounded to the nearest integer, improving consistency in status retrieval.
2025-09-10 11:29:41 -04:00
MrNewb 371ee19445 Merge pull request #151 from TheOrderFivem/vehicle-module
Vehicle module
2025-09-10 11:15:06 -04:00
MrNewb f472232273 Add vehicle properties system and update attributions
Introduces a comprehensive vehicle properties handler in lib/vehicles/client.lua, inspired by ESX, QB-Core, and ox_lib frameworks. Updates Attributions.md to document the new vehicle system, clarify licensing, and improve formatting. Registers Vehicles in lib/init.lua for client use.
2025-09-10 11:07:58 -04:00
MrNewb 66df77cc3f fix manifest warning 2025-09-10 10:42:15 -04:00
MrNewb 9fb5927a57 Merge pull request #150 from StrixLuca/patch-1
Update README.md
2025-09-07 09:00:34 -04:00
MrNewb de0f7b9492 Update Community Bridge Documentation link 2025-09-07 08:59:24 -04:00
StrixLuca 46574bef95 Update README.md 2025-09-06 09:30:01 +01:00
MrNewb 5b7e7bb06e Merge pull request #149 from TheOrderFivem/crowleys-branch
Crowleys branch
2025-09-04 22:32:41 -04:00
Mr.Crowley 18748bd775 Refactor entity movement and add Math.Nearest function
Simplifies entity movement logic in client_entity.lua by improving coordinate comparison and updating behavior triggers. Adds a new Math.Nearest function in math.lua to round values to the nearest whole number.
2025-09-04 11:42:59 -05:00
Mr.Crowley debfb06231 Refactor stash and targets behavior logic
Simplifies stash target assignment by returning early when registering a stash, ensuring consistent target setup. Enhances target update logic to check for removed targets and removes debug print statement.
2025-09-04 08:21:48 -05:00
MrNewb 0186815079 Merge pull request #146 from solaire-fivem/fix-issue-with-the-GetHunger-and-GetThirst-server-sided-functions
Fix issue with GetThirst and GetHunger not working in ESX
2025-09-04 04:45:49 -04:00
Solaire 18ac3ce0ca Round the result 2025-09-03 22:58:17 +01:00
Mr.Crowley 7443695254 Improve entity spawning and target behaviors
Refactored client entity spawning to handle missing models and improved coordinate update sensitivity. Removed model assertion from server entity creation. Enhanced resource start event handling for both server and client. Updated stash and target behaviors to support additional properties and better zone handling for entities without spawned objects.
2025-09-03 08:57:39 -05:00
Mr.Crowley dff4622a94 Refactor entity behavior to use Bridge.Entity
Replaces all usage of Bridge.ClientEntity and Bridge.ServerEntity with Bridge.Entity across shared behavior modules. Updates initialization in lib/init.lua to use cLib.Entity and marks cLib.ClientEntity and cLib.ServerEntity as deprecated for consistency and future maintainability.
2025-09-03 04:06:31 -05:00
Mr.Crowley cb9dbdf610 Adjust entity movement threshold and follow behavior
Increased the movement threshold for entity updates from 0.05 to 1.0 to reduce unnecessary position updates. Modified follow behavior to offset the entity's coordinates by -1 on the Z axis when updating, possibly to account for ground level or animation adjustments.
2025-09-03 01:23:01 -05:00
Mr.Crowley dd08f058c3 Refactor client entity management functions
Added freeze position handling in UpdateEntity and ensured OnDestroy behavior is triggered on entity destruction. Removed unused and commented-out Update function, and improved code clarity in Set and Destroy methods.
2025-09-03 01:04:04 -05:00
Mr.Crowley 8346130b00 Add modular entity behaviors and update entity logic
Introduces modular behaviors for entities, including anim, attach, clothing, follow, particles, scenarios, shop, stash, targets, and weapon, each in their own files. Updates client_entity.lua and behaviors.lua to support dynamic behavior registration, initialization, and triggering. Refactors entity update logic to improve movement handling and behavior invocation.
2025-09-03 00:28:17 -05:00
MrNewb facffe26c5 Merge pull request #148 from TheOrderFivem/JobCounts
Job counts
2025-09-03 01:25:02 -04:00
MrNewb 209d257f1c Merge pull request #147 from TheOrderFivem/loggs
Loggs
2025-09-03 01:13:43 -04:00
MrNewb 9c61f7967d Update callback module import paths
Changed all references from 'lib/utility/shared/callbacks.lua' to 'lib/callback/shared/callback.lua' in client and server files for framework, inventory, and phone modules to reflect new file structure or module location.

Commit#f900bc5 did not adjust these, correcting.
2025-09-01 17:05:34 -04:00
solaire-fivem 71cd1e0676 Fix issue with GetThirst and GetHunger not working in ESX 2025-09-01 14:22:03 +01:00
MrNewb 63d2f675f6 Buffer and batch Discord log messages
Introduces a queue and timer to batch log messages before sending them to Discord, reducing the number of HTTP requests. Refactors the built-in log handler to use the new queuing system and improves code consistency. Looks gross but works.
2025-09-01 03:33:29 -04:00
MrNewb e9fa5a2891 Fix type annotation for job count function
Updated the type annotation for the 'tbl' parameter in Framework.GetJobCountTotal from 'any' to 'table' for improved clarity and correctness.
2025-09-01 02:31:14 -04:00
MrNewb 7f14eef82b Refactor logging system and centralize config
Reworked the logging system to use a unified handler approach supporting built-in, qb, ox_lib, and Fivemerr log systems. Deprecated Logs.Send and Logs.Notify in favor of Logs.CreateLog. Centralized all logging configuration options in serverConfig.lua for easier management and extensibility.
2025-09-01 02:29:15 -04:00
MrNewb 014dba1012 Add job count tracking to framework
Introduces job count tracking and retrieval functions to both client and server modules. The server now maintains and updates a global state of job counts, synchronizing changes to clients. Refactors job registration logic for accuracy and consistency, and adds utility functions for total job counts and player source retrieval.

This usage with the state may be a problem on initial start for highly populated servers as 200 players load in for example...
2025-08-31 22:49:31 -04:00
MrNewb 9fdb41e9f6 Add job count management on player events
Introduces event handlers to update job counts when players load, change jobs, or unload across multiple framework modules. Ensures job count tracking stays accurate by adding or removing counts based on player actions. (would like to update this to have some client event tables?)
2025-08-31 22:49:29 -04:00