Skip to content

Commit fe3847d

Browse files
committed
Add json support
1 parent a437265 commit fe3847d

26 files changed

+14721
-1928
lines changed

client/editor.lua

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
RegisterNUICallback('saveConfig', function(data, cb)
2+
local file = data.file
3+
local configData = data.data
4+
TriggerServerEvent('qb-core:server:configEditor', file, configData)
5+
print('Saving config for file:', file)
6+
cb('ok')
7+
end)
8+
9+
RegisterNUICallback('closeEditor', function(data, cb)
10+
SetNuiFocus(false, false)
11+
cb('ok')
12+
end)
13+
14+
RegisterNetEvent('qb-core:client:configEditor', function(allData)
15+
SendNUIMessage({
16+
action = 'populateData',
17+
data = allData
18+
})
19+
SetNuiFocus(true, true)
20+
end)

client/main.lua

-50
This file was deleted.

config.lua

-157
This file was deleted.

fxmanifest.lua

+11-14
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,18 @@ game 'gta5'
33
lua54 'yes'
44
author 'Kakarot'
55
description 'Core resource for the framework, contains all the core functionality and features'
6-
version '1.3.0'
6+
version '2.0.0'
77

88
shared_scripts {
9-
'config.lua',
109
'shared/locale.lua',
1110
'locale/en.lua',
1211
'locale/*.lua',
13-
'shared/main.lua',
14-
'shared/items.lua',
15-
'shared/jobs.lua',
16-
'shared/vehicles.lua',
17-
'shared/gangs.lua',
18-
'shared/weapons.lua',
19-
'shared/locations.lua'
12+
'shared/core.lua',
13+
'shared/loader.lua',
14+
'shared/main.lua'
2015
}
2116

2217
client_scripts {
23-
'client/main.lua',
2418
'client/functions.lua',
2519
'client/loops.lua',
2620
'client/events.lua',
@@ -29,7 +23,6 @@ client_scripts {
2923

3024
server_scripts {
3125
'@oxmysql/lib/MySQL.lua',
32-
'server/main.lua',
3326
'server/functions.lua',
3427
'server/player.lua',
3528
'server/events.lua',
@@ -42,9 +35,13 @@ ui_page 'html/index.html'
4235

4336
files {
4437
'html/index.html',
45-
'html/css/style.css',
46-
'html/css/drawtext.css',
47-
'html/js/*.js'
38+
'html/css/*.css',
39+
'html/js/*.js',
40+
'shared/jobs.json',
41+
'shared/gangs.json',
42+
'shared/items.json',
43+
'shared/vehicles.json',
44+
'shared/weapons.json'
4845
}
4946

5047
dependency 'oxmysql'

0 commit comments

Comments
 (0)