https://github.com/adrianrguez96/dcore-fivem-roleplay-framework
Custom-built FiveM roleplay framework with unique features and optimized performance
https://github.com/adrianrguez96/dcore-fivem-roleplay-framework
fivem framework gta5 lua roleplay
Last synced: about 1 year ago
JSON representation
Custom-built FiveM roleplay framework with unique features and optimized performance
- Host: GitHub
- URL: https://github.com/adrianrguez96/dcore-fivem-roleplay-framework
- Owner: Adrianrguez96
- License: mit
- Created: 2024-08-24T16:26:07.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-08-24T16:51:01.000Z (almost 2 years ago)
- Last Synced: 2025-01-29T12:23:03.662Z (over 1 year ago)
- Topics: fivem, framework, gta5, lua, roleplay
- Language: Lua
- Homepage:
- Size: 2.95 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# D-Core Framework
D-Core Framework is a foundational core designed to help you create and manage your own roleplay server on FiveM. Built with an object-oriented programming (OOP) approach in Lua, D-Core utilizes modern web technologies such as HTML5, CSS3, jQuery, and ES6 JavaScript for its NUI (New User Interface).
## Features
- Object-Oriented Programming: D-Core leverages Lua's OOP capabilities, allowing for clean, modular, and maintainable code.
- Modern Web Technologies: The NUI components are built using HTML5, CSS3, jQuery, and JavaScript (ES6), ensuring a responsive and dynamic user interface.
- Flexible Integration: Easily integrate D-Core with other resources or modify existing scripts like ESX or Qbus to work seamlessly with D-Core.
# Using Core Functions in Other Resources
D-Core's core functions can be integrated into other resources or modified scripts to enhance your server's capabilities. Below are the basic declarations needed to start using D-Core in your client and server scripts.
## Client-Side Declaration
To use D-Core functions on the client side, add the following code at the beginning of your script. It's recommended to create a separate file, core.lua, where you can manage this part of your script logic.
```
Core = Core or {}
Citizen.CreateThread(function()
while true do
TriggerEvent("core:client:GetFramework", function(core) Core = core end)
if Core.Status then
-- Here the controllers are started and the main functions of each of them are called
break
end
Wait(0)
end
end)
```
## Server-Side Declaration
Similarly, to use D-Core functions on the server side, include the following code:
```
Core = Core or {}
Citizen.CreateThread(function()
while true do
TriggerEvent("core:server:GetFramework", function(core) Core = core end)
if Core.Status then
-- Here the controllers are started and the main functions of each of them are called
break
end
Wait(0)
end
```
# Important Note
This is an alpha version of the framework, which means it may contain bugs or incomplete features. Your feedback and contributions are welcome as the framework continues to evolve.
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.