mirror of
https://github.com/ND-Framework/ND_Core.git
synced 2026-08-17 05:56:01 +01:00
Compare commits
115 Commits
wip-2.0.0
...
d3278e9be1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d3278e9be1 | ||
|
|
24229485d9 | ||
|
|
4f9d274c62 | ||
|
|
73f38c12f6 | ||
|
|
0b39a8c039 | ||
|
|
568185ca19 | ||
|
|
bc41788cc9 | ||
|
|
8a3502e515 | ||
|
|
a431a49d8c | ||
|
|
0bd76ed79f | ||
|
|
3f20d0f918 | ||
|
|
31bf86a826 | ||
|
|
9bd42fb26e | ||
|
|
085bb71dcc | ||
|
|
35d8d887c8 | ||
|
|
544ad64779 | ||
|
|
43f690e356 | ||
|
|
e883c4e64f | ||
|
|
5928d89edf | ||
|
|
9b846dc07e | ||
|
|
baac4c75dd | ||
|
|
fb708cc7e7 | ||
|
|
1547d310eb | ||
|
|
9d4708f6d9 | ||
|
|
a7713804f0 | ||
|
|
a9785ce754 | ||
|
|
fe922e1b98 | ||
|
|
b97f42bb0a | ||
|
|
d132c12025 | ||
|
|
119b0034bf | ||
|
|
622b6fa8b0 | ||
|
|
2e6dfa9e5f | ||
|
|
4c4166de94 | ||
|
|
dea7ac6c8f | ||
|
|
120d924cae | ||
|
|
2a263a6c2e | ||
|
|
4ff4f487a1 | ||
|
|
e26821841b | ||
|
|
e9aafe1f2d | ||
|
|
6987bb63ae | ||
|
|
e0c4a8419b | ||
|
|
66f93bde14 | ||
|
|
2460df2f34 | ||
|
|
b79bb6ec7f | ||
|
|
eef1bb60f5 | ||
|
|
1320c4ab7d | ||
|
|
2c7aa5723a | ||
|
|
97a8b991ae | ||
|
|
2a3ac3b63b | ||
|
|
5d3c051149 | ||
|
|
fc82b217e9 | ||
|
|
284411ce66 | ||
|
|
a7257cf68f | ||
|
|
841a5771c5 | ||
|
|
8fd7878ba6 | ||
|
|
60e86d2038 | ||
|
|
626f0ad06f | ||
|
|
d5c3acbd81 | ||
|
|
98cba87bec | ||
|
|
001fc22ef6 | ||
|
|
87420e99e9 | ||
|
|
c5597161d9 | ||
|
|
898b9aefe9 | ||
|
|
5545650dd5 | ||
|
|
f4f01a5b1c | ||
|
|
3252118f93 | ||
|
|
9d4708a1f8 | ||
|
|
d0d04ae282 | ||
|
|
c005c1b28b | ||
|
|
590044b5d6 | ||
|
|
3146172c0c | ||
|
|
2ce47ef8d1 | ||
|
|
6258651d8b | ||
|
|
eecbc8f690 | ||
|
|
1d25b54e0f | ||
|
|
e18389a52a | ||
|
|
539e522373 | ||
|
|
2bacdd2a20 | ||
|
|
6242a44c0b | ||
|
|
74e4ccc2de | ||
|
|
2fda7655b5 | ||
|
|
ade82436a5 | ||
|
|
f512d0ed0c | ||
|
|
0a19fe8a33 | ||
|
|
2882c7c1ae | ||
|
|
6291690bd4 | ||
|
|
af82c447c1 | ||
|
|
46f4bdbd64 | ||
|
|
4870d639d4 | ||
|
|
ed895b4e6d | ||
|
|
5d2925d0c3 | ||
|
|
0500cef32f | ||
|
|
0e1fb43cd2 | ||
|
|
3260aa01f2 | ||
|
|
71a54be704 | ||
|
|
d939607d64 | ||
|
|
5cb038819c | ||
|
|
9f5bb34bdd | ||
|
|
29006870c3 | ||
|
|
a60e1b9e32 | ||
|
|
7fe7901a13 | ||
|
|
ca8f4369f6 | ||
|
|
e1d4b2fcff | ||
|
|
8b0f2b010d | ||
|
|
24e8874050 | ||
|
|
289d040b5c | ||
|
|
3f0c47c2d0 | ||
|
|
543b23a644 | ||
|
|
4b106d3688 | ||
|
|
db5c54f2d8 | ||
|
|
a1150bb821 | ||
|
|
8f7c52130a | ||
|
|
6e71142970 | ||
|
|
d9df135abb | ||
|
|
72fb153cfc |
16
README.md
16
README.md
@@ -16,9 +16,13 @@
|
||||
* [oxmysql](https://github.com/overextended/oxmysql/releases)
|
||||
* [ox_lib](https://github.com/overextended/ox_lib/releases)
|
||||
|
||||
## v2 Addons
|
||||
* [Character selection](https://github.com/ND-Framework/ND_Characters/tree/wip-v2)
|
||||
* [Banking](https://github.com/ND-Framework/ND_Banking/tree/wip-v2)
|
||||
* [Appearance shops](https://github.com/ND-Framework/ND_AppearanceShops/tree/wip-v2)
|
||||
* [Dealership](https://github.com/ND-Framework/ND_Dealership/tree/v2)
|
||||
* [Inventory](https://github.com/overextended/ox_inventory/pull/1403)
|
||||
## Addons
|
||||
* [Character selection](https://github.com/ND-Framework/ND_Characters/releases)
|
||||
* [Banking](https://github.com/ND-Framework/ND_Banking/releases)
|
||||
* [Appearance shops](https://github.com/ND-Framework/ND_AppearanceShops/releases)
|
||||
* [Dealership](https://github.com/ND-Framework/ND_Dealership/releases)
|
||||
* [Inventory](https://github.com/overextended/ox_inventory/releases)
|
||||
* [Ambulance job](https://github.com/ND-Framework/ND_Ambulance/releases)
|
||||
* [Casino](https://github.com/ND-Framework/ND_Casino/releases)
|
||||
* [Blackjack](https://github.com/ND-Framework/ND_Blackjack/releases)
|
||||
* [Nitro](https://github.com/ND-Framework/ND_Nitro/releases)
|
||||
|
||||
@@ -29,14 +29,13 @@ AddEventHandler("gameEventTriggered", function(name, args)
|
||||
local victim = args[1]
|
||||
if not IsPedAPlayer(victim) or NetworkGetPlayerIndexFromPed(victim) ~= cache.playerId then return end
|
||||
|
||||
if not IsPedDeadOrDying(victim, true) and GetEntityHealth(victim) > 0 then
|
||||
local hit, bone = GetPedLastDamageBone(victim)
|
||||
if hit and usingAmbulance then
|
||||
local damageWeapon = ambulance:getLastDamagingWeapon(victim)
|
||||
return damageWeapon and ambulance:updateBodyDamage(bone, damageWeapon)
|
||||
end
|
||||
return
|
||||
local hit, bone = GetPedLastDamageBone(victim)
|
||||
if hit and usingAmbulance then
|
||||
local damageWeapon = ambulance:getLastDamagingWeapon(victim)
|
||||
ambulance:updateBodyDamage(bone, damageWeapon)
|
||||
end
|
||||
|
||||
if not IsPedDeadOrDying(victim, true) or GetEntityHealth(victim) > 100 then return end
|
||||
|
||||
local killerEntity, deathCause = GetPedSourceOfDeath(cache.ped), GetPedCauseOfDeath(cache.ped)
|
||||
local killerClientId = NetworkGetPlayerIndexFromPed(killerEntity)
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
RegisterNetEvent("ND:notifyClient", function(...)
|
||||
NDCore.notify(...)
|
||||
end)
|
||||
|
||||
-- updates the money on the client.
|
||||
RegisterNetEvent("ND:updateMoney", function(cash, bank)
|
||||
if not NDCore.player then return end
|
||||
@@ -22,5 +26,54 @@ RegisterNetEvent("ND:updateLastLocation", function(location)
|
||||
end)
|
||||
|
||||
RegisterNetEvent("ND:revivePlayer", function()
|
||||
NDCore.revivePlayer(true)
|
||||
if source == "" then return end
|
||||
local oldPed = cache.ped
|
||||
local veh = GetVehiclePedIsIn(oldPed)
|
||||
local seat = cache.seat
|
||||
local coords = GetEntityCoords(oldPed)
|
||||
local armor = GetPedArmour(oldPed)
|
||||
|
||||
NetworkResurrectLocalPlayer(coords.x, coords.y, coords.z, GetEntityHeading(oldPed), true, true, false)
|
||||
|
||||
local ped = PlayerPedId()
|
||||
if oldPed ~= ped then
|
||||
DeleteEntity(oldPed)
|
||||
ClearAreaOfPeds(coords.x, coords.y, coords.z, 0.2, false)
|
||||
end
|
||||
|
||||
SetEntityInvincible(ped, false)
|
||||
FreezeEntityPosition(ped, false)
|
||||
SetEntityVisible(ped, true)
|
||||
SetEveryoneIgnorePlayer(ped, false)
|
||||
SetPedCanBeTargetted(ped, true)
|
||||
SetEntityCanBeDamaged(ped, true)
|
||||
SetBlockingOfNonTemporaryEvents(ped, false)
|
||||
SetPedCanRagdollFromPlayerImpact(ped, true)
|
||||
ClearPedTasksImmediately(ped)
|
||||
SetPedArmour(ped, armor)
|
||||
|
||||
if veh and veh ~= 0 then
|
||||
SetPedIntoVehicle(ped, veh, seat)
|
||||
end
|
||||
end)
|
||||
|
||||
RegisterNetEvent("ND:characterUnloaded")
|
||||
|
||||
RegisterNetEvent("ND:clothingMenu", function()
|
||||
if GetResourceState("fivem-appearance") ~= "started" then return end
|
||||
|
||||
local function customize(appearance)
|
||||
if not appearance then return end
|
||||
TriggerServerEvent("ND:updateClothing", appearance)
|
||||
end
|
||||
|
||||
exports["fivem-appearance"]:startPlayerCustomization(customize, {
|
||||
ped = false,
|
||||
headBlend = true,
|
||||
faceFeatures = true,
|
||||
headOverlays = true,
|
||||
components = true,
|
||||
props = true,
|
||||
tattoos = true
|
||||
})
|
||||
end)
|
||||
|
||||
@@ -26,56 +26,15 @@ function NDCore.getPlayersFromCoords(distance, coords)
|
||||
return closePlayers
|
||||
end
|
||||
|
||||
function NDCore.revivePlayer(reset, keepDead)
|
||||
local usingAmbulance = GetResourceState("ND_Ambulance") == "started"
|
||||
if not keepDead then
|
||||
LocalPlayer.state.dead = false
|
||||
if usingAmbulance then
|
||||
local state = Player(cache.serverId).state
|
||||
state:set("isDead", false, true)
|
||||
end
|
||||
end
|
||||
|
||||
local veh = GetVehiclePedIsIn(cache.ped)
|
||||
local seat = cache.seat
|
||||
local coords = GetEntityCoords(cache.ped)
|
||||
NetworkResurrectLocalPlayer(coords.x, coords.y, coords.z, GetEntityHeading(cache.ped), true, true, false)
|
||||
|
||||
local ped = PlayerPedId()
|
||||
if cache.ped ~= ped then
|
||||
DeleteEntity(cache.ped)
|
||||
ClearAreaOfPeds(coords.x, coords.y, coords.z, 0.2, false)
|
||||
end
|
||||
|
||||
SetEntityInvincible(ped, false)
|
||||
FreezeEntityPosition(ped, false)
|
||||
SetEntityVisible(ped, true)
|
||||
SetEveryoneIgnorePlayer(ped, false)
|
||||
SetPedCanBeTargetted(ped, true)
|
||||
SetEntityCanBeDamaged(ped, true)
|
||||
SetBlockingOfNonTemporaryEvents(ped, false)
|
||||
SetPedCanRagdollFromPlayerImpact(ped, true)
|
||||
ClearPedTasksImmediately(ped)
|
||||
|
||||
if veh and veh ~= 0 then
|
||||
SetPedIntoVehicle(ped, veh, seat)
|
||||
end
|
||||
if reset and GetPedMovementClipset(ped) == `move_m@injured` then
|
||||
ClearEntityLastDamageEntity(ped)
|
||||
SetPedMoveRateOverride(ped, 1.0)
|
||||
ResetPedMovementClipset(ped, 0)
|
||||
end
|
||||
if reset and usingAmbulance then
|
||||
exports["ND_Ambulance"]:resetBodyDamage()
|
||||
function NDCore.getConfig(info)
|
||||
if not info then
|
||||
return Config
|
||||
end
|
||||
return Config[info]
|
||||
end
|
||||
|
||||
function NDCore.notify(...)
|
||||
if GetResourceState("ModernHUD") == "started" then
|
||||
exports["ModernHUD"]:notify(...)
|
||||
elseif GetResourceState("ox_lib") == "started" then
|
||||
lib.notify(...)
|
||||
end
|
||||
lib.notify(...)
|
||||
end
|
||||
|
||||
for name, func in pairs(NDCore) do
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
lib.locale()
|
||||
NDCore = {}
|
||||
|
||||
Config = {
|
||||
@@ -7,14 +8,16 @@ Config = {
|
||||
discordAsset = GetConvar("core:discordAsset", "andyyy"),
|
||||
discordAssetSmall = GetConvar("core:discordAssetSmall", "andyyy"),
|
||||
discordActionText = GetConvar("core:discordActionText", "DISCORD"),
|
||||
discordActionLink = GetConvar("discordActionLink", "https://discord.gg/Z9Mxu72zZ6"),
|
||||
discordActionLink = GetConvar("core:discordActionLink", "https://discord.gg/Z9Mxu72zZ6"),
|
||||
discordActionText2 = GetConvar("core:discordActionText2", "STORE"),
|
||||
discordActionLink2 = GetConvar("core:discordActionLink2", "https://andyyy.tebex.io/category/fivem-scripts"),
|
||||
randomUnlockedVehicleChance = GetConvarInt("core:randomUnlockedVehicleChance", 30),
|
||||
disableVehicleAirControl = GetConvarInt("core:disableVehicleAirControl", 1) == 1,
|
||||
randomUnlockedVehicleChance = GetConvarInt("core:randomUnlockedVehicleChance", 30),
|
||||
requireKeys = GetConvarInt("core:requireKeys", 1) == 1,
|
||||
useInventoryForKeys = GetConvarInt("core:useInventoryForKeys", 1) == 1,
|
||||
groups = json.decode(GetConvar("core:groups", "[]")),
|
||||
compatibility = json.decode(GetConvar("core:compatibility", "[]"))
|
||||
compatibility = json.decode(GetConvar("core:compatibility", "[]")),
|
||||
lockpickTries = GetConvarInt("core:lockpickTries", 3)
|
||||
}
|
||||
|
||||
-- Discord rich presence.
|
||||
@@ -24,11 +27,11 @@ CreateThread(function()
|
||||
SetDiscordRichPresenceAssetSmall(Config.discordAssetSmall)
|
||||
SetDiscordRichPresenceAction(0, Config.discordActionText, Config.discordActionLink)
|
||||
SetDiscordRichPresenceAction(1, Config.discordActionText2, Config.discordActionLink2)
|
||||
local presenceText = ("Playing: %s"):format(Config.serverName)
|
||||
local presenceText = locale("discord_text_server", Config.serverName)
|
||||
while true do
|
||||
if NDCore.player then
|
||||
local presence = ("Playing: %s as %s %s"):format(Config.serverName, NDCore.player.firstname, NDCore.player.lastname)
|
||||
local presenceTextSmall = ("Playing as: %s %s"):format(NDCore.player.firstname, NDCore.player.lastname)
|
||||
local presence = locale("discord_text", Config.serverName, NDCore.player.firstname, NDCore.player.lastname)
|
||||
local presenceTextSmall = locale("discord_text_small", NDCore.player.firstname, NDCore.player.lastname)
|
||||
SetRichPresence(presence)
|
||||
SetDiscordRichPresenceAssetText(presenceText)
|
||||
SetDiscordRichPresenceAssetSmallText(presenceTextSmall)
|
||||
@@ -47,8 +50,8 @@ CreateThread(function()
|
||||
sleep = 0
|
||||
BeginScaleformMovieMethodOnFrontendHeader("SET_HEADING_DETAILS")
|
||||
ScaleformMovieMethodAddParamPlayerNameString(("%s %s"):format(NDCore.player.firstname, NDCore.player.lastname))
|
||||
ScaleformMovieMethodAddParamTextureNameString(("Cash: $%d"):format(NDCore.player.cash))
|
||||
ScaleformMovieMethodAddParamTextureNameString(("Bank: $%d"):format(NDCore.player.bank))
|
||||
ScaleformMovieMethodAddParamTextureNameString(locale("pause_menu_cash", NDCore.player.cash))
|
||||
ScaleformMovieMethodAddParamTextureNameString(locale("pause_menu_bank", NDCore.player.bank))
|
||||
EndScaleformMovieMethod()
|
||||
elseif sleep == 0 then
|
||||
sleep = 500
|
||||
|
||||
@@ -101,7 +101,18 @@ local function updateBlips(playerGroups)
|
||||
end
|
||||
end
|
||||
|
||||
function NDCore.createAiPed(info)
|
||||
local function disableCollisionWithModels(ped, models)
|
||||
if not models then return end
|
||||
local coords = GetEntityCoords(ped)
|
||||
for i=1, #models do
|
||||
local m = models[i]
|
||||
local model = type(m) == "number" and m or GetHashKey(m)
|
||||
local obj = GetClosestObjectOfType(coords.x, coords.y, coords.z, 5.0, model, false, false, false)
|
||||
SetEntityNoCollisionEntity(ped, obj, false)
|
||||
end
|
||||
end
|
||||
|
||||
function NDCore.createAiPed(info, cb)
|
||||
local ped
|
||||
local model = type(info.model) == "string" and GetHashKey(info.model) or info.model
|
||||
local blipInfo = info.blip
|
||||
@@ -111,7 +122,7 @@ function NDCore.createAiPed(info)
|
||||
local options = info.options
|
||||
local blip = createBlip(coords, blipInfo)
|
||||
local point = lib.points.new({
|
||||
coords = vec3(coords.x, coords.y, coords.z),
|
||||
coords = coords.xyz,
|
||||
distance = info.distance or 25.0
|
||||
})
|
||||
|
||||
@@ -123,6 +134,10 @@ function NDCore.createAiPed(info)
|
||||
resource = info.resource or GetInvokingResource()
|
||||
}
|
||||
|
||||
if blip and blipInfo and blipInfo.showWhenNear and DoesBlipExist(blip) and #(GetEntityCoords(cache.ped)-coords.xyz) > point.distance then
|
||||
SetBlipAlpha(blip, 0)
|
||||
end
|
||||
|
||||
function point:onEnter()
|
||||
local found, ground = GetGroundZFor_3dCoord(coords.x, coords.y, coords.z, true)
|
||||
lib.requestModel(model)
|
||||
@@ -133,6 +148,11 @@ function NDCore.createAiPed(info)
|
||||
Wait(100)
|
||||
end
|
||||
|
||||
if cb then
|
||||
cb(ped)
|
||||
end
|
||||
|
||||
disableCollisionWithModels(ped, info.disableCollisionWithModels)
|
||||
configPed(ped)
|
||||
setClothing(ped, clothing)
|
||||
locations[id].ped = ped
|
||||
@@ -218,10 +238,10 @@ end)
|
||||
RegisterCommand("getclothing", function(source, args, rawCommand)
|
||||
local info = ""
|
||||
for k, v in pairs(clothingComponents) do
|
||||
info = ("%s\n%s = {\n drawable = %s,\n texture = %s\n},"):format(info, k, GetPedDrawableVariation(cache.ped, v), GetPedTextureVariation(cache.ped, v))
|
||||
info = ("%s\n%s = { drawable = %s, texture = %s },"):format(info, k, GetPedDrawableVariation(cache.ped, v), GetPedTextureVariation(cache.ped, v))
|
||||
end
|
||||
for k, v in pairs(clothingProps) do
|
||||
info = ("%s\n%s = {\n drawable = %s,\n texture = %s\n},"):format(info, k, GetPedPropIndex(cache.ped, v), GetPedPropTextureIndex(cache.ped, v))
|
||||
info = ("%s\n%s = { drawable = %s, texture = %s },"):format(info, k, GetPedPropIndex(cache.ped, v), GetPedPropTextureIndex(cache.ped, v))
|
||||
end
|
||||
lib.setClipboard(info)
|
||||
end, false)
|
||||
|
||||
@@ -1,4 +1,14 @@
|
||||
return {
|
||||
{
|
||||
garageType = "land",
|
||||
groups = {"lsfd"},
|
||||
ped = vector4(370.9027, -593.8090, 28.8681, 73.6009),
|
||||
vehicleSpawns = {
|
||||
vec4(366.7840, -591.4883, 28.7261, 339.6823),
|
||||
vec4(365.0753, -582.8641, 28.7156, 135.0064),
|
||||
vec4(357.4239, -604.7719, 28.6767, 177.1355),
|
||||
}
|
||||
},
|
||||
{
|
||||
garageType = "land",
|
||||
groups = {"sahp", "lspd", "bcso"},
|
||||
@@ -240,4 +250,52 @@ return {
|
||||
vector4(216.56, -801.90, 30.79, 69.39)
|
||||
}
|
||||
},
|
||||
{
|
||||
garageType = "land",
|
||||
ped = vector4(587.5941, 2744.2844, 42.0691, 181.0514),
|
||||
vehicleSpawns = {
|
||||
vector4(584.3921, 2721.3599, 41.6483, 184.3260),
|
||||
vector4(577.1069, 2736.2322, 41.6097, 184.6912),
|
||||
vector4(577.9459, 2721.0010, 41.6481, 185.1414),
|
||||
vector4(574.1685, 2735.7288, 41.6397, 184.5562)
|
||||
}
|
||||
},
|
||||
{
|
||||
garageType = "land",
|
||||
ped = vector4(2746.1726, 3458.7378, 55.8272, 245.1009),
|
||||
vehicleSpawns = {
|
||||
vector4(2768.2136, 3456.2710, 55.2840, 67.7897),
|
||||
vector4(2759.3218, 3451.1448, 55.4786, 248.0150),
|
||||
vector4(2763.6526, 3445.0544, 55.4741, 66.9754),
|
||||
vector4(2787.2947, 3467.1001, 54.9407, 247.4356),
|
||||
vector4(2773.9514, 3471.6238, 55.0407, 246.8264)
|
||||
}
|
||||
},
|
||||
{
|
||||
garageType = "land",
|
||||
ped = vector4(120.4042, 6623.5190, 31.9593, 228.8283),
|
||||
vehicleSpawns = {
|
||||
vector4(155.9047, 6593.3252, 31.4343, 359.3789),
|
||||
vector4(155.7900, 6602.6978, 31.4463, 358.8232),
|
||||
vector4(145.8267, 6614.0996, 31.4007, 178.7948),
|
||||
vector4(145.6977, 6602.8950, 31.4397, 181.0616),
|
||||
vector4(132.4042, 6585.2139, 31.5501, 91.0906)
|
||||
}
|
||||
},
|
||||
{
|
||||
garageType = "heli",
|
||||
groups = {"lspd"},
|
||||
ped = vector4(465.6194, -985.4730, 43.6918, 0.8591),
|
||||
vehicleSpawns = {
|
||||
vector4(449.3105, -981.1057, 44.0788, 359.6042)
|
||||
}
|
||||
},
|
||||
{
|
||||
garageType = "heli",
|
||||
groups = {"lsfd"},
|
||||
ped = vector4(339.6271, -581.0325, 74.1656, 267.8232),
|
||||
vehicleSpawns = {
|
||||
vector4(351.3463, -588.1304, 74.1698, 108.5617)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -119,8 +119,8 @@ end
|
||||
local function parkVehicle(veh)
|
||||
if not veh or not DoesEntityExist(veh) then
|
||||
return NDCore.notify({
|
||||
title = "Garage",
|
||||
description = "No owned vehicle found nearby.",
|
||||
title = locale("garage"),
|
||||
description = locale("no_owned_veh_nearby"),
|
||||
type = "error",
|
||||
position = "bottom",
|
||||
duration = 3000
|
||||
@@ -128,8 +128,8 @@ local function parkVehicle(veh)
|
||||
end
|
||||
if GetPedInVehicleSeat(veh, -1) ~= 0 then
|
||||
NDCore.notify({
|
||||
title = "Garage",
|
||||
description = "Player in vehicle!",
|
||||
title = locale("garage"),
|
||||
description = locale("player_in_veh"),
|
||||
type = "error",
|
||||
position = "bottom",
|
||||
duration = 3000
|
||||
@@ -156,13 +156,13 @@ end
|
||||
|
||||
local function getEngineStatus(health)
|
||||
if health > 950 then
|
||||
return "Perfect"
|
||||
return locale("perfect")
|
||||
elseif health > 750 then
|
||||
return "Good"
|
||||
return locale("good")
|
||||
elseif health > 500 then
|
||||
return "Bad"
|
||||
return locale("bad")
|
||||
end
|
||||
return "Very bad"
|
||||
return locale("very_bad")
|
||||
end
|
||||
|
||||
local function createMenuOptions(vehicle, vehicleSpawns)
|
||||
@@ -174,21 +174,21 @@ local function createMenuOptions(vehicle, vehicleSpawns)
|
||||
if not makeName or makeName == "NULL" then
|
||||
makeName = ""
|
||||
else
|
||||
metadata[#metadata+1] = {label = "Make", value = makeName}
|
||||
metadata[#metadata+1] = {label = locale("veh_make_brand"), value = makeName}
|
||||
makeName = makeName .. " "
|
||||
end
|
||||
if not modelName or modelName == "NULL" then
|
||||
modelName = ""
|
||||
else
|
||||
metadata[#metadata+1] = {label = "Model", value = modelName}
|
||||
metadata[#metadata+1] = {label = locale("veh_model"), value = modelName}
|
||||
end
|
||||
|
||||
if props?.plate then
|
||||
metadata[#metadata+1] = {label = "Plate", value = props.plate}
|
||||
metadata[#metadata+1] = {label = locale("veh_plate"), value = props.plate}
|
||||
end
|
||||
if props?.engineHealth then
|
||||
metadata[#metadata+1] = {
|
||||
label = "Engine status",
|
||||
label = locale("engine_status"),
|
||||
value = getEngineStatus(props.engineHealth),
|
||||
progress = props.engineHealth/10,
|
||||
colorScheme = "blue"
|
||||
@@ -205,7 +205,7 @@ local function createMenuOptions(vehicle, vehicleSpawns)
|
||||
end
|
||||
|
||||
return {
|
||||
title = ("Vehicle: %s%s\nPlate: %s"):format(makeName, modelName, props?.plate or "not found"),
|
||||
title = ("%s: %s%s\n%s: %s"):format(locale("vehicle"), makeName, modelName, locale("veh_plate"), props?.plate or locale("not_found")),
|
||||
metadata = metadata,
|
||||
onSelect = function(args)
|
||||
TriggerServerEvent("ND_Vehicles:takeVehicle", vehicle.id, vehicleSpawns)
|
||||
@@ -217,7 +217,7 @@ local function createMenu(vehicles, garageType, vehicleSpawns, impound)
|
||||
local options = {}
|
||||
if not impound then
|
||||
options[#options+1] = {
|
||||
title = "Park vehicle",
|
||||
title = locale("park_veh"),
|
||||
onSelect = function(args)
|
||||
local veh = getClosestOwnedVehicle()
|
||||
parkVehicle(veh)
|
||||
@@ -231,13 +231,13 @@ local function createMenu(vehicles, garageType, vehicleSpawns, impound)
|
||||
end
|
||||
if impound and #options == 0 then
|
||||
options[#options+1] = {
|
||||
title = "No vehicles found",
|
||||
title = locale("no_vehs_found"),
|
||||
readOnly = true
|
||||
}
|
||||
end
|
||||
return {
|
||||
id = ("garage_%s"):format(garageType),
|
||||
title = impound and "Vehicle impound" or "Parking garage",
|
||||
title = impound and locale("vehicle_impound") or locale("parking_garage"),
|
||||
options = options,
|
||||
onExit = function()
|
||||
garageOpen = false
|
||||
@@ -253,7 +253,7 @@ for i=1, #locations do
|
||||
distance = 45.0,
|
||||
clothing = clothing[math.random(1, #clothing)],
|
||||
blip = {
|
||||
label = location.impound and ("Impound (%s)"):format(location.garageType) or ("Parking garage (%s)"):format(location.garageType),
|
||||
label = location.impound and locale("impound_w_location", location.garageType) or locale("garage_w_location", location.garageType),
|
||||
sprite = location.impound and 285 or sprite[location.garageType],
|
||||
scale = 0.7,
|
||||
color = 3,
|
||||
@@ -267,7 +267,7 @@ for i=1, #locations do
|
||||
{
|
||||
name = "nd_core:garagePed",
|
||||
icon = "fa-solid fa-warehouse",
|
||||
label = location.impound and "View impounded vehicles" or "View garage",
|
||||
label = location.impound and locale("view_impounded_vehs") or locale("view_garage"),
|
||||
distance = 2.0,
|
||||
canInteract = function(entity, distance, coords, name, bone)
|
||||
if not location.groups then return true end
|
||||
|
||||
@@ -1,188 +1,188 @@
|
||||
local vehicleColorNames = {
|
||||
[0] = "Black",
|
||||
[1] = "Black",
|
||||
[2] = "Black",
|
||||
[3] = "Silver",
|
||||
[4] = "Silver",
|
||||
[5] = "Silver",
|
||||
[6] = "Gray",
|
||||
[7] = "Silver",
|
||||
[8] = "Silver",
|
||||
[9] = "Silver",
|
||||
[10] = "Metal",
|
||||
[11] = "Grey",
|
||||
[12] = "Black",
|
||||
[13] = "Gray",
|
||||
[14] = "Grey",
|
||||
[15] = "Black",
|
||||
[16] = "Black",
|
||||
[17] = "Silver",
|
||||
[18] = "Silver",
|
||||
[19] = "Metal",
|
||||
[20] = "Silver",
|
||||
[21] = "Black",
|
||||
[22] = "Graphite",
|
||||
[23] = "Silver",
|
||||
[24] = "Silver",
|
||||
[25] = "Silver",
|
||||
[26] = "Silver",
|
||||
[27] = "Red",
|
||||
[28] = "Red",
|
||||
[29] = "Red",
|
||||
[30] = "Red",
|
||||
[31] = "Red",
|
||||
[32] = "Red",
|
||||
[33] = "Red",
|
||||
[34] = "Red",
|
||||
[35] = "Red",
|
||||
[36] = "Orange",
|
||||
[37] = "Gold",
|
||||
[38] = "Orange",
|
||||
[39] = "Red",
|
||||
[40] = "Red",
|
||||
[41] = "Orange",
|
||||
[42] = "Yellow",
|
||||
[43] = "Red",
|
||||
[44] = "Red",
|
||||
[45] = "Red",
|
||||
[46] = "Red",
|
||||
[47] = "Red",
|
||||
[48] = "Red",
|
||||
[49] = "Green",
|
||||
[50] = "Green",
|
||||
[51] = "Green",
|
||||
[52] = "Green",
|
||||
[53] = "Green",
|
||||
[54] = "Green",
|
||||
[55] = "Green",
|
||||
[56] = "Green",
|
||||
[57] = "Green",
|
||||
[58] = "Green",
|
||||
[59] = "Green",
|
||||
[60] = "Green",
|
||||
[61] = "Blue",
|
||||
[62] = "Blue",
|
||||
[63] = "Blue",
|
||||
[64] = "Blue",
|
||||
[65] = "Blue",
|
||||
[66] = "Blue",
|
||||
[67] = "Blue",
|
||||
[68] = "Blue",
|
||||
[69] = "Blue",
|
||||
[70] = "Blue",
|
||||
[71] = "Blue",
|
||||
[72] = "Blue",
|
||||
[73] = "Blue",
|
||||
[74] = "Blue",
|
||||
[75] = "Blue",
|
||||
[76] = "Blue",
|
||||
[77] = "Blue",
|
||||
[78] = "Blue",
|
||||
[79] = "Bblue",
|
||||
[80] = "Blue",
|
||||
[81] = "Blue",
|
||||
[82] = "Blue",
|
||||
[83] = "Blue",
|
||||
[84] = "Blue",
|
||||
[85] = "Blue",
|
||||
[86] = "Blue",
|
||||
[87] = "Blue",
|
||||
[88] = "Yellow",
|
||||
[89] = "Yellow",
|
||||
[90] = "Bronze",
|
||||
[91] = "Yellow",
|
||||
[92] = "Lime",
|
||||
[93] = "Champagne",
|
||||
[94] = "Beige",
|
||||
[95] = "Ivory",
|
||||
[96] = "Brown",
|
||||
[97] = "Brown",
|
||||
[98] = "Brown",
|
||||
[99] = "Beige",
|
||||
[100] = "Brown",
|
||||
[101] = "Brown",
|
||||
[102] = "Beechwood",
|
||||
[103] = "Beechwood",
|
||||
[104] = "Orange",
|
||||
[105] = "Sand",
|
||||
[106] = "Sand",
|
||||
[107] = "Cream",
|
||||
[108] = "Brown",
|
||||
[109] = "Brown",
|
||||
[110] = "Brown",
|
||||
[111] = "White",
|
||||
[112] = "White",
|
||||
[113] = "Beige",
|
||||
[114] = "Brown",
|
||||
[115] = "Brown",
|
||||
[116] = "Beige",
|
||||
[117] = "Steel",
|
||||
[118] = "Steel",
|
||||
[119] = "Aluminium",
|
||||
[120] = "Chrome",
|
||||
[121] = "White",
|
||||
[122] = "White",
|
||||
[123] = "Orange",
|
||||
[124] = "Orange",
|
||||
[125] = "Green",
|
||||
[126] = "Yellow",
|
||||
[127] = "Blue",
|
||||
[128] = "Green",
|
||||
[129] = "Brown",
|
||||
[130] = "Orange",
|
||||
[131] = "White",
|
||||
[132] = "White",
|
||||
[133] = "Green",
|
||||
[134] = "White",
|
||||
[135] = "Pink",
|
||||
[136] = "pink",
|
||||
[137] = "Pink",
|
||||
[138] = "Orange",
|
||||
[139] = "Green",
|
||||
[140] = "Blue",
|
||||
[141] = "Black",
|
||||
[142] = "Black",
|
||||
[143] = "Black",
|
||||
[144] = "Green",
|
||||
[145] = "Purple",
|
||||
[146] = "Blue",
|
||||
[147] = "Black",
|
||||
[148] = "Purple",
|
||||
[149] = "Purple",
|
||||
[150] = "Red",
|
||||
[151] = "Green",
|
||||
[152] = "Green",
|
||||
[153] = "Brown",
|
||||
[154] = "Tan",
|
||||
[155] = "Green",
|
||||
[156] = "ALLOY",
|
||||
[157] = "Blue",
|
||||
[0] = locale("veh_color_black"),
|
||||
[1] = locale("veh_color_black"),
|
||||
[2] = locale("veh_color_black"),
|
||||
[3] = locale("veh_color_silver"),
|
||||
[4] = locale("veh_color_silver"),
|
||||
[5] = locale("veh_color_silver"),
|
||||
[6] = locale("veh_color_grey"),
|
||||
[7] = locale("veh_color_silver"),
|
||||
[8] = locale("veh_color_silver"),
|
||||
[9] = locale("veh_color_silver"),
|
||||
[10] = locale("veh_color_metal"),
|
||||
[11] = locale("veh_color_grey"),
|
||||
[12] = locale("veh_color_black"),
|
||||
[13] = locale("veh_color_grey"),
|
||||
[14] = locale("veh_color_grey"),
|
||||
[15] = locale("veh_color_black"),
|
||||
[16] = locale("veh_color_black"),
|
||||
[17] = locale("veh_color_silver"),
|
||||
[18] = locale("veh_color_silver"),
|
||||
[19] = locale("veh_color_metal"),
|
||||
[20] = locale("veh_color_silver"),
|
||||
[21] = locale("veh_color_black"),
|
||||
[22] = locale("veh_color_graphite"),
|
||||
[23] = locale("veh_color_silver"),
|
||||
[24] = locale("veh_color_silver"),
|
||||
[25] = locale("veh_color_silver"),
|
||||
[26] = locale("veh_color_silver"),
|
||||
[27] = locale("veh_color_red"),
|
||||
[28] = locale("veh_color_red"),
|
||||
[29] = locale("veh_color_red"),
|
||||
[30] = locale("veh_color_red"),
|
||||
[31] = locale("veh_color_red"),
|
||||
[32] = locale("veh_color_red"),
|
||||
[33] = locale("veh_color_red"),
|
||||
[34] = locale("veh_color_red"),
|
||||
[35] = locale("veh_color_red"),
|
||||
[36] = locale("veh_color_orange"),
|
||||
[37] = locale("veh_color_gold"),
|
||||
[38] = locale("veh_color_orange"),
|
||||
[39] = locale("veh_color_red"),
|
||||
[40] = locale("veh_color_red"),
|
||||
[41] = locale("veh_color_orange"),
|
||||
[42] = locale("veh_color_yellow"),
|
||||
[43] = locale("veh_color_red"),
|
||||
[44] = locale("veh_color_red"),
|
||||
[45] = locale("veh_color_red"),
|
||||
[46] = locale("veh_color_red"),
|
||||
[47] = locale("veh_color_red"),
|
||||
[48] = locale("veh_color_red"),
|
||||
[49] = locale("veh_color_green"),
|
||||
[50] = locale("veh_color_green"),
|
||||
[51] = locale("veh_color_green"),
|
||||
[52] = locale("veh_color_green"),
|
||||
[53] = locale("veh_color_green"),
|
||||
[54] = locale("veh_color_green"),
|
||||
[55] = locale("veh_color_green"),
|
||||
[56] = locale("veh_color_green"),
|
||||
[57] = locale("veh_color_green"),
|
||||
[58] = locale("veh_color_green"),
|
||||
[59] = locale("veh_color_green"),
|
||||
[60] = locale("veh_color_green"),
|
||||
[61] = locale("veh_color_blue"),
|
||||
[62] = locale("veh_color_blue"),
|
||||
[63] = locale("veh_color_blue"),
|
||||
[64] = locale("veh_color_blue"),
|
||||
[65] = locale("veh_color_blue"),
|
||||
[66] = locale("veh_color_blue"),
|
||||
[67] = locale("veh_color_blue"),
|
||||
[68] = locale("veh_color_blue"),
|
||||
[69] = locale("veh_color_blue"),
|
||||
[70] = locale("veh_color_blue"),
|
||||
[71] = locale("veh_color_blue"),
|
||||
[72] = locale("veh_color_blue"),
|
||||
[73] = locale("veh_color_blue"),
|
||||
[74] = locale("veh_color_blue"),
|
||||
[75] = locale("veh_color_blue"),
|
||||
[76] = locale("veh_color_blue"),
|
||||
[77] = locale("veh_color_blue"),
|
||||
[78] = locale("veh_color_blue"),
|
||||
[79] = locale("veh_color_bblue"),
|
||||
[80] = locale("veh_color_blue"),
|
||||
[81] = locale("veh_color_blue"),
|
||||
[82] = locale("veh_color_blue"),
|
||||
[83] = locale("veh_color_blue"),
|
||||
[84] = locale("veh_color_blue"),
|
||||
[85] = locale("veh_color_blue"),
|
||||
[86] = locale("veh_color_blue"),
|
||||
[87] = locale("veh_color_blue"),
|
||||
[88] = locale("veh_color_yellow"),
|
||||
[89] = locale("veh_color_yellow"),
|
||||
[90] = locale("veh_color_bronze"),
|
||||
[91] = locale("veh_color_yellow"),
|
||||
[92] = locale("veh_color_lime"),
|
||||
[93] = locale("veh_color_champagne"),
|
||||
[94] = locale("veh_color_beige"),
|
||||
[95] = locale("veh_color_ivory"),
|
||||
[96] = locale("veh_color_brown"),
|
||||
[97] = locale("veh_color_brown"),
|
||||
[98] = locale("veh_color_brown"),
|
||||
[99] = locale("veh_color_beige"),
|
||||
[100] = locale("veh_color_brown"),
|
||||
[101] = locale("veh_color_brown"),
|
||||
[102] = locale("veh_color_beechwood"),
|
||||
[103] = locale("veh_color_beechwood"),
|
||||
[104] = locale("veh_color_orange"),
|
||||
[105] = locale("veh_color_sand"),
|
||||
[106] = locale("veh_color_sand"),
|
||||
[107] = locale("veh_color_cream"),
|
||||
[108] = locale("veh_color_brown"),
|
||||
[109] = locale("veh_color_brown"),
|
||||
[110] = locale("veh_color_brown"),
|
||||
[111] = locale("veh_color_white"),
|
||||
[112] = locale("veh_color_white"),
|
||||
[113] = locale("veh_color_beige"),
|
||||
[114] = locale("veh_color_brown"),
|
||||
[115] = locale("veh_color_brown"),
|
||||
[116] = locale("veh_color_beige"),
|
||||
[117] = locale("veh_color_steel"),
|
||||
[118] = locale("veh_color_steel"),
|
||||
[119] = locale("veh_color_aluminium"),
|
||||
[120] = locale("veh_color_chrome"),
|
||||
[121] = locale("veh_color_white"),
|
||||
[122] = locale("veh_color_white"),
|
||||
[123] = locale("veh_color_orange"),
|
||||
[124] = locale("veh_color_orange"),
|
||||
[125] = locale("veh_color_green"),
|
||||
[126] = locale("veh_color_yellow"),
|
||||
[127] = locale("veh_color_blue"),
|
||||
[128] = locale("veh_color_green"),
|
||||
[129] = locale("veh_color_brown"),
|
||||
[130] = locale("veh_color_orange"),
|
||||
[131] = locale("veh_color_white"),
|
||||
[132] = locale("veh_color_white"),
|
||||
[133] = locale("veh_color_green"),
|
||||
[134] = locale("veh_color_white"),
|
||||
[135] = locale("veh_color_pink"),
|
||||
[136] = locale("veh_color_pink"),
|
||||
[137] = locale("veh_color_pink"),
|
||||
[138] = locale("veh_color_orange"),
|
||||
[139] = locale("veh_color_green"),
|
||||
[140] = locale("veh_color_blue"),
|
||||
[141] = locale("veh_color_black"),
|
||||
[142] = locale("veh_color_black"),
|
||||
[143] = locale("veh_color_black"),
|
||||
[144] = locale("veh_color_green"),
|
||||
[145] = locale("veh_color_purple"),
|
||||
[146] = locale("veh_color_blue"),
|
||||
[147] = locale("veh_color_black"),
|
||||
[148] = locale("veh_color_purple"),
|
||||
[149] = locale("veh_color_purple"),
|
||||
[150] = locale("veh_color_red"),
|
||||
[151] = locale("veh_color_green"),
|
||||
[152] = locale("veh_color_green"),
|
||||
[153] = locale("veh_color_brown"),
|
||||
[154] = locale("veh_color_tan"),
|
||||
[155] = locale("veh_color_green"),
|
||||
[156] = locale("veh_color_alloy"),
|
||||
[157] = locale("veh_color_blue"),
|
||||
}
|
||||
|
||||
local vehicleClassNames = {
|
||||
[0] = "Compact",
|
||||
[1] = "Sedan",
|
||||
[2] = "SUV",
|
||||
[3] = "Coupe",
|
||||
[4] = "Muscle",
|
||||
[5] = "Sports Classic",
|
||||
[6] = "Sport",
|
||||
[7] = "Super",
|
||||
[8] = "Motorcycle",
|
||||
[9] = "Off-road",
|
||||
[10] = "Industrial",
|
||||
[11] = "Utility",
|
||||
[12] = "Van",
|
||||
[13] = "Cycle",
|
||||
[14] = "Boat",
|
||||
[15] = "Helicopter",
|
||||
[16] = "Plane",
|
||||
[17] = "Service",
|
||||
[18] = "Emergency",
|
||||
[19] = "Military",
|
||||
[20] = "Commercial",
|
||||
[21] = "Train",
|
||||
[22] = "Open wheel"
|
||||
[0] = locale("veh_class_compact"),
|
||||
[1] = locale("veh_class_sedan"),
|
||||
[2] = locale("veh_class_suv"),
|
||||
[3] = locale("veh_class_coupe"),
|
||||
[4] = locale("veh_class_muscle"),
|
||||
[5] = locale("veh_class_sports_classic"),
|
||||
[6] = locale("veh_class_sport"),
|
||||
[7] = locale("veh_class_super"),
|
||||
[8] = locale("veh_class_motorcycle"),
|
||||
[9] = locale("veh_class_off_road"),
|
||||
[10] = locale("veh_class_industrial"),
|
||||
[11] = locale("veh_class_utility"),
|
||||
[12] = locale("veh_class_van"),
|
||||
[13] = locale("veh_class_cycle"),
|
||||
[14] = locale("veh_class_boat"),
|
||||
[15] = locale("veh_class_helicopter"),
|
||||
[16] = locale("veh_class_plane"),
|
||||
[17] = locale("veh_class_service"),
|
||||
[18] = locale("veh_class_emergency"),
|
||||
[19] = locale("veh_class_military"),
|
||||
[20] = locale("veh_class_commercial"),
|
||||
[21] = locale("veh_class_train"),
|
||||
[22] = locale("veh_class_open_wheel")
|
||||
}
|
||||
|
||||
local cruiseSpeedSet = 0
|
||||
@@ -264,7 +264,7 @@ RegisterNetEvent("ND_Vehicles:blip", function(netId, status)
|
||||
SetBlipScale(blip, 0.8)
|
||||
SetBlipAsShortRange(blip, true)
|
||||
BeginTextCommandSetBlipName("STRING")
|
||||
AddTextComponentSubstringPlayerName("Personal vehicle")
|
||||
AddTextComponentSubstringPlayerName(locale("personal_vehicle"))
|
||||
EndTextCommandSetBlipName(blip)
|
||||
end)
|
||||
|
||||
@@ -293,6 +293,7 @@ AddStateBagChangeHandler("props", nil, function(bagName, key, value, reserved, r
|
||||
lib.setVehicleProperties(entity, props)
|
||||
end)
|
||||
|
||||
local playingKey = 0
|
||||
local function playKeyFob(veh)
|
||||
local keyFob
|
||||
local ped = cache.ped
|
||||
@@ -300,12 +301,21 @@ local function playKeyFob(veh)
|
||||
if #(coords-GetEntityCoords(veh)) > 25.0 then return end
|
||||
|
||||
if not playerVehicle then
|
||||
playingKey += 1
|
||||
SetPedCurrentWeaponVisible(ped, false, false)
|
||||
ClearPedTasks(ped)
|
||||
lib.requestAnimDict("anim@mp_player_intmenu@key_fob@")
|
||||
TaskPlayAnim(ped, "anim@mp_player_intmenu@key_fob@", "fob_click_fp", 8.0, 8.0, -1, 48, 1, false, false, false)
|
||||
keyFob = CreateObject(`lr_prop_carkey_fob`, 0, 0, 0, true, true, true)
|
||||
AttachEntityToEntity(keyFob, ped, GetPedBoneIndex(ped, 0xDEAD), 0.12, 0.04, -0.025, -100.0, 100.0, 0.0, true, true, false, true, 1, true)
|
||||
Wait(700)
|
||||
SetTimeout(400, function()
|
||||
playingKey -= 1
|
||||
end)
|
||||
SetTimeout(1200, function()
|
||||
if playingKey > 0 then return end
|
||||
SetPedCurrentWeaponVisible(ped, true, false)
|
||||
end)
|
||||
end
|
||||
|
||||
PlaySoundFromEntity(-1, "Remote_Control_Fob", ped, "PI_Menu_Sounds", true, 0)
|
||||
@@ -346,8 +356,9 @@ AddStateBagChangeHandler("locked", nil, function(bagName, key, value, reserved,
|
||||
end)
|
||||
end)
|
||||
|
||||
lib.callback.register("ND_Vehicles:getProps", function(netId)
|
||||
local veh = getVehFromNetId(netId)
|
||||
local function getProps(veh)
|
||||
if not veh or not DoesEntityExist(veh) then return end
|
||||
|
||||
local props = lib.getVehicleProperties(veh)
|
||||
local colorPrimary, colorSecondary = GetVehicleColours(veh)
|
||||
if not props then return end
|
||||
@@ -358,7 +369,18 @@ lib.callback.register("ND_Vehicles:getProps", function(netId)
|
||||
props.className = vehicleClassNames[GetVehicleClass(veh)]
|
||||
props.makeName = GetLabelText(GetMakeNameFromVehicleModel(props.model))
|
||||
props.modelName = GetLabelText(GetDisplayNameFromVehicleModel(props.model))
|
||||
|
||||
return props
|
||||
end
|
||||
|
||||
lib.callback.register("ND_Vehicles:getProps", function(netId)
|
||||
local veh = getVehFromNetId(netId)
|
||||
return getProps(veh)
|
||||
end)
|
||||
|
||||
lib.callback.register("ND_Vehicles:getPropsFromCurrentVeh", function()
|
||||
local veh = GetVehiclePedIsIn(cache.ped)
|
||||
return getProps(veh)
|
||||
end)
|
||||
|
||||
lib.callback.register("ND_Vehicles:getVehicleModelMakeLabel", function(model)
|
||||
@@ -425,7 +447,7 @@ end
|
||||
|
||||
local vehicleLockKeybind = lib.addKeybind({
|
||||
name = "vehicleKey",
|
||||
description = "Unlock/lock vehicle (double click)",
|
||||
description = locale("keybind_carkey"),
|
||||
defaultKey = "E",
|
||||
onPressed = function(self)
|
||||
local time = GetCloudTimeAsInt()
|
||||
@@ -447,8 +469,8 @@ NDCore.isResourceStarted("ox_inventory", function(started)
|
||||
Wait(1000)
|
||||
vehicleLockKeybind:disable(true)
|
||||
exports.ox_inventory:displayMetadata({
|
||||
vehPlate = "Plate",
|
||||
vehModel = "Model"
|
||||
vehPlate = locale("veh_plate"),
|
||||
vehModel = locale("veh_model")
|
||||
})
|
||||
end)
|
||||
|
||||
@@ -470,22 +492,35 @@ CreateThread(function()
|
||||
local wait = 500
|
||||
while true do
|
||||
Wait(wait)
|
||||
|
||||
local reset = true
|
||||
playerVehicle = cache.seat == -1 and cache.vehicle
|
||||
if playerVehicle then
|
||||
if Config.disableVehicleAirControl and not vehicleClassNotDisableAirControl[GetVehicleClass(playerVehicle)] and (IsEntityInAir(playerVehicle) or IsEntityUpsidedown(playerVehicle)) then
|
||||
wait = 0
|
||||
DisableControlAction(0, 59) -- disable vehicle air control.
|
||||
DisableControlAction(0, 60)
|
||||
elseif not GetIsVehicleEngineRunning(playerVehicle) and not hasVehicleKeysCheck(playerVehicle) then
|
||||
wait = 0
|
||||
DisableControlAction(0, 59)
|
||||
if DoesEntityExist(playerVehicle) and IsVehicleEngineStarting(playerVehicle) then
|
||||
SetVehicleEngineOn(playerVehicle, false, true, true) -- don't turn on engine if no keys.
|
||||
end
|
||||
else
|
||||
wait = 500
|
||||
|
||||
local entering = GetVehiclePedIsEntering(cache.ped)
|
||||
if entering and DoesEntityExist(entering) and IsVehicleNeedsToBeHotwired(entering) then
|
||||
SetVehicleNeedsToBeHotwired(entering, false)
|
||||
end
|
||||
|
||||
if not playerVehicle then goto skip end
|
||||
|
||||
if Config.disableVehicleAirControl and not vehicleClassNotDisableAirControl[GetVehicleClass(playerVehicle)] and (IsEntityInAir(playerVehicle) or IsEntityUpsidedown(playerVehicle)) then
|
||||
wait = 0
|
||||
reset = false
|
||||
DisableControlAction(0, 59) -- disable vehicle air control.
|
||||
DisableControlAction(0, 60)
|
||||
end
|
||||
if Config.requireKeys and not GetIsVehicleEngineRunning(playerVehicle) and not hasVehicleKeysCheck(playerVehicle) then
|
||||
wait = 0
|
||||
reset = false
|
||||
DisableControlAction(0, 59)
|
||||
DisableControlAction(0, 71)
|
||||
if DoesEntityExist(playerVehicle) and IsVehicleEngineStarting(playerVehicle) then
|
||||
SetVehicleEngineOn(playerVehicle, false, true, true) -- don't turn on engine if no keys.
|
||||
end
|
||||
elseif wait ~= 500 then
|
||||
end
|
||||
|
||||
::skip::
|
||||
if (reset or not playerVehicle) and wait ~= 500 then
|
||||
wait = 500
|
||||
end
|
||||
end
|
||||
@@ -517,7 +552,7 @@ local function hotwireVehicle()
|
||||
|
||||
local success = lib.progressCircle({
|
||||
duration = math.random(10000, 20000),
|
||||
label = "Hotwiring",
|
||||
label = locale("progress_hotwiring"),
|
||||
useWhileDead = false,
|
||||
allowRagdoll = false,
|
||||
allowCuffed = false,
|
||||
@@ -574,7 +609,7 @@ local function lockpickVehicle()
|
||||
}
|
||||
|
||||
lib.requestAnimDict("veh@break_in@0h@p_m_one@")
|
||||
for i=1, 7 do
|
||||
for i=1, Config.lockpickTries do
|
||||
TaskPlayAnimAdvanced(cache.ped, "veh@break_in@0h@p_m_one@", "std_force_entry_ds", pos.x, pos.y, pos.z+0.025, rot.x, rot.y, rot.z, 8.0, 8.0, 1800, 28, 0.1)
|
||||
local dificulty = dificulties[math.random(1, #dificulties)]
|
||||
local success = lib.skillCheck(dificulty)
|
||||
@@ -612,8 +647,8 @@ exports("keyControl", function(action, slot)
|
||||
if data.slot == slot then
|
||||
if metadata and not metadata.keyEnabled then
|
||||
return lib.notify({
|
||||
title = "No signal",
|
||||
description = "Vehicle key disabled.",
|
||||
title = locale("no_signal"),
|
||||
description = locale("veh_key_disabled"),
|
||||
type = "error",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
@@ -635,8 +670,8 @@ exports("keyControl", function(action, slot)
|
||||
elseif action == "disable" then
|
||||
TriggerServerEvent("ND_Vehicles:disableKey", slot)
|
||||
lib.notify({
|
||||
title = "Key disabled",
|
||||
description = "This vehicle key has been disabled and cannot be used anymore.",
|
||||
title = locale("veh_key_disabled"),
|
||||
description = locale("veh_key_disabled2"),
|
||||
type = "inform",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
@@ -648,8 +683,8 @@ local function cruiseControl()
|
||||
cruiseSpeedVehicle = GetEntitySpeed(playerVehicle) * 2.236936
|
||||
if not playerVehicle then
|
||||
lib.notify({
|
||||
title = "Cruise control",
|
||||
description = "Vehicle cruise control disabled.",
|
||||
title = locale("cruise_control"),
|
||||
description = locale("cruise_control_disabled"),
|
||||
type = "inform",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
@@ -658,8 +693,8 @@ local function cruiseControl()
|
||||
end
|
||||
if cruiseSpeedVehicle < cruiseSpeedSet/3 then
|
||||
lib.notify({
|
||||
title = "Cruise control",
|
||||
description = "Vehicle cruise control disabled.",
|
||||
title = locale("cruise_control"),
|
||||
description = locale("cruise_control_disabled"),
|
||||
type = "inform",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
@@ -674,14 +709,14 @@ end
|
||||
|
||||
lib.addKeybind({
|
||||
name = "vehicleCruiseControl",
|
||||
description = "Toggle vehicle cruise control",
|
||||
description = locale("cruise_control_toggle"),
|
||||
defaultKey = "",
|
||||
onPressed = function(self)
|
||||
if cruiseControlEnabled and cruiseSpeedVehicle-1 > cruiseSpeedSet then
|
||||
cruiseSpeedSet = cruiseSpeedVehicle
|
||||
return lib.notify({
|
||||
title = "Cruise control",
|
||||
description = ("Increased to %d mph."):format(math.floor(cruiseSpeedSet)),
|
||||
title = locale("cruise_control"),
|
||||
description = locale("cruise_control_increase"),
|
||||
type = "inform",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
@@ -689,20 +724,25 @@ lib.addKeybind({
|
||||
elseif cruiseControlEnabled then
|
||||
cruiseControlEnabled = false
|
||||
return lib.notify({
|
||||
title = "Cruise control",
|
||||
description = "Vehicle cruise control disabled.",
|
||||
title = locale("cruise_control"),
|
||||
description = locale("cruise_control_disabled"),
|
||||
type = "inform",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
})
|
||||
end
|
||||
if not playerVehicle then return end
|
||||
|
||||
local speed = math.floor(GetEntitySpeed(playerVehicle) * 2.236936)
|
||||
if speed < 10 then return end
|
||||
|
||||
cruiseControlEnabled = true
|
||||
cruiseSpeedVehicle = math.floor(GetEntitySpeed(playerVehicle) * 2.236936)
|
||||
cruiseSpeedVehicle = speed
|
||||
cruiseSpeedSet = cruiseSpeedVehicle
|
||||
|
||||
lib.notify({
|
||||
title = "Cruise control",
|
||||
description = ("Set to %d mph."):format(math.floor(cruiseSpeedSet)),
|
||||
title = locale("cruise_control"),
|
||||
description = locale("cruise_control_enabled"),
|
||||
type = "inform",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
@@ -716,7 +756,7 @@ lib.addKeybind({
|
||||
|
||||
lib.addKeybind({
|
||||
name = "vehicleShuffleSeat",
|
||||
description = "Suffle vehicle seat.",
|
||||
description = locale("seat_shuffle"),
|
||||
defaultKey = "",
|
||||
onPressed = function(self)
|
||||
if not cache.vehicle then return end
|
||||
|
||||
@@ -5,13 +5,32 @@ exports("GetCoreObject", function()
|
||||
end)
|
||||
|
||||
NDCore.Functions = {}
|
||||
NDCore.Functions.GetPlayer = NDCore.getPlayer
|
||||
NDCore.Functions.GetPlayers = NDCore.getPlayers
|
||||
NDCore.Functions.GetUserDiscordInfo = NDCore.getDiscordInfo
|
||||
NDCore.Functions.SetActiveCharacter = NDCore.setActiveCharacter
|
||||
NDCore.Functions.GetPlayerCharacters = NDCore.fetchAllCharacters
|
||||
NDCore.Functions.GetPlayerByCharacterId = NDCore.fetchCharacter
|
||||
|
||||
function NDCore.Functions.GetPlayer(src)
|
||||
local player = NDCore.getPlayer(src)
|
||||
return {
|
||||
source = player.source,
|
||||
id = player.id,
|
||||
firstName = player.firstname,
|
||||
lastName = player.lastname,
|
||||
dob = player.dob,
|
||||
gender = player.gender,
|
||||
cash = player.cash,
|
||||
bank = player.bank,
|
||||
phoneNumber = player.metadata.phone,
|
||||
lastLocation = player.metadata.lastLocation,
|
||||
inventory = player.inventory,
|
||||
discordInfo = player.discordInfo,
|
||||
data = player.metadata,
|
||||
job = player.job
|
||||
}
|
||||
end
|
||||
|
||||
function NDCore.Functions.GetPlayerIdentifierFromType(identifierType, src)
|
||||
return GetPlayerIdentifierByType(src, identifierType)
|
||||
end
|
||||
|
||||
@@ -60,7 +60,7 @@ function NDCore.GetPlayerData()
|
||||
|
||||
player.coords = GetEntityCoords(cache.ped)
|
||||
player.loadout = {}
|
||||
player.maxWeight = exports.ox_inventory:GetPlayerMaxWeight()
|
||||
player.maxWeight = GetResourceState("ox_inventory") == "started" and exports.ox_inventory:GetPlayerMaxWeight() or 0
|
||||
player.money = player.Accounts.Money
|
||||
player.sex = player.gender
|
||||
player.firstName = player.firstname
|
||||
@@ -112,7 +112,7 @@ function NDCore.Progressbar(message, lenght, options)
|
||||
end
|
||||
|
||||
function NDCore.SearchInventory(item, count)
|
||||
local itemCount = exports.ox_inventory:Search(item)
|
||||
local itemCount = GetResourceState("ox_inventory") == "started" and exports.ox_inventory:Search(item) or 0
|
||||
return itemCount >= count and itemCount
|
||||
end
|
||||
|
||||
@@ -133,7 +133,7 @@ function NDCore.ShowHelpNotification()
|
||||
end
|
||||
|
||||
function NDCore.ShowInventory()
|
||||
exports.ox_inventory:openInventory("player", cache.serverId)
|
||||
return GetResourceState("ox_inventory") == "started" and exports.ox_inventory:openInventory("player", cache.serverId)
|
||||
end
|
||||
|
||||
function NDCore.ShowNotification(msg, type, time)
|
||||
|
||||
@@ -5,7 +5,8 @@ local registeredItems = {}
|
||||
|
||||
local function getAmmoFromWeapon(weapon)
|
||||
if not weapon then return end
|
||||
for item, data in pairs(exports.ox_inventory:Items()) do
|
||||
local items = GetResourceState("ox_inventory") == "started" and exports.ox_inventory:Items() or {}
|
||||
for item, data in pairs(items) do
|
||||
if data.weapon and data.model and data.model:lower() == weapon:lower() then
|
||||
return data.ammoname
|
||||
end
|
||||
@@ -60,7 +61,7 @@ local function createPlayerFunctions(self)
|
||||
end
|
||||
|
||||
function self.addInventoryItem(item, count)
|
||||
exports.ox_inventory:AddItem(self.source, item, count)
|
||||
return GetResourceState("ox_inventory") == "started" and exports.ox_inventory:AddItem(self.source, item, count)
|
||||
end
|
||||
|
||||
function self.addMoney(amount)
|
||||
@@ -100,11 +101,11 @@ local function createPlayerFunctions(self)
|
||||
end
|
||||
|
||||
function self.canCarryItem(item, count)
|
||||
return exports.ox_inventory:CanCarryItem(self.source, item, count)
|
||||
return GetResourceState("ox_inventory") == "started" and exports.ox_inventory:CanCarryItem(self.source, item, count)
|
||||
end
|
||||
|
||||
function self.canSwapItem(firstItem, firstItemCount, testItem, testItemCount)
|
||||
exports.ox_inventory:CanSwapItem(self.source, firstItem, firstItemCount, testItem, testItemCount)
|
||||
return GetResourceState("ox_inventory") == "started" and exports.ox_inventory:CanSwapItem(self.source, firstItem, firstItemCount, testItem, testItemCount)
|
||||
end
|
||||
|
||||
function self.clearMeta(index)
|
||||
@@ -137,7 +138,7 @@ local function createPlayerFunctions(self)
|
||||
end
|
||||
|
||||
function self.getInventory(minimal)
|
||||
local playerItems = exports.ox_inventory:GetInventoryItems(self.source)
|
||||
local playerItems = GetResourceState("ox_inventory") == "started" and exports.ox_inventory:GetInventoryItems(self.source) or {}
|
||||
if not minimal then
|
||||
return playerItems
|
||||
end
|
||||
@@ -145,7 +146,7 @@ local function createPlayerFunctions(self)
|
||||
end
|
||||
|
||||
function self.getInventoryItem(item)
|
||||
local playerItems = exports.ox_inventory:GetInventoryItems(self.source)
|
||||
local playerItems = GetResourceState("ox_inventory") == "started" and exports.ox_inventory:GetInventoryItems(self.source) or {}
|
||||
for name, data in pairs(playerItems) do
|
||||
if name == item then
|
||||
return data
|
||||
@@ -162,11 +163,11 @@ local function createPlayerFunctions(self)
|
||||
end
|
||||
|
||||
function self.hasItem(item, metadata)
|
||||
return exports.ox_inventory:GetItem(self.source, item, metadata)
|
||||
return GetResourceState("ox_inventory") == "started" and exports.ox_inventory:GetItem(self.source, item, metadata)
|
||||
end
|
||||
|
||||
function self.removeInventoryItem(item, count)
|
||||
exports.ox_inventory:RemoveItem(self.source, item, count)
|
||||
return GetResourceState("ox_inventory") == "started" and exports.ox_inventory:RemoveItem(self.source, item, count)
|
||||
end
|
||||
|
||||
function self.removeMoney(amount)
|
||||
@@ -304,7 +305,8 @@ end
|
||||
function NDCore.GetItemLabel(item)
|
||||
if not itemNames then
|
||||
itemNames = {}
|
||||
for item, data in pairs(exports.ox_inventory:Items()) do
|
||||
local items = GetResourceState("ox_inventory") == "started" and exports.ox_inventory:Items() or {}
|
||||
for item, data in pairs(items) do
|
||||
itemNames[item] = data.label
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1,74 +0,0 @@
|
||||
-- For support join my discord: https://discord.gg/Z9Mxu72zZ6
|
||||
|
||||
config = {
|
||||
serverName = "Andy's Development",
|
||||
characterLimit = 15, -- How many characters can a player create.
|
||||
customPauseMenu = true, -- A custom pause menu will display your money, characters name and the server name in the pause menu.
|
||||
enablePVP = true, -- pvp allows doing damage to other players.
|
||||
|
||||
-- Money related
|
||||
startingCash = 2500, -- default cash the character will start with if the character creator doesn't specify it.
|
||||
startingBank = 8000,-- default money in the bank account the character will start with if the character creator doesn't specify it.
|
||||
|
||||
-- If you'd like to whitelist certain roles on discord then set this to true and add role ids.
|
||||
enableDiscordWhitelist = false,
|
||||
notWhitelistedMessage = "You're not allowlisted in this server please join our discord to apply for a allowlist: https://discord.gg/Z9Mxu72zZ6",
|
||||
whitelistRoles = {
|
||||
"872921520719142932"
|
||||
},
|
||||
|
||||
-- These are admins roles that will give a user permission to admin commands and more.
|
||||
adminRoles = {
|
||||
"872921520719142932"
|
||||
},
|
||||
|
||||
-- Discord Rich presence
|
||||
enableRichPresence = true,
|
||||
updateIntervall = 60, -- how many seconds of delay until it updates status.
|
||||
appId = 858146067018416128,
|
||||
largeLogo = "andyyy",
|
||||
smallLogo = "andyyy",
|
||||
firstButtonName = "DISCORD",
|
||||
firstButtonLink = "https://discord.gg/Z9Mxu72zZ6",
|
||||
secondButtonName = "TEBEX",
|
||||
secondButtonLink = "https://andyyy.tebex.io/category/fivem-scripts",
|
||||
|
||||
|
||||
-- Groups can be gangs, jobs, subdivisions, etc.
|
||||
groups = {
|
||||
["Ballas"] = {
|
||||
"Member", -- rank 1
|
||||
"Boss" -- rank 2
|
||||
},
|
||||
["SWAT"] = {
|
||||
"Member", -- rank 1
|
||||
"Sniper", -- rank 2
|
||||
"Team lead", -- rank 3
|
||||
"Commander" -- rank 4
|
||||
},
|
||||
["SAHP"] = {
|
||||
"Trooper",
|
||||
"Senior Trooper",
|
||||
"Corporal",
|
||||
"Sergeant",
|
||||
"Lieutenant",
|
||||
"Cheif"
|
||||
},
|
||||
["LSPD"] = {
|
||||
"Officer",
|
||||
"Senior officer",
|
||||
"Corporal",
|
||||
"Sergeant",
|
||||
"Lieutenant",
|
||||
"Cheif"
|
||||
},
|
||||
["BCSO"] = {
|
||||
"Deputy",
|
||||
"Senior Deputy",
|
||||
"Corporal",
|
||||
"Sergeant",
|
||||
"Lieutenant",
|
||||
"Cheif"
|
||||
}
|
||||
},
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
-- For support join my discord: https://discord.gg/Z9Mxu72zZ6
|
||||
|
||||
server_config = {
|
||||
discordServerToken = "OTAwODg1MDMxMDQ2Nzc0ODQ1.GU1TSC.Ed8D2_wcU-UQ1vZhe1khahgV8J3hLahOp4N1D8", -- discord bot token for permissions
|
||||
guildId = "872496972454592523", -- discord guild id
|
||||
}
|
||||
@@ -1,15 +1,16 @@
|
||||
CREATE TABLE IF NOT EXISTS `nd_characters` (
|
||||
`charid` INT(10) NOT NULL AUTO_INCREMENT,
|
||||
`identifier` VARCHAR(200) NOT NULL DEFAULT '0',
|
||||
`name` VARCHAR(50) DEFAULT NULL,
|
||||
`firstname` VARCHAR(50) DEFAULT NULL,
|
||||
`lastname` VARCHAR(50) DEFAULT NULL,
|
||||
`dob` VARCHAR(50) DEFAULT NULL,
|
||||
`gender` VARCHAR(50) DEFAULT NULL,
|
||||
`cash` INT(10) DEFAULT '0',
|
||||
`bank` INT(10) DEFAULT '0',
|
||||
`groups` LONGTEXT DEFAULT '[]',
|
||||
`metadata` LONGTEXT DEFAULT '[]',
|
||||
`inventory` LONGTEXT DEFAULT '[]',
|
||||
PRIMARY KEY (`charid`) USING BTREE
|
||||
`charid` INT(10) NOT NULL AUTO_INCREMENT,
|
||||
`identifier` VARCHAR(200) NOT NULL DEFAULT '0',
|
||||
`name` VARCHAR(50) DEFAULT NULL,
|
||||
`firstname` VARCHAR(50) DEFAULT NULL,
|
||||
`lastname` VARCHAR(50) DEFAULT NULL,
|
||||
`dob` VARCHAR(50) DEFAULT NULL,
|
||||
`gender` VARCHAR(50) DEFAULT NULL,
|
||||
`cash` INT(10) DEFAULT '0',
|
||||
`bank` INT(10) DEFAULT '0',
|
||||
`phonenumber` VARCHAR(20) DEFAULT NULL,
|
||||
`groups` LONGTEXT DEFAULT ('[]'),
|
||||
`metadata` LONGTEXT DEFAULT ('[]'),
|
||||
`inventory` LONGTEXT DEFAULT ('[]'),
|
||||
PRIMARY KEY (`charid`) USING BTREE
|
||||
);
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
CREATE TABLE IF NOT EXISTS `nd_vehicles` (
|
||||
`id` INT(11) NOT NULL AUTO_INCREMENT,
|
||||
`owner` INT(11) DEFAULT NULL,
|
||||
`plate` VARCHAR(255) DEFAULT NULL,
|
||||
`glovebox` LONGTEXT DEFAULT '[]',
|
||||
`trunk` LONGTEXT DEFAULT '[]',
|
||||
`properties` LONGTEXT DEFAULT '[]',
|
||||
`id` INT(11) NOT NULL AUTO_INCREMENT,
|
||||
`owner` INT(11) DEFAULT NULL,
|
||||
`plate` VARCHAR(255) DEFAULT NULL,
|
||||
`glovebox` LONGTEXT DEFAULT ('[]'),
|
||||
`trunk` LONGTEXT DEFAULT ('[]'),
|
||||
`properties` LONGTEXT DEFAULT ('[]'),
|
||||
`stored` INT(11) DEFAULT '1',
|
||||
`impounded` INT(11) DEFAULT '0',
|
||||
`stolen` INT(11) DEFAULT '0',
|
||||
`metadata` LONGTEXT DEFAULT '[]',
|
||||
PRIMARY KEY (`id`) USING BTREE,
|
||||
INDEX `owner` (`owner`) USING BTREE,
|
||||
CONSTRAINT `vehowner` FOREIGN KEY (`owner`) REFERENCES `nd_characters` (`charid`) ON UPDATE CASCADE ON DELETE CASCADE
|
||||
`impounded` INT(11) DEFAULT '0',
|
||||
`stolen` INT(11) DEFAULT '0',
|
||||
`metadata` LONGTEXT DEFAULT ('[]'),
|
||||
PRIMARY KEY (`id`) USING BTREE,
|
||||
INDEX `owner` (`owner`) USING BTREE,
|
||||
CONSTRAINT `vehowner` FOREIGN KEY (`owner`) REFERENCES `nd_characters` (`charid`) ON UPDATE CASCADE ON DELETE CASCADE
|
||||
);
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
author "Andyyy#7666"
|
||||
description "ND Framework Core"
|
||||
version "2.0.0"
|
||||
version "2.3.2"
|
||||
|
||||
fx_version "cerulean"
|
||||
game "gta5"
|
||||
@@ -34,9 +34,15 @@ server_scripts {
|
||||
files {
|
||||
"init.lua",
|
||||
"client/vehicle/data.lua",
|
||||
"compatibility/**/locale.lua"
|
||||
"compatibility/**/locale.lua",
|
||||
"locales/*.json"
|
||||
}
|
||||
|
||||
dependency "oxmysql"
|
||||
dependencies {
|
||||
"ox_lib",
|
||||
"oxmysql"
|
||||
}
|
||||
|
||||
-- below were used with backwards compatibility but could interfere with resources checking if the resources are started.
|
||||
-- provide "es_extended"
|
||||
-- provide "qb-Core"
|
||||
|
||||
2
init.lua
2
init.lua
@@ -9,3 +9,5 @@ NDCore = setmetatable({}, {
|
||||
return self[index]
|
||||
end
|
||||
})
|
||||
|
||||
return NDCore
|
||||
|
||||
134
locales/ar.json
Normal file
134
locales/ar.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "لم يتم العثور على حساب ديسكورد الخاص بك، انضم إلى ديسكورد هنا: %s.",
|
||||
"connecting": "جارٍ الاتصال...",
|
||||
"identifier_not_found": "لم يتم العثور على %s الخاص بك.",
|
||||
"deposit": "إيداع",
|
||||
"withdraw": "سحب",
|
||||
"vehicle_ownership_transfered": "تم نقل الملكية",
|
||||
"vehicle_ownership_transfered2": "تم نقل ملكية المركبة %s.",
|
||||
"vehicle_ownership_received": "تم استلام الملكية",
|
||||
"vehicle_ownership_received2": "تم استلام ملكية المركبة %s.",
|
||||
"keys_shared": "تمت مشاركة المفاتيح",
|
||||
"keys_shared2": "لقد شاركت مفاتيح المركبة مع %s.",
|
||||
"keys_received": "تم استلام المفاتيح",
|
||||
"keys_received2": "لقد استلمت مفاتيح المركبة من %s.",
|
||||
"no_signal": "لا يوجد إشارة",
|
||||
"veh_key_disabled": "تم تعطيل مفتاح المركبة.",
|
||||
"veh_key_disabled2": "تم تعطيل هذا المفتاح ولا يمكن استخدامه بعد الآن.",
|
||||
"veh_far_away": "المركبة بعيدة جدًا.",
|
||||
"veh_locked": "مقفول",
|
||||
"veh_locked2": "تم قفل مركبتك الآن.",
|
||||
"veh_unlocked": "مفتوح",
|
||||
"veh_unlocked2": "تم فتح مركبتك الآن.",
|
||||
"garage": "كراج",
|
||||
"no_owned_veh_nearby": "لم يتم العثور على مركبة مملوكة بالقرب منك.",
|
||||
"veh_stored_in_garage": "تم تخزين المركبة في الكراج.",
|
||||
"impound_reclaim": "استعادة المركبة من الحجز",
|
||||
"impound": "حجز",
|
||||
"impound_not_enough": "سعر الاستعادة هو $%d، ليس لديك ما يكفي!",
|
||||
"impound_paid": "تم دفع $%d لاستعادة المركبة!",
|
||||
"success": "نجاح",
|
||||
"staff_action": "إجراء من الموظفين",
|
||||
"staff_money_removed": "تم إزالة $%d (%s) من %s",
|
||||
"user_money_removed": "تمت إزالة $%d من %s",
|
||||
"staff_money_added": "تمت إضافة $%d (%s) إلى %s",
|
||||
"user_money_added": "تمت إضافة $%d إلى %s",
|
||||
"staff_money_set": "تم ضبط %s (%s) على $%d",
|
||||
"user_money_set": "تم ضبط %s على $%d",
|
||||
"job_updated_noti": "تم تحديث الوظيفة إلى %s، الرتبة %s.",
|
||||
"group_added_noti": "تمت إضافتك إلى مجموعة %s، الرتبة %s.",
|
||||
"group_removed_noti": "تمت إزالتك من مجموعة %s.",
|
||||
"no_player_found": "لم يتم العثور على لاعب",
|
||||
"not_enough_cash": "ليس لديك ما يكفي من النقود",
|
||||
"player_not_nearby": "اللاعب ليس بالقرب منك",
|
||||
"cant_give_money": "تعذر إعطاء المال",
|
||||
"money_received": "تم استلام المال",
|
||||
"money_received2": "تم استلام $%d نقدًا",
|
||||
"money_given": "تم إعطاء المال",
|
||||
"money_given2": "لقد أعطيت $%d نقدًا",
|
||||
"player_in_veh": "اللاعب داخل المركبة!",
|
||||
"perfect": "ممتاز",
|
||||
"good": "جيد",
|
||||
"bad": "سيء",
|
||||
"very_bad": "سيء جدًا",
|
||||
"veh_make_brand": "الصانع",
|
||||
"veh_model": "الطراز",
|
||||
"veh_plate": "اللوحة",
|
||||
"engine_status": "حالة المحرك",
|
||||
"vehicle": "مركبة",
|
||||
"not_found": "غير موجود",
|
||||
"park_veh": "ركن المركبة",
|
||||
"no_vehs_found": "لم يتم العثور على مركبات",
|
||||
"vehicle_impound": "حجز المركبة",
|
||||
"parking_garage": "كراج سيارات",
|
||||
"impound_w_location": "الحجز (%s)",
|
||||
"garage_w_location": "كراج السيارات (%s)",
|
||||
"view_impounded_vehs": "عرض المركبات المحجوزة",
|
||||
"view_garage": "عرض الكراج",
|
||||
"personal_vehicle": "مركبة شخصية",
|
||||
"keybind_carkey": "فتح/قفل المركبة (نقر مزدوج)",
|
||||
"progress_hotwiring": "تشغيل المركبة بدون مفتاح",
|
||||
"cruise_control": "التحكم بالسرعة",
|
||||
"cruise_control_enabled": "تم تفعيل التحكم بالسرعة",
|
||||
"cruise_control_disabled": "تم تعطيل التحكم بالسرعة",
|
||||
"cruise_control_toggle": "تبديل التحكم بالسرعة",
|
||||
"cruise_control_increase": "زيادة سرعة التحكم",
|
||||
"seat_shuffle": "تبديل مقعد المركبة",
|
||||
"discord_text": "تلعب: %s كـ %s %s",
|
||||
"discord_text_small": "تلعب كـ: %s %s",
|
||||
"discord_text_server": "تلعب: %s",
|
||||
"pause_menu_cash": "نقد: $%d",
|
||||
"pause_menu_bank": "البنك: $%d",
|
||||
"veh_color_black": "أسود",
|
||||
"veh_color_silver": "فضي",
|
||||
"veh_color_grey": "رمادي",
|
||||
"veh_color_metal": "معدني",
|
||||
"veh_color_graphite": "جرافيت",
|
||||
"veh_color_red": "أحمر",
|
||||
"veh_color_orange": "برتقالي",
|
||||
"veh_color_gold": "ذهبي",
|
||||
"veh_color_yellow": "أصفر",
|
||||
"veh_color_green": "أخضر",
|
||||
"veh_color_blue": "أزرق",
|
||||
"veh_color_bblue": "أزرق فاتح",
|
||||
"veh_color_bronze": "برونزي",
|
||||
"veh_color_lime": "ليموني",
|
||||
"veh_color_champagne": "شامبانيا",
|
||||
"veh_color_beige": "بيج",
|
||||
"veh_color_ivory": "عاجي",
|
||||
"veh_color_brown": "بني",
|
||||
"veh_color_beechwood": "خشب الزان",
|
||||
"veh_color_sand": "رملي",
|
||||
"veh_color_cream": "كريمي",
|
||||
"veh_color_white": "أبيض",
|
||||
"veh_color_steel": "فولاذي",
|
||||
"veh_color_aluminium": "ألمنيوم",
|
||||
"veh_color_chrome": "كروم",
|
||||
"veh_color_pink": "وردي",
|
||||
"veh_color_purple": "بنفسجي",
|
||||
"veh_color_tan": "قمحي",
|
||||
"veh_color_alloy": "سبيكة",
|
||||
"veh_class_compact": "مدمجة",
|
||||
"veh_class_sedan": "سيدان",
|
||||
"veh_class_suv": "دفع رباعي",
|
||||
"veh_class_coupe": "كوبيه",
|
||||
"veh_class_muscle": "عضلية",
|
||||
"veh_class_sports_classic": "رياضية كلاسيكية",
|
||||
"veh_class_sport": "رياضية",
|
||||
"veh_class_super": "سوبر",
|
||||
"veh_class_motorcycle": "دراجة نارية",
|
||||
"veh_class_off_road": "طرق وعرة",
|
||||
"veh_class_industrial": "صناعية",
|
||||
"veh_class_utility": "خدمية",
|
||||
"veh_class_van": "فان",
|
||||
"veh_class_cycle": "دراجة",
|
||||
"veh_class_boat": "قارب",
|
||||
"veh_class_helicopter": "مروحية",
|
||||
"veh_class_plane": "طائرة",
|
||||
"veh_class_service": "خدمة",
|
||||
"veh_class_emergency": "طوارئ",
|
||||
"veh_class_military": "عسكرية",
|
||||
"veh_class_commercial": "تجارية",
|
||||
"veh_class_train": "قطار",
|
||||
"veh_class_open_wheel": "مفتوح العجلات"
|
||||
}
|
||||
134
locales/da.json
Normal file
134
locales/da.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "Din Discord blev ikke fundet, deltag i vores Discord her: %s.",
|
||||
"connecting": "Forbinder...",
|
||||
"identifier_not_found": "Din %s blev ikke fundet.",
|
||||
"deposit": "Indsæt",
|
||||
"withdraw": "Hæv",
|
||||
"vehicle_ownership_transfered": "Ejerskab overført",
|
||||
"vehicle_ownership_transfered2": "Ejerskab af køretøj %s er blevet overført.",
|
||||
"vehicle_ownership_received": "Ejerskab modtaget",
|
||||
"vehicle_ownership_received2": "Modtog ejerskab af køretøj %s.",
|
||||
"keys_shared": "Nøgler delt",
|
||||
"keys_shared2": "Du har delt bilnøgler med %s.",
|
||||
"keys_received": "Nøgler modtaget",
|
||||
"keys_received2": "Du har modtaget bilnøgler fra %s.",
|
||||
"no_signal": "Ingen signal",
|
||||
"veh_key_disabled": "Bilnøgle deaktiveret.",
|
||||
"veh_key_disabled2": "Denne bilnøgle er blevet deaktiveret og kan ikke bruges længere.",
|
||||
"veh_far_away": "Køretøj for langt væk.",
|
||||
"veh_locked": "LÅST",
|
||||
"veh_locked2": "Dit køretøj er nu låst.",
|
||||
"veh_unlocked": "ULÅST",
|
||||
"veh_unlocked2": "Dit køretøj er nu ulåst.",
|
||||
"garage": "Garage",
|
||||
"no_owned_veh_nearby": "Ingen ejet køretøj fundet i nærheden.",
|
||||
"veh_stored_in_garage": "Køretøj gemt i garage.",
|
||||
"impound_reclaim": "Hent køretøj fra beslaglæggelse",
|
||||
"impound": "Beslaglæggelse",
|
||||
"impound_not_enough": "Prisen for at hente er %d kr, du har ikke nok!",
|
||||
"impound_paid": "Betalt %d kr for at hente køretøj!",
|
||||
"success": "succes",
|
||||
"staff_action": "Personalehandling",
|
||||
"staff_money_removed": "Fjernede %d kr (%s) fra %s",
|
||||
"user_money_removed": "fjernede %d kr fra %s",
|
||||
"staff_money_added": "Tilføjede %d kr (%s) til %s",
|
||||
"user_money_added": "tilføjede %d kr til %s",
|
||||
"staff_money_set": "Satte %s's (%s) til %d kr",
|
||||
"user_money_set": "satte %s til %d kr",
|
||||
"job_updated_noti": "Job opdateret til %s, rang %s.",
|
||||
"group_added_noti": "Tilføjet til gruppe %s, rang %s.",
|
||||
"group_removed_noti": "Fjernet fra gruppe %s.",
|
||||
"no_player_found": "Ingen spiller fundet",
|
||||
"not_enough_cash": "Du har ikke nok kontanter",
|
||||
"player_not_nearby": "Spiller ikke i nærheden",
|
||||
"cant_give_money": "Kunne ikke give penge",
|
||||
"money_received": "Penge modtaget",
|
||||
"money_received2": "Modtog %d kr i kontanter",
|
||||
"money_given": "Penge givet",
|
||||
"money_given2": "Du gav %d kr i kontanter",
|
||||
"player_in_veh": "Spiller i køretøj!",
|
||||
"perfect": "Perfekt",
|
||||
"good": "God",
|
||||
"bad": "Dårlig",
|
||||
"very_bad": "Meget dårlig",
|
||||
"veh_make_brand": "Mærke",
|
||||
"veh_model": "Model",
|
||||
"veh_plate": "Nummerplade",
|
||||
"engine_status": "Motorstatus",
|
||||
"vehicle": "Køretøj",
|
||||
"not_found": "ikke fundet",
|
||||
"park_veh": "Parkér køretøj",
|
||||
"no_vehs_found": "Ingen køretøjer fundet",
|
||||
"vehicle_impound": "Køretøj beslaglagt",
|
||||
"parking_garage": "Parkeringsgarage",
|
||||
"impound_w_location": "Beslaglæggelse (%s)",
|
||||
"garage_w_location": "Parkeringsgarage (%s)",
|
||||
"view_impounded_vehs": "Se beslaglagte køretøjer",
|
||||
"view_garage": "Se garage",
|
||||
"personal_vehicle": "Personligt køretøj",
|
||||
"keybind_carkey": "Lås/lås op for køretøj (dobbeltklik)",
|
||||
"progress_hotwiring": "Koble tænding",
|
||||
"cruise_control": "Fartpilot",
|
||||
"cruise_control_enabled": "Fartpilot aktiveret",
|
||||
"cruise_control_disabled": "Fartpilot deaktiveret",
|
||||
"cruise_control_toggle": "Skift fartpilot",
|
||||
"cruise_control_increase": "Øget fartpilot hastighed",
|
||||
"seat_shuffle": "Skift sæde",
|
||||
"discord_text": "Spiller: %s som %s %s",
|
||||
"discord_text_small": "Spiller som: %s %s",
|
||||
"discord_text_server": "Spiller: %s",
|
||||
"pause_menu_cash": "Kontanter: %d",
|
||||
"pause_menu_bank": "Bank: %d",
|
||||
"veh_color_black": "Sort",
|
||||
"veh_color_silver": "Sølv",
|
||||
"veh_color_grey": "Grå",
|
||||
"veh_color_metal": "Metal",
|
||||
"veh_color_graphite": "Grafit",
|
||||
"veh_color_red": "Rød",
|
||||
"veh_color_orange": "Orange",
|
||||
"veh_color_gold": "Guld",
|
||||
"veh_color_yellow": "Gul",
|
||||
"veh_color_green": "Grøn",
|
||||
"veh_color_blue": "Blå",
|
||||
"veh_color_bblue": "Lyseblå",
|
||||
"veh_color_bronze": "Bronze",
|
||||
"veh_color_lime": "Lime",
|
||||
"veh_color_champagne": "Champagne",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Elfenben",
|
||||
"veh_color_brown": "Brun",
|
||||
"veh_color_beechwood": "Bøgetræ",
|
||||
"veh_color_sand": "Sand",
|
||||
"veh_color_cream": "Creme",
|
||||
"veh_color_white": "Hvid",
|
||||
"veh_color_steel": "Stål",
|
||||
"veh_color_aluminium": "Aluminium",
|
||||
"veh_color_chrome": "Krom",
|
||||
"veh_color_pink": "Pink",
|
||||
"veh_color_purple": "Lilla",
|
||||
"veh_color_tan": "Tan",
|
||||
"veh_color_alloy": "Legering",
|
||||
"veh_class_compact": "Kompakt",
|
||||
"veh_class_sedan": "Sedan",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupé",
|
||||
"veh_class_muscle": "Muskelbil",
|
||||
"veh_class_sports_classic": "Klassisk sportsvogn",
|
||||
"veh_class_sport": "Sport",
|
||||
"veh_class_super": "Superbil",
|
||||
"veh_class_motorcycle": "Motorcykel",
|
||||
"veh_class_off_road": "Off-road",
|
||||
"veh_class_industrial": "Industriel",
|
||||
"veh_class_utility": "Utility",
|
||||
"veh_class_van": "Varevogn",
|
||||
"veh_class_cycle": "Cykel",
|
||||
"veh_class_boat": "Båd",
|
||||
"veh_class_helicopter": "Helikopter",
|
||||
"veh_class_plane": "Fly",
|
||||
"veh_class_service": "Service",
|
||||
"veh_class_emergency": "Nød",
|
||||
"veh_class_military": "Militær",
|
||||
"veh_class_commercial": "Kommerciel",
|
||||
"veh_class_train": "Tog",
|
||||
"veh_class_open_wheel": "Åben hjul"
|
||||
}
|
||||
134
locales/de.json
Normal file
134
locales/de.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "Dein Discord wurde nicht gefunden, trete unserem Discord hier bei: %s.",
|
||||
"connecting": "Verbinde...",
|
||||
"identifier_not_found": "Dein %s wurde nicht gefunden.",
|
||||
"deposit": "Einzahlen",
|
||||
"withdraw": "Abheben",
|
||||
"vehicle_ownership_transfered": "Besitz übertragen",
|
||||
"vehicle_ownership_transfered2": "Fahrzeugbesitz von %s wurde übertragen.",
|
||||
"vehicle_ownership_received": "Besitz erhalten",
|
||||
"vehicle_ownership_received2": "Fahrzeugbesitz von %s erhalten.",
|
||||
"keys_shared": "Schlüssel geteilt",
|
||||
"keys_shared2": "Du hast die Fahrzeugschlüssel an %s gegeben.",
|
||||
"keys_received": "Schlüssel erhalten",
|
||||
"keys_received2": "Du hast die Fahrzeugschlüssel von %s erhalten.",
|
||||
"no_signal": "Kein Signal",
|
||||
"veh_key_disabled": "Fahrzeugschlüssel deaktiviert.",
|
||||
"veh_key_disabled2": "Dieser Fahrzeugschlüssel wurde deaktiviert und kann nicht mehr verwendet werden.",
|
||||
"veh_far_away": "Fahrzeug zu weit entfernt.",
|
||||
"veh_locked": "GESCHLOSSEN",
|
||||
"veh_locked2": "Dein Fahrzeug ist jetzt abgeschlossen.",
|
||||
"veh_unlocked": "GEÖFFNET",
|
||||
"veh_unlocked2": "Dein Fahrzeug ist jetzt geöffnet.",
|
||||
"garage": "Garage",
|
||||
"no_owned_veh_nearby": "Kein eigenes Fahrzeug in der Nähe gefunden.",
|
||||
"veh_stored_in_garage": "Fahrzeug in Garage gespeichert.",
|
||||
"impound_reclaim": "Fahrzeug aus dem Abschlepphof zurückholen",
|
||||
"impound": "Abschlepphof",
|
||||
"impound_not_enough": "Der Preis zur Rückholung beträgt %d €, du hast nicht genug!",
|
||||
"impound_paid": "%d € bezahlt, um das Fahrzeug zurückzuholen!",
|
||||
"success": "Erfolg",
|
||||
"staff_action": "Mitarbeiteraktion",
|
||||
"staff_money_removed": "%d € (%s) von %s entfernt",
|
||||
"user_money_removed": "%d € von %s entfernt",
|
||||
"staff_money_added": "%d € (%s) zu %s hinzugefügt",
|
||||
"user_money_added": "%d € zu %s hinzugefügt",
|
||||
"staff_money_set": "%s's (%s) auf %d € gesetzt",
|
||||
"user_money_set": "%s auf %d € gesetzt",
|
||||
"job_updated_noti": "Job auf %s, Rang %s aktualisiert.",
|
||||
"group_added_noti": "Zur Gruppe %s, Rang %s hinzugefügt.",
|
||||
"group_removed_noti": "Aus der Gruppe %s entfernt.",
|
||||
"no_player_found": "Kein Spieler gefunden",
|
||||
"not_enough_cash": "Du hast nicht genug Bargeld",
|
||||
"player_not_nearby": "Spieler nicht in der Nähe",
|
||||
"cant_give_money": "Konnte kein Geld geben",
|
||||
"money_received": "Geld erhalten",
|
||||
"money_received2": "%d € in bar erhalten",
|
||||
"money_given": "Geld gegeben",
|
||||
"money_given2": "Du hast %d € in bar gegeben",
|
||||
"player_in_veh": "Spieler im Fahrzeug!",
|
||||
"perfect": "Perfekt",
|
||||
"good": "Gut",
|
||||
"bad": "Schlecht",
|
||||
"very_bad": "Sehr schlecht",
|
||||
"veh_make_brand": "Marke",
|
||||
"veh_model": "Modell",
|
||||
"veh_plate": "Kennzeichen",
|
||||
"engine_status": "Motorstatus",
|
||||
"vehicle": "Fahrzeug",
|
||||
"not_found": "nicht gefunden",
|
||||
"park_veh": "Fahrzeug parken",
|
||||
"no_vehs_found": "Keine Fahrzeuge gefunden",
|
||||
"vehicle_impound": "Fahrzeugabschlepphof",
|
||||
"parking_garage": "Parkgarage",
|
||||
"impound_w_location": "Abschlepphof (%s)",
|
||||
"garage_w_location": "Parkgarage (%s)",
|
||||
"view_impounded_vehs": "Abgeschleppte Fahrzeuge anzeigen",
|
||||
"view_garage": "Garage anzeigen",
|
||||
"personal_vehicle": "Privatfahrzeug",
|
||||
"keybind_carkey": "Fahrzeug auf-/zusperren (Doppelklick)",
|
||||
"progress_hotwiring": "Kurzschließen",
|
||||
"cruise_control": "Tempomat",
|
||||
"cruise_control_enabled": "Tempomat aktiviert",
|
||||
"cruise_control_disabled": "Tempomat deaktiviert",
|
||||
"cruise_control_toggle": "Tempomat umschalten",
|
||||
"cruise_control_increase": "Tempomatgeschwindigkeit erhöht",
|
||||
"seat_shuffle": "Sitz wechseln",
|
||||
"discord_text": "Spielt: %s als %s %s",
|
||||
"discord_text_small": "Spielt als: %s %s",
|
||||
"discord_text_server": "Spielt: %s",
|
||||
"pause_menu_cash": "Bargeld: €%d",
|
||||
"pause_menu_bank": "Bank: €%d",
|
||||
"veh_color_black": "Schwarz",
|
||||
"veh_color_silver": "Silber",
|
||||
"veh_color_grey": "Grau",
|
||||
"veh_color_metal": "Metall",
|
||||
"veh_color_graphite": "Graphit",
|
||||
"veh_color_red": "Rot",
|
||||
"veh_color_orange": "Orange",
|
||||
"veh_color_gold": "Gold",
|
||||
"veh_color_yellow": "Gelb",
|
||||
"veh_color_green": "Grün",
|
||||
"veh_color_blue": "Blau",
|
||||
"veh_color_bblue": "Hellblau",
|
||||
"veh_color_bronze": "Bronze",
|
||||
"veh_color_lime": "Limette",
|
||||
"veh_color_champagne": "Champagner",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Elfenbein",
|
||||
"veh_color_brown": "Braun",
|
||||
"veh_color_beechwood": "Buchenholz",
|
||||
"veh_color_sand": "Sand",
|
||||
"veh_color_cream": "Creme",
|
||||
"veh_color_white": "Weiß",
|
||||
"veh_color_steel": "Stahl",
|
||||
"veh_color_aluminium": "Aluminium",
|
||||
"veh_color_chrome": "Chrom",
|
||||
"veh_color_pink": "Pink",
|
||||
"veh_color_purple": "Lila",
|
||||
"veh_color_tan": "Hellbraun",
|
||||
"veh_color_alloy": "Legierung",
|
||||
"veh_class_compact": "Kompakt",
|
||||
"veh_class_sedan": "Limousine",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupé",
|
||||
"veh_class_muscle": "Muscle-Car",
|
||||
"veh_class_sports_classic": "Klassischer Sportwagen",
|
||||
"veh_class_sport": "Sportwagen",
|
||||
"veh_class_super": "Supersportwagen",
|
||||
"veh_class_motorcycle": "Motorrad",
|
||||
"veh_class_off_road": "Geländewagen",
|
||||
"veh_class_industrial": "Industriefahrzeug",
|
||||
"veh_class_utility": "Nutzfahrzeug",
|
||||
"veh_class_van": "Van",
|
||||
"veh_class_cycle": "Fahrrad",
|
||||
"veh_class_boat": "Boot",
|
||||
"veh_class_helicopter": "Hubschrauber",
|
||||
"veh_class_plane": "Flugzeug",
|
||||
"veh_class_service": "Service",
|
||||
"veh_class_emergency": "Notfall",
|
||||
"veh_class_military": "Militär",
|
||||
"veh_class_commercial": "Gewerblich",
|
||||
"veh_class_train": "Zug",
|
||||
"veh_class_open_wheel": "Offenes Rad"
|
||||
}
|
||||
135
locales/en.json
Normal file
135
locales/en.json
Normal file
@@ -0,0 +1,135 @@
|
||||
{
|
||||
"not_in_discord": "Your discord was not found, join our discord here: %s.",
|
||||
"connecting": "Connecting...",
|
||||
"identifier_not_found": "Your %s was not found.",
|
||||
"deposit": "Deposit",
|
||||
"withdraw": "Withdraw",
|
||||
"vehicle_ownership_transfered": "Ownership transfered",
|
||||
"vehicle_ownership_transfered2": "Vehicle ownership of %s has been transfered.",
|
||||
"vehicle_ownership_received": "Ownership received",
|
||||
"vehicle_ownership_received2": "Received vehicle ownership of %s.",
|
||||
"keys_shared": "Keys shared",
|
||||
"keys_shared2": "You've shared vehicle keys to %s.",
|
||||
"keys_received": "Keys received",
|
||||
"keys_received2": "You've shared vehicle keys to %s.",
|
||||
"no_signal": "No signal",
|
||||
"veh_key_disabled": "Vehicle key disabled.",
|
||||
"veh_key_disabled2": "This vehicle key has been disabled and cannot be used anymore.",
|
||||
"veh_far_away": "Vehicle to far away.",
|
||||
"veh_locked": "LOCKED",
|
||||
"veh_locked2": "Your vehicle has now been locked.",
|
||||
"veh_unlocked": "UNLOCKED",
|
||||
"veh_unlocked2": "Your vehicle has now been unlocked.",
|
||||
"garage": "Garage",
|
||||
"no_owned_veh_nearby": "No owned vehicle found nearby.",
|
||||
"veh_stored_in_garage": "Vehicle stored in garage.",
|
||||
"impound_reclaim": "Vehicle impound reclaim",
|
||||
"impound": "Impound",
|
||||
"impound_not_enough": "Price to reclaim is $%d, you don't have enough!",
|
||||
"impound_paid": "Paid $%d to reclaim vehicle!",
|
||||
"success": "success",
|
||||
"staff_action": "Staff action",
|
||||
"staff_money_removed": "Removed $%d (%s) from %s",
|
||||
"user_money_removed": "removed $%d from %s",
|
||||
"staff_money_added": "Added $%d (%s) to %s",
|
||||
"user_money_added": "added $%d to %s",
|
||||
"staff_money_set": "Set %s's (%s) to $%d",
|
||||
"user_money_set": "set %s to $%d",
|
||||
"job_updated_noti": "Job updated to %s, rank %s.",
|
||||
"group_added_noti": "Added to group %s, rank %s.",
|
||||
"group_removed_noti": "Removed from group %s.",
|
||||
"no_player_found": "No player found",
|
||||
"not_enough_cash": "You don't have enough cash",
|
||||
"player_not_nearby": "Player is not nearby",
|
||||
"cant_give_money": "Couldn't give money",
|
||||
"money_received": "Money received",
|
||||
"money_received2": "Received $%d in cash",
|
||||
"money_given": "Money given",
|
||||
"money_given2": "You gave $%d in cash",
|
||||
"player_in_veh": "Player in vehicle!",
|
||||
"perfect": "Perfect",
|
||||
"good": "Good",
|
||||
"bad": "Bad",
|
||||
"very_bad": "Very bad",
|
||||
"veh_make_brand": "Make",
|
||||
"veh_model": "Model",
|
||||
"veh_plate": "Plate",
|
||||
"engine_status": "Engine status",
|
||||
"vehicle": "Vehicle",
|
||||
"not_found": "not found",
|
||||
"park_veh": "Park vehicle",
|
||||
"no_vehs_found": "No vehicles found",
|
||||
"vehicle_impound": "Vehicle impound",
|
||||
"parking_garage": "Parking garage",
|
||||
"impound_w_location": "Impound (%s)",
|
||||
"garage_w_location": "Parking garage (%s)",
|
||||
"view_impounded_vehs": "View impounded vehicles",
|
||||
"view_garage": "View garage",
|
||||
"personal_vehicle": "Personal vehicle",
|
||||
"keybind_carkey": "Unlock/lock vehicle (double click)",
|
||||
"progress_hotwiring": "Hotwiring",
|
||||
"cruise_control": "Cruise control",
|
||||
"cruise_control_enabled": "Vehicle cruise control enabled",
|
||||
"cruise_control_disabled": "Vehicle cruise control disabled",
|
||||
"cruise_control_toggle": "Toggle vehicle cruise control",
|
||||
"cruise_control_increase": "Increased cruise control speed",
|
||||
"seat_shuffle": "Shuffle vehicle seat",
|
||||
"discord_text": "Playing: %s as %s %s",
|
||||
"discord_text_small": "Playing as: %s %s",
|
||||
"discord_text_server": "Playing: %s",
|
||||
"pause_menu_cash": "Cash: $%d",
|
||||
"pause_menu_bank": "Bank: $%d",
|
||||
|
||||
"veh_color_black": "Black",
|
||||
"veh_color_silver": "Silver",
|
||||
"veh_color_grey": "Grey",
|
||||
"veh_color_metal": "Metal",
|
||||
"veh_color_graphite": "Graphite",
|
||||
"veh_color_red": "Red",
|
||||
"veh_color_orange": "Orange",
|
||||
"veh_color_gold": "Gold",
|
||||
"veh_color_yellow": "Yellow",
|
||||
"veh_color_green": "Green",
|
||||
"veh_color_blue": "Blue",
|
||||
"veh_color_bblue": "Bblue",
|
||||
"veh_color_bronze": "Bronze",
|
||||
"veh_color_lime": "Lime",
|
||||
"veh_color_champagne": "Champagne",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Ivory",
|
||||
"veh_color_brown": "Brown",
|
||||
"veh_color_beechwood": "Beechwood",
|
||||
"veh_color_sand": "Sand",
|
||||
"veh_color_cream": "Cream",
|
||||
"veh_color_white": "White",
|
||||
"veh_color_steel": "Steel",
|
||||
"veh_color_aluminium": "Aluminium",
|
||||
"veh_color_chrome": "Chrome",
|
||||
"veh_color_pink": "Pink",
|
||||
"veh_color_purple": "Purple",
|
||||
"veh_color_tan": "Tan",
|
||||
"veh_color_alloy": "Alloy",
|
||||
"veh_class_compact": "Compact",
|
||||
"veh_class_sedan": "Sedan",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupe",
|
||||
"veh_class_muscle": "Muscle",
|
||||
"veh_class_sports_classic": "Sports Classic",
|
||||
"veh_class_sport": "Sport",
|
||||
"veh_class_super": "Super",
|
||||
"veh_class_motorcycle": "Motorcycle",
|
||||
"veh_class_off_road": "Off-road",
|
||||
"veh_class_industrial": "Industrial",
|
||||
"veh_class_utility": "Utility",
|
||||
"veh_class_van": "Van",
|
||||
"veh_class_cycle": "Cycle",
|
||||
"veh_class_boat": "Boat",
|
||||
"veh_class_helicopter": "Helicopter",
|
||||
"veh_class_plane": "Plane",
|
||||
"veh_class_service": "Service",
|
||||
"veh_class_emergency": "Emergency",
|
||||
"veh_class_military": "Military",
|
||||
"veh_class_commercial": "Commercial",
|
||||
"veh_class_train": "Train",
|
||||
"veh_class_open_wheel": "Open wheel"
|
||||
}
|
||||
134
locales/es.json
Normal file
134
locales/es.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "No se encontró tu Discord, únete a nuestro Discord aquí: %s.",
|
||||
"connecting": "Conectando...",
|
||||
"identifier_not_found": "No se encontró tu %s.",
|
||||
"deposit": "Depositar",
|
||||
"withdraw": "Retirar",
|
||||
"vehicle_ownership_transfered": "Propiedad transferida",
|
||||
"vehicle_ownership_transfered2": "La propiedad del vehículo %s ha sido transferida.",
|
||||
"vehicle_ownership_received": "Propiedad recibida",
|
||||
"vehicle_ownership_received2": "Has recibido la propiedad del vehículo %s.",
|
||||
"keys_shared": "Llaves compartidas",
|
||||
"keys_shared2": "Has compartido las llaves del vehículo con %s.",
|
||||
"keys_received": "Llaves recibidas",
|
||||
"keys_received2": "Has recibido las llaves del vehículo de %s.",
|
||||
"no_signal": "Sin señal",
|
||||
"veh_key_disabled": "Llave del vehículo desactivada.",
|
||||
"veh_key_disabled2": "Esta llave ha sido desactivada y no se puede usar más.",
|
||||
"veh_far_away": "Vehículo demasiado lejos.",
|
||||
"veh_locked": "BLOQUEADO",
|
||||
"veh_locked2": "Tu vehículo ha sido bloqueado.",
|
||||
"veh_unlocked": "DESBLOQUEADO",
|
||||
"veh_unlocked2": "Tu vehículo ha sido desbloqueado.",
|
||||
"garage": "Garaje",
|
||||
"no_owned_veh_nearby": "No se encontró un vehículo propio cerca.",
|
||||
"veh_stored_in_garage": "Vehículo guardado en el garaje.",
|
||||
"impound_reclaim": "Recuperar vehículo del depósito",
|
||||
"impound": "Depósito",
|
||||
"impound_not_enough": "El precio para recuperar es %d €, ¡no tienes suficiente!",
|
||||
"impound_paid": "¡Has pagado %d € para recuperar el vehículo!",
|
||||
"success": "Éxito",
|
||||
"staff_action": "Acción del personal",
|
||||
"staff_money_removed": "Se retiraron %d € (%s) de %s",
|
||||
"user_money_removed": "se retiraron %d € de %s",
|
||||
"staff_money_added": "Se añadieron %d € (%s) a %s",
|
||||
"user_money_added": "se añadieron %d € a %s",
|
||||
"staff_money_set": "Se estableció %s's (%s) en %d €",
|
||||
"user_money_set": "se estableció %s en %d €",
|
||||
"job_updated_noti": "Trabajo actualizado a %s, rango %s.",
|
||||
"group_added_noti": "Añadido al grupo %s, rango %s.",
|
||||
"group_removed_noti": "Eliminado del grupo %s.",
|
||||
"no_player_found": "No se encontró jugador",
|
||||
"not_enough_cash": "No tienes suficiente dinero en efectivo",
|
||||
"player_not_nearby": "El jugador no está cerca",
|
||||
"cant_give_money": "No se pudo dar dinero",
|
||||
"money_received": "Dinero recibido",
|
||||
"money_received2": "Has recibido %d € en efectivo",
|
||||
"money_given": "Dinero entregado",
|
||||
"money_given2": "Has dado %d € en efectivo",
|
||||
"player_in_veh": "¡Jugador en el vehículo!",
|
||||
"perfect": "Perfecto",
|
||||
"good": "Bueno",
|
||||
"bad": "Malo",
|
||||
"very_bad": "Muy malo",
|
||||
"veh_make_brand": "Marca",
|
||||
"veh_model": "Modelo",
|
||||
"veh_plate": "Matrícula",
|
||||
"engine_status": "Estado del motor",
|
||||
"vehicle": "Vehículo",
|
||||
"not_found": "no encontrado",
|
||||
"park_veh": "Aparcar vehículo",
|
||||
"no_vehs_found": "No se encontraron vehículos",
|
||||
"vehicle_impound": "Depósito de vehículos",
|
||||
"parking_garage": "Aparcamiento",
|
||||
"impound_w_location": "Depósito (%s)",
|
||||
"garage_w_location": "Aparcamiento (%s)",
|
||||
"view_impounded_vehs": "Ver vehículos en el depósito",
|
||||
"view_garage": "Ver garaje",
|
||||
"personal_vehicle": "Vehículo personal",
|
||||
"keybind_carkey": "Bloquear/desbloquear vehículo (doble clic)",
|
||||
"progress_hotwiring": "Forzando encendido",
|
||||
"cruise_control": "Control de crucero",
|
||||
"cruise_control_enabled": "Control de crucero activado",
|
||||
"cruise_control_disabled": "Control de crucero desactivado",
|
||||
"cruise_control_toggle": "Alternar control de crucero",
|
||||
"cruise_control_increase": "Velocidad de control de crucero aumentada",
|
||||
"seat_shuffle": "Cambiar de asiento",
|
||||
"discord_text": "Jugando: %s como %s %s",
|
||||
"discord_text_small": "Jugando como: %s %s",
|
||||
"discord_text_server": "Jugando: %s",
|
||||
"pause_menu_cash": "Efectivo: €%d",
|
||||
"pause_menu_bank": "Banco: €%d",
|
||||
"veh_color_black": "Negro",
|
||||
"veh_color_silver": "Plateado",
|
||||
"veh_color_grey": "Gris",
|
||||
"veh_color_metal": "Metal",
|
||||
"veh_color_graphite": "Grafito",
|
||||
"veh_color_red": "Rojo",
|
||||
"veh_color_orange": "Naranja",
|
||||
"veh_color_gold": "Oro",
|
||||
"veh_color_yellow": "Amarillo",
|
||||
"veh_color_green": "Verde",
|
||||
"veh_color_blue": "Azul",
|
||||
"veh_color_bblue": "Azul claro",
|
||||
"veh_color_bronze": "Bronce",
|
||||
"veh_color_lime": "Lima",
|
||||
"veh_color_champagne": "Champán",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Marfil",
|
||||
"veh_color_brown": "Marrón",
|
||||
"veh_color_beechwood": "Haya",
|
||||
"veh_color_sand": "Arena",
|
||||
"veh_color_cream": "Crema",
|
||||
"veh_color_white": "Blanco",
|
||||
"veh_color_steel": "Acero",
|
||||
"veh_color_aluminium": "Aluminio",
|
||||
"veh_color_chrome": "Cromo",
|
||||
"veh_color_pink": "Rosa",
|
||||
"veh_color_purple": "Púrpura",
|
||||
"veh_color_tan": "Bronceado",
|
||||
"veh_color_alloy": "Aleación",
|
||||
"veh_class_compact": "Compacto",
|
||||
"veh_class_sedan": "Sedán",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupé",
|
||||
"veh_class_muscle": "Muscle car",
|
||||
"veh_class_sports_classic": "Deportivo clásico",
|
||||
"veh_class_sport": "Deportivo",
|
||||
"veh_class_super": "Superdeportivo",
|
||||
"veh_class_motorcycle": "Motocicleta",
|
||||
"veh_class_off_road": "Todoterreno",
|
||||
"veh_class_industrial": "Industrial",
|
||||
"veh_class_utility": "Utilitario",
|
||||
"veh_class_van": "Furgoneta",
|
||||
"veh_class_cycle": "Bicicleta",
|
||||
"veh_class_boat": "Barco",
|
||||
"veh_class_helicopter": "Helicóptero",
|
||||
"veh_class_plane": "Avión",
|
||||
"veh_class_service": "Servicio",
|
||||
"veh_class_emergency": "Emergencia",
|
||||
"veh_class_military": "Militar",
|
||||
"veh_class_commercial": "Comercial",
|
||||
"veh_class_train": "Tren",
|
||||
"veh_class_open_wheel": "Rueda abierta"
|
||||
}
|
||||
134
locales/fi.json
Normal file
134
locales/fi.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "Discord-tiliäsi ei löytynyt, liity Discordiimme täällä: %s.",
|
||||
"connecting": "Yhdistetään...",
|
||||
"identifier_not_found": "%s-tunnistetta ei löytynyt.",
|
||||
"deposit": "Talleta",
|
||||
"withdraw": "Nosta",
|
||||
"vehicle_ownership_transfered": "Omistajuus siirretty",
|
||||
"vehicle_ownership_transfered2": "Ajoneuvon %s omistajuus on siirretty.",
|
||||
"vehicle_ownership_received": "Omistajuus vastaanotettu",
|
||||
"vehicle_ownership_received2": "Olet saanut ajoneuvon %s omistajuuden.",
|
||||
"keys_shared": "Avaimet jaettu",
|
||||
"keys_shared2": "Olet jakanut ajoneuvon avaimet käyttäjälle %s.",
|
||||
"keys_received": "Avaimet vastaanotettu",
|
||||
"keys_received2": "Olet saanut ajoneuvon avaimet käyttäjältä %s.",
|
||||
"no_signal": "Ei signaalia",
|
||||
"veh_key_disabled": "Ajoneuvoavain poistettu käytöstä.",
|
||||
"veh_key_disabled2": "Tämä ajoneuvoavain on poistettu käytöstä eikä sitä voi enää käyttää.",
|
||||
"veh_far_away": "Ajoneuvo liian kaukana.",
|
||||
"veh_locked": "LUKITTU",
|
||||
"veh_locked2": "Ajoneuvosi on nyt lukittu.",
|
||||
"veh_unlocked": "AVATTU",
|
||||
"veh_unlocked2": "Ajoneuvosi on nyt avattu.",
|
||||
"garage": "Autotalli",
|
||||
"no_owned_veh_nearby": "Lähistöltä ei löytynyt omistamaasi ajoneuvoa.",
|
||||
"veh_stored_in_garage": "Ajoneuvo tallennettu autotalliin.",
|
||||
"impound_reclaim": "Ajoneuvon takaisinlunastus varikolta",
|
||||
"impound": "Varikko",
|
||||
"impound_not_enough": "Takaisinlunastuksen hinta on %d €, sinulla ei ole tarpeeksi rahaa!",
|
||||
"impound_paid": "Maksettu %d € ajoneuvon takaisinlunastuksesta!",
|
||||
"success": "Onnistui",
|
||||
"staff_action": "Ylläpidon toimenpide",
|
||||
"staff_money_removed": "Poistettu %d € (%s) käyttäjältä %s",
|
||||
"user_money_removed": "poistettu %d € käyttäjältä %s",
|
||||
"staff_money_added": "Lisätty %d € (%s) käyttäjälle %s",
|
||||
"user_money_added": "lisätty %d € käyttäjälle %s",
|
||||
"staff_money_set": "Asetettu %s (%s) summaksi %d €",
|
||||
"user_money_set": "asetettu %s summaksi %d €",
|
||||
"job_updated_noti": "Työ päivitetty: %s, taso %s.",
|
||||
"group_added_noti": "Lisätty ryhmään %s, taso %s.",
|
||||
"group_removed_noti": "Poistettu ryhmästä %s.",
|
||||
"no_player_found": "Pelaajaa ei löytynyt",
|
||||
"not_enough_cash": "Sinulla ei ole tarpeeksi käteistä",
|
||||
"player_not_nearby": "Pelaaja ei ole lähellä",
|
||||
"cant_give_money": "Rahan antaminen epäonnistui",
|
||||
"money_received": "Raha vastaanotettu",
|
||||
"money_received2": "Vastaanotettu %d € käteisenä",
|
||||
"money_given": "Raha annettu",
|
||||
"money_given2": "Annoit %d € käteisenä",
|
||||
"player_in_veh": "Pelaaja ajoneuvossa!",
|
||||
"perfect": "Täydellinen",
|
||||
"good": "Hyvä",
|
||||
"bad": "Huono",
|
||||
"very_bad": "Todella huono",
|
||||
"veh_make_brand": "Merkki",
|
||||
"veh_model": "Malli",
|
||||
"veh_plate": "Rekisterikilpi",
|
||||
"engine_status": "Moottorin tila",
|
||||
"vehicle": "Ajoneuvo",
|
||||
"not_found": "ei löytynyt",
|
||||
"park_veh": "Pysäköi ajoneuvo",
|
||||
"no_vehs_found": "Ajoneuvoja ei löytynyt",
|
||||
"vehicle_impound": "Ajoneuvovarikko",
|
||||
"parking_garage": "Pysäköintihalli",
|
||||
"impound_w_location": "Varikko (%s)",
|
||||
"garage_w_location": "Pysäköintihalli (%s)",
|
||||
"view_impounded_vehs": "Näytä varikolla olevat ajoneuvot",
|
||||
"view_garage": "Näytä autotalli",
|
||||
"personal_vehicle": "Henkilökohtainen ajoneuvo",
|
||||
"keybind_carkey": "Lukitse/avaa ajoneuvo (kaksoisklikkaus)",
|
||||
"progress_hotwiring": "Käynnistetään luvatta",
|
||||
"cruise_control": "Vakionopeudensäädin",
|
||||
"cruise_control_enabled": "Vakionopeudensäädin käytössä",
|
||||
"cruise_control_disabled": "Vakionopeudensäädin pois käytöstä",
|
||||
"cruise_control_toggle": "Vaihda vakionopeudensäädin päälle/pois",
|
||||
"cruise_control_increase": "Vakionopeus kasvoi",
|
||||
"seat_shuffle": "Vaihda istumapaikkaa ajoneuvossa",
|
||||
"discord_text": "Pelaa: %s hahmona %s %s",
|
||||
"discord_text_small": "Pelaa hahmona: %s %s",
|
||||
"discord_text_server": "Pelaa: %s",
|
||||
"pause_menu_cash": "Käteinen: €%d",
|
||||
"pause_menu_bank": "Pankki: €%d",
|
||||
"veh_color_black": "Musta",
|
||||
"veh_color_silver": "Hopea",
|
||||
"veh_color_grey": "Harmaa",
|
||||
"veh_color_metal": "Metalli",
|
||||
"veh_color_graphite": "Grafiitti",
|
||||
"veh_color_red": "Punainen",
|
||||
"veh_color_orange": "Oranssi",
|
||||
"veh_color_gold": "Kulta",
|
||||
"veh_color_yellow": "Keltainen",
|
||||
"veh_color_green": "Vihreä",
|
||||
"veh_color_blue": "Sininen",
|
||||
"veh_color_bblue": "Vaaleansininen",
|
||||
"veh_color_bronze": "Pronssi",
|
||||
"veh_color_lime": "Lime",
|
||||
"veh_color_champagne": "Samppanja",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Norsunluu",
|
||||
"veh_color_brown": "Ruskea",
|
||||
"veh_color_beechwood": "Pyökki",
|
||||
"veh_color_sand": "Hiekka",
|
||||
"veh_color_cream": "Kerma",
|
||||
"veh_color_white": "Valkoinen",
|
||||
"veh_color_steel": "Teräs",
|
||||
"veh_color_aluminium": "Alumiini",
|
||||
"veh_color_chrome": "Kromi",
|
||||
"veh_color_pink": "Vaaleanpunainen",
|
||||
"veh_color_purple": "Violetti",
|
||||
"veh_color_tan": "Vaalea ruskea",
|
||||
"veh_color_alloy": "Seosmetalli",
|
||||
"veh_class_compact": "Pieni auto",
|
||||
"veh_class_sedan": "Sedan",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupe",
|
||||
"veh_class_muscle": "Muskeliauto",
|
||||
"veh_class_sports_classic": "Klassinen urheiluauto",
|
||||
"veh_class_sport": "Urheiluauto",
|
||||
"veh_class_super": "Superauto",
|
||||
"veh_class_motorcycle": "Moottoripyörä",
|
||||
"veh_class_off_road": "Maastoauto",
|
||||
"veh_class_industrial": "Teollisuusajoneuvo",
|
||||
"veh_class_utility": "Hyötyajoneuvo",
|
||||
"veh_class_van": "Pakettiauto",
|
||||
"veh_class_cycle": "Polkupyörä",
|
||||
"veh_class_boat": "Vene",
|
||||
"veh_class_helicopter": "Helikopteri",
|
||||
"veh_class_plane": "Lentokone",
|
||||
"veh_class_service": "Huoltoajoneuvo",
|
||||
"veh_class_emergency": "Hätäajoneuvo",
|
||||
"veh_class_military": "Sotilasajoneuvo",
|
||||
"veh_class_commercial": "Kaupallinen ajoneuvo",
|
||||
"veh_class_train": "Juna",
|
||||
"veh_class_open_wheel": "Avoin pyörä"
|
||||
}
|
||||
134
locales/fr.json
Normal file
134
locales/fr.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "Votre Discord n'a pas été trouvé, rejoignez notre Discord ici : %s.",
|
||||
"connecting": "Connexion...",
|
||||
"identifier_not_found": "Votre %s n'a pas été trouvé.",
|
||||
"deposit": "Dépôt",
|
||||
"withdraw": "Retrait",
|
||||
"vehicle_ownership_transfered": "Propriété transférée",
|
||||
"vehicle_ownership_transfered2": "La propriété du véhicule %s a été transférée.",
|
||||
"vehicle_ownership_received": "Propriété reçue",
|
||||
"vehicle_ownership_received2": "Vous avez reçu la propriété du véhicule %s.",
|
||||
"keys_shared": "Clés partagées",
|
||||
"keys_shared2": "Vous avez partagé les clés du véhicule avec %s.",
|
||||
"keys_received": "Clés reçues",
|
||||
"keys_received2": "Vous avez reçu les clés du véhicule de %s.",
|
||||
"no_signal": "Pas de signal",
|
||||
"veh_key_disabled": "Clé de véhicule désactivée.",
|
||||
"veh_key_disabled2": "Cette clé de véhicule a été désactivée et ne peut plus être utilisée.",
|
||||
"veh_far_away": "Véhicule trop éloigné.",
|
||||
"veh_locked": "VERROUILLÉ",
|
||||
"veh_locked2": "Votre véhicule est maintenant verrouillé.",
|
||||
"veh_unlocked": "DÉVERROUILLÉ",
|
||||
"veh_unlocked2": "Votre véhicule est maintenant déverrouillé.",
|
||||
"garage": "Garage",
|
||||
"no_owned_veh_nearby": "Aucun véhicule possédé trouvé à proximité.",
|
||||
"veh_stored_in_garage": "Véhicule rangé dans le garage.",
|
||||
"impound_reclaim": "Récupération de véhicule mis en fourrière",
|
||||
"impound": "Fourrière",
|
||||
"impound_not_enough": "Le prix pour récupérer est de %d €, vous n'avez pas assez!",
|
||||
"impound_paid": "Vous avez payé %d € pour récupérer le véhicule!",
|
||||
"success": "succès",
|
||||
"staff_action": "Action du staff",
|
||||
"staff_money_removed": "%d € (%s) retiré de %s",
|
||||
"user_money_removed": "%d € retiré de %s",
|
||||
"staff_money_added": "%d € (%s) ajouté à %s",
|
||||
"user_money_added": "%d € ajouté à %s",
|
||||
"staff_money_set": "Solde de %s (%s) défini à %d €",
|
||||
"user_money_set": "Solde de %s défini à %d €",
|
||||
"job_updated_noti": "Emploi mis à jour en %s, grade %s.",
|
||||
"group_added_noti": "Ajouté au groupe %s, grade %s.",
|
||||
"group_removed_noti": "Retiré du groupe %s.",
|
||||
"no_player_found": "Aucun joueur trouvé",
|
||||
"not_enough_cash": "Vous n'avez pas assez d'argent liquide",
|
||||
"player_not_nearby": "Joueur non à proximité",
|
||||
"cant_give_money": "Impossible de donner de l'argent",
|
||||
"money_received": "Argent reçu",
|
||||
"money_received2": "Vous avez reçu %d € en liquide",
|
||||
"money_given": "Argent donné",
|
||||
"money_given2": "Vous avez donné %d € en liquide",
|
||||
"player_in_veh": "Joueur dans un véhicule!",
|
||||
"perfect": "Parfait",
|
||||
"good": "Bon",
|
||||
"bad": "Mauvais",
|
||||
"very_bad": "Très mauvais",
|
||||
"veh_make_brand": "Marque",
|
||||
"veh_model": "Modèle",
|
||||
"veh_plate": "Plaque",
|
||||
"engine_status": "État du moteur",
|
||||
"vehicle": "Véhicule",
|
||||
"not_found": "introuvable",
|
||||
"park_veh": "Garer le véhicule",
|
||||
"no_vehs_found": "Aucun véhicule trouvé",
|
||||
"vehicle_impound": "Fourrière",
|
||||
"parking_garage": "Garage de stationnement",
|
||||
"impound_w_location": "Fourrière (%s)",
|
||||
"garage_w_location": "Garage (%s)",
|
||||
"view_impounded_vehs": "Voir les véhicules en fourrière",
|
||||
"view_garage": "Voir le garage",
|
||||
"personal_vehicle": "Véhicule personnel",
|
||||
"keybind_carkey": "Verrouiller/déverrouiller le véhicule (double clic)",
|
||||
"progress_hotwiring": "Démarrage forcé",
|
||||
"cruise_control": "Régulateur de vitesse",
|
||||
"cruise_control_enabled": "Régulateur de vitesse activé",
|
||||
"cruise_control_disabled": "Régulateur de vitesse désactivé",
|
||||
"cruise_control_toggle": "Activer/désactiver le régulateur de vitesse",
|
||||
"cruise_control_increase": "Vitesse du régulateur augmentée",
|
||||
"seat_shuffle": "Changer de siège",
|
||||
"discord_text": "Joue : %s en tant que %s %s",
|
||||
"discord_text_small": "Joue en tant que : %s %s",
|
||||
"discord_text_server": "Joue : %s",
|
||||
"pause_menu_cash": "Argent liquide : €%d",
|
||||
"pause_menu_bank": "Banque : €%d",
|
||||
"veh_color_black": "Noir",
|
||||
"veh_color_silver": "Argent",
|
||||
"veh_color_grey": "Gris",
|
||||
"veh_color_metal": "Métal",
|
||||
"veh_color_graphite": "Graphite",
|
||||
"veh_color_red": "Rouge",
|
||||
"veh_color_orange": "Orange",
|
||||
"veh_color_gold": "Or",
|
||||
"veh_color_yellow": "Jaune",
|
||||
"veh_color_green": "Vert",
|
||||
"veh_color_blue": "Bleu",
|
||||
"veh_color_bblue": "Bleu clair",
|
||||
"veh_color_bronze": "Bronze",
|
||||
"veh_color_lime": "Citron vert",
|
||||
"veh_color_champagne": "Champagne",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Ivoire",
|
||||
"veh_color_brown": "Marron",
|
||||
"veh_color_beechwood": "Hêtre",
|
||||
"veh_color_sand": "Sable",
|
||||
"veh_color_cream": "Crème",
|
||||
"veh_color_white": "Blanc",
|
||||
"veh_color_steel": "Acier",
|
||||
"veh_color_aluminium": "Aluminium",
|
||||
"veh_color_chrome": "Chrome",
|
||||
"veh_color_pink": "Rose",
|
||||
"veh_color_purple": "Violet",
|
||||
"veh_color_tan": "Fauve",
|
||||
"veh_color_alloy": "Alliage",
|
||||
"veh_class_compact": "Compact",
|
||||
"veh_class_sedan": "Berline",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupé",
|
||||
"veh_class_muscle": "Muscle car",
|
||||
"veh_class_sports_classic": "Sport classique",
|
||||
"veh_class_sport": "Sport",
|
||||
"veh_class_super": "Super",
|
||||
"veh_class_motorcycle": "Moto",
|
||||
"veh_class_off_road": "Tout-terrain",
|
||||
"veh_class_industrial": "Industriel",
|
||||
"veh_class_utility": "Utilitaire",
|
||||
"veh_class_van": "Van",
|
||||
"veh_class_cycle": "Vélo",
|
||||
"veh_class_boat": "Bateau",
|
||||
"veh_class_helicopter": "Hélicoptère",
|
||||
"veh_class_plane": "Avion",
|
||||
"veh_class_service": "Service",
|
||||
"veh_class_emergency": "Urgence",
|
||||
"veh_class_military": "Militaire",
|
||||
"veh_class_commercial": "Commercial",
|
||||
"veh_class_train": "Train",
|
||||
"veh_class_open_wheel": "Monoplace"
|
||||
}
|
||||
134
locales/it.json
Normal file
134
locales/it.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "Il tuo account Discord non è stato trovato, unisciti al nostro Discord qui: %s.",
|
||||
"connecting": "Connessione in corso...",
|
||||
"identifier_not_found": "Il tuo %s non è stato trovato.",
|
||||
"deposit": "Deposito",
|
||||
"withdraw": "Prelievo",
|
||||
"vehicle_ownership_transfered": "Proprietà trasferita",
|
||||
"vehicle_ownership_transfered2": "La proprietà del veicolo %s è stata trasferita.",
|
||||
"vehicle_ownership_received": "Proprietà ricevuta",
|
||||
"vehicle_ownership_received2": "Hai ricevuto la proprietà del veicolo %s.",
|
||||
"keys_shared": "Chiavi condivise",
|
||||
"keys_shared2": "Hai condiviso le chiavi del veicolo con %s.",
|
||||
"keys_received": "Chiavi ricevute",
|
||||
"keys_received2": "Hai ricevuto le chiavi del veicolo da %s.",
|
||||
"no_signal": "Nessun segnale",
|
||||
"veh_key_disabled": "Chiave del veicolo disattivata.",
|
||||
"veh_key_disabled2": "Questa chiave del veicolo è stata disattivata e non può più essere utilizzata.",
|
||||
"veh_far_away": "Veicolo troppo lontano.",
|
||||
"veh_locked": "CHIUSO",
|
||||
"veh_locked2": "Il tuo veicolo è ora chiuso.",
|
||||
"veh_unlocked": "APERTO",
|
||||
"veh_unlocked2": "Il tuo veicolo è ora aperto.",
|
||||
"garage": "Garage",
|
||||
"no_owned_veh_nearby": "Nessun veicolo di tua proprietà trovato nelle vicinanze.",
|
||||
"veh_stored_in_garage": "Veicolo riposto in garage.",
|
||||
"impound_reclaim": "Riscatto veicolo dal deposito",
|
||||
"impound": "Deposito",
|
||||
"impound_not_enough": "Il prezzo per riscattare è %d €, non hai abbastanza soldi!",
|
||||
"impound_paid": "Hai pagato %d € per riscattare il veicolo!",
|
||||
"success": "successo",
|
||||
"staff_action": "Azione staff",
|
||||
"staff_money_removed": "Rimossi %d € (%s) da %s",
|
||||
"user_money_removed": "rimossi %d € da %s",
|
||||
"staff_money_added": "Aggiunti %d € (%s) a %s",
|
||||
"user_money_added": "aggiunti %d € a %s",
|
||||
"staff_money_set": "Impostato il saldo di %s (%s) a %d €",
|
||||
"user_money_set": "impostato %s a %d €",
|
||||
"job_updated_noti": "Lavoro aggiornato a %s, grado %s.",
|
||||
"group_added_noti": "Aggiunto al gruppo %s, grado %s.",
|
||||
"group_removed_noti": "Rimosso dal gruppo %s.",
|
||||
"no_player_found": "Nessun giocatore trovato",
|
||||
"not_enough_cash": "Non hai abbastanza contanti",
|
||||
"player_not_nearby": "Il giocatore non è vicino",
|
||||
"cant_give_money": "Impossibile dare denaro",
|
||||
"money_received": "Denaro ricevuto",
|
||||
"money_received2": "Ricevuti %d € in contanti",
|
||||
"money_given": "Denaro dato",
|
||||
"money_given2": "Hai dato %d € in contanti",
|
||||
"player_in_veh": "Giocatore in veicolo!",
|
||||
"perfect": "Perfetto",
|
||||
"good": "Buono",
|
||||
"bad": "Scarso",
|
||||
"very_bad": "Molto scarso",
|
||||
"veh_make_brand": "Marca",
|
||||
"veh_model": "Modello",
|
||||
"veh_plate": "Targa",
|
||||
"engine_status": "Stato motore",
|
||||
"vehicle": "Veicolo",
|
||||
"not_found": "non trovato",
|
||||
"park_veh": "Parcheggia veicolo",
|
||||
"no_vehs_found": "Nessun veicolo trovato",
|
||||
"vehicle_impound": "Deposito veicoli",
|
||||
"parking_garage": "Parcheggio",
|
||||
"impound_w_location": "Deposito (%s)",
|
||||
"garage_w_location": "Parcheggio (%s)",
|
||||
"view_impounded_vehs": "Visualizza veicoli in deposito",
|
||||
"view_garage": "Visualizza garage",
|
||||
"personal_vehicle": "Veicolo personale",
|
||||
"keybind_carkey": "Apri/chiudi veicolo (doppio click)",
|
||||
"progress_hotwiring": "Avviamento forzato",
|
||||
"cruise_control": "Cruise control",
|
||||
"cruise_control_enabled": "Cruise control attivato",
|
||||
"cruise_control_disabled": "Cruise control disattivato",
|
||||
"cruise_control_toggle": "Attiva/disattiva cruise control",
|
||||
"cruise_control_increase": "Velocità cruise control aumentata",
|
||||
"seat_shuffle": "Cambia posto nel veicolo",
|
||||
"discord_text": "Giocando: %s come %s %s",
|
||||
"discord_text_small": "Giocando come: %s %s",
|
||||
"discord_text_server": "Giocando: %s",
|
||||
"pause_menu_cash": "Contanti: €%d",
|
||||
"pause_menu_bank": "Banca: €%d",
|
||||
"veh_color_black": "Nero",
|
||||
"veh_color_silver": "Argento",
|
||||
"veh_color_grey": "Grigio",
|
||||
"veh_color_metal": "Metallo",
|
||||
"veh_color_graphite": "Grafite",
|
||||
"veh_color_red": "Rosso",
|
||||
"veh_color_orange": "Arancione",
|
||||
"veh_color_gold": "Oro",
|
||||
"veh_color_yellow": "Giallo",
|
||||
"veh_color_green": "Verde",
|
||||
"veh_color_blue": "Blu",
|
||||
"veh_color_bblue": "Blu chiaro",
|
||||
"veh_color_bronze": "Bronzo",
|
||||
"veh_color_lime": "Lime",
|
||||
"veh_color_champagne": "Champagne",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Avorio",
|
||||
"veh_color_brown": "Marrone",
|
||||
"veh_color_beechwood": "Faggio",
|
||||
"veh_color_sand": "Sabbia",
|
||||
"veh_color_cream": "Crema",
|
||||
"veh_color_white": "Bianco",
|
||||
"veh_color_steel": "Acciaio",
|
||||
"veh_color_aluminium": "Alluminio",
|
||||
"veh_color_chrome": "Cromo",
|
||||
"veh_color_pink": "Rosa",
|
||||
"veh_color_purple": "Viola",
|
||||
"veh_color_tan": "Marrone chiaro",
|
||||
"veh_color_alloy": "Lega",
|
||||
"veh_class_compact": "Compatta",
|
||||
"veh_class_sedan": "Berlina",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupé",
|
||||
"veh_class_muscle": "Muscle car",
|
||||
"veh_class_sports_classic": "Sport classico",
|
||||
"veh_class_sport": "Sport",
|
||||
"veh_class_super": "Super",
|
||||
"veh_class_motorcycle": "Motocicletta",
|
||||
"veh_class_off_road": "Fuoristrada",
|
||||
"veh_class_industrial": "Industriale",
|
||||
"veh_class_utility": "Utility",
|
||||
"veh_class_van": "Furgone",
|
||||
"veh_class_cycle": "Bicicletta",
|
||||
"veh_class_boat": "Barca",
|
||||
"veh_class_helicopter": "Elicottero",
|
||||
"veh_class_plane": "Aereo",
|
||||
"veh_class_service": "Servizio",
|
||||
"veh_class_emergency": "Emergenza",
|
||||
"veh_class_military": "Militare",
|
||||
"veh_class_commercial": "Commerciale",
|
||||
"veh_class_train": "Treno",
|
||||
"veh_class_open_wheel": "Ruota scoperta"
|
||||
}
|
||||
134
locales/nl.json
Normal file
134
locales/nl.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "Je Discord-account is niet gevonden, sluit je hier aan bij onze Discord: %s.",
|
||||
"connecting": "Verbinden...",
|
||||
"identifier_not_found": "Je %s is niet gevonden.",
|
||||
"deposit": "Storten",
|
||||
"withdraw": "Opnemen",
|
||||
"vehicle_ownership_transfered": "Eigendom overgedragen",
|
||||
"vehicle_ownership_transfered2": "Het eigendom van het voertuig %s is overgedragen.",
|
||||
"vehicle_ownership_received": "Eigendom ontvangen",
|
||||
"vehicle_ownership_received2": "Je hebt het eigendom van voertuig %s ontvangen.",
|
||||
"keys_shared": "Sleutels gedeeld",
|
||||
"keys_shared2": "Je hebt voertuig sleutels gedeeld met %s.",
|
||||
"keys_received": "Sleutels ontvangen",
|
||||
"keys_received2": "Je hebt voertuig sleutels ontvangen van %s.",
|
||||
"no_signal": "Geen signaal",
|
||||
"veh_key_disabled": "Voertuigsleutel uitgeschakeld.",
|
||||
"veh_key_disabled2": "Deze voertuigsleutel is uitgeschakeld en kan niet meer worden gebruikt.",
|
||||
"veh_far_away": "Voertuig te ver weg.",
|
||||
"veh_locked": "GESLOTEN",
|
||||
"veh_locked2": "Je voertuig is nu gesloten.",
|
||||
"veh_unlocked": "GEOPEND",
|
||||
"veh_unlocked2": "Je voertuig is nu geopend.",
|
||||
"garage": "Garage",
|
||||
"no_owned_veh_nearby": "Geen eigendom voertuig in de buurt gevonden.",
|
||||
"veh_stored_in_garage": "Voertuig opgeslagen in garage.",
|
||||
"impound_reclaim": "Voertuig terugvorderen uit beslag",
|
||||
"impound": "Beslag",
|
||||
"impound_not_enough": "Prijs voor terugvordering is €%d, je hebt niet genoeg!",
|
||||
"impound_paid": "€%d betaald om voertuig terug te vorderen!",
|
||||
"success": "succes",
|
||||
"staff_action": "Staf actie",
|
||||
"staff_money_removed": "€%d (%s) verwijderd van %s",
|
||||
"user_money_removed": "€%d verwijderd van %s",
|
||||
"staff_money_added": "€%d (%s) toegevoegd aan %s",
|
||||
"user_money_added": "€%d toegevoegd aan %s",
|
||||
"staff_money_set": "Saldo van %s (%s) ingesteld op €%d",
|
||||
"user_money_set": "Saldo van %s ingesteld op €%d",
|
||||
"job_updated_noti": "Baan bijgewerkt naar %s, rang %s.",
|
||||
"group_added_noti": "Toegevoegd aan groep %s, rang %s.",
|
||||
"group_removed_noti": "Verwijderd uit groep %s.",
|
||||
"no_player_found": "Geen speler gevonden",
|
||||
"not_enough_cash": "Je hebt niet genoeg contant geld",
|
||||
"player_not_nearby": "Speler is niet in de buurt",
|
||||
"cant_give_money": "Kon geen geld geven",
|
||||
"money_received": "Geld ontvangen",
|
||||
"money_received2": "€%d contant ontvangen",
|
||||
"money_given": "Geld gegeven",
|
||||
"money_given2": "Je hebt €%d contant gegeven",
|
||||
"player_in_veh": "Speler in voertuig!",
|
||||
"perfect": "Perfect",
|
||||
"good": "Goed",
|
||||
"bad": "Slecht",
|
||||
"very_bad": "Zeer slecht",
|
||||
"veh_make_brand": "Merk",
|
||||
"veh_model": "Model",
|
||||
"veh_plate": "Kenteken",
|
||||
"engine_status": "Motorstatus",
|
||||
"vehicle": "Voertuig",
|
||||
"not_found": "niet gevonden",
|
||||
"park_veh": "Voertuig parkeren",
|
||||
"no_vehs_found": "Geen voertuigen gevonden",
|
||||
"vehicle_impound": "Voertuigen in beslag",
|
||||
"parking_garage": "Parkeergarage",
|
||||
"impound_w_location": "Beslag (%s)",
|
||||
"garage_w_location": "Parkeergarage (%s)",
|
||||
"view_impounded_vehs": "Bekijk in beslag genomen voertuigen",
|
||||
"view_garage": "Bekijk garage",
|
||||
"personal_vehicle": "Persoonlijk voertuig",
|
||||
"keybind_carkey": "Voertuig openen/sluiten (dubbelklik)",
|
||||
"progress_hotwiring": "Hotwiring",
|
||||
"cruise_control": "Cruise control",
|
||||
"cruise_control_enabled": "Cruise control ingeschakeld",
|
||||
"cruise_control_disabled": "Cruise control uitgeschakeld",
|
||||
"cruise_control_toggle": "Cruise control aan/uit",
|
||||
"cruise_control_increase": "Cruise control snelheid verhoogd",
|
||||
"seat_shuffle": "Stoel wisselen",
|
||||
"discord_text": "Spelend: %s als %s %s",
|
||||
"discord_text_small": "Spelend als: %s %s",
|
||||
"discord_text_server": "Spelend: %s",
|
||||
"pause_menu_cash": "Contant: €%d",
|
||||
"pause_menu_bank": "Bank: €%d",
|
||||
"veh_color_black": "Zwart",
|
||||
"veh_color_silver": "Zilver",
|
||||
"veh_color_grey": "Grijs",
|
||||
"veh_color_metal": "Metaal",
|
||||
"veh_color_graphite": "Grafiet",
|
||||
"veh_color_red": "Rood",
|
||||
"veh_color_orange": "Oranje",
|
||||
"veh_color_gold": "Goud",
|
||||
"veh_color_yellow": "Geel",
|
||||
"veh_color_green": "Groen",
|
||||
"veh_color_blue": "Blauw",
|
||||
"veh_color_bblue": "Helderblauw",
|
||||
"veh_color_bronze": "Brons",
|
||||
"veh_color_lime": "Limoen",
|
||||
"veh_color_champagne": "Champagne",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Ivoor",
|
||||
"veh_color_brown": "Bruin",
|
||||
"veh_color_beechwood": "Beukenhout",
|
||||
"veh_color_sand": "Zand",
|
||||
"veh_color_cream": "Crème",
|
||||
"veh_color_white": "Wit",
|
||||
"veh_color_steel": "Staal",
|
||||
"veh_color_aluminium": "Aluminium",
|
||||
"veh_color_chrome": "Chroom",
|
||||
"veh_color_pink": "Roze",
|
||||
"veh_color_purple": "Paars",
|
||||
"veh_color_tan": "Bruin-beige",
|
||||
"veh_color_alloy": "Alloy",
|
||||
"veh_class_compact": "Compact",
|
||||
"veh_class_sedan": "Sedan",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupe",
|
||||
"veh_class_muscle": "Muscle",
|
||||
"veh_class_sports_classic": "Sport Classic",
|
||||
"veh_class_sport": "Sport",
|
||||
"veh_class_super": "Super",
|
||||
"veh_class_motorcycle": "Motorfiets",
|
||||
"veh_class_off_road": "Off-road",
|
||||
"veh_class_industrial": "Industrieel",
|
||||
"veh_class_utility": "Utility",
|
||||
"veh_class_van": "Bus",
|
||||
"veh_class_cycle": "Fiets",
|
||||
"veh_class_boat": "Boot",
|
||||
"veh_class_helicopter": "Helikopter",
|
||||
"veh_class_plane": "Vliegtuig",
|
||||
"veh_class_service": "Dienst",
|
||||
"veh_class_emergency": "Nooddienst",
|
||||
"veh_class_military": "Militair",
|
||||
"veh_class_commercial": "Commercieel",
|
||||
"veh_class_train": "Trein",
|
||||
"veh_class_open_wheel": "Open wiel"
|
||||
}
|
||||
134
locales/no.json
Normal file
134
locales/no.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "Discorden din ble ikke funnet, bli med i vår Discord her: %s.",
|
||||
"connecting": "Kobler til...",
|
||||
"identifier_not_found": "Din %s ble ikke funnet.",
|
||||
"deposit": "Innskudd",
|
||||
"withdraw": "Ta ut",
|
||||
"vehicle_ownership_transfered": "Eierskap overført",
|
||||
"vehicle_ownership_transfered2": "Eierskapet til kjøretøyet %s har blitt overført.",
|
||||
"vehicle_ownership_received": "Eierskap mottatt",
|
||||
"vehicle_ownership_received2": "Mottatt eierskap til kjøretøyet %s.",
|
||||
"keys_shared": "Nøkler delt",
|
||||
"keys_shared2": "Du har delt kjøretøynøkler med %s.",
|
||||
"keys_received": "Nøkler mottatt",
|
||||
"keys_received2": "Du har mottatt kjøretøynøkler fra %s.",
|
||||
"no_signal": "Ingen signal",
|
||||
"veh_key_disabled": "Kjøretøynøkkel deaktivert.",
|
||||
"veh_key_disabled2": "Denne nøkkelen er deaktivert og kan ikke brukes lenger.",
|
||||
"veh_far_away": "Kjøretøyet er for langt unna.",
|
||||
"veh_locked": "LÅST",
|
||||
"veh_locked2": "Kjøretøyet ditt er nå låst.",
|
||||
"veh_unlocked": "ÅPEN",
|
||||
"veh_unlocked2": "Kjøretøyet ditt er nå åpnet.",
|
||||
"garage": "Garasje",
|
||||
"no_owned_veh_nearby": "Ingen eide kjøretøy i nærheten.",
|
||||
"veh_stored_in_garage": "Kjøretøy lagret i garasje.",
|
||||
"impound_reclaim": "Hent kjøretøy fra beslag",
|
||||
"impound": "Beslag",
|
||||
"impound_not_enough": "Pris for å hente er %d kr, du har ikke nok!",
|
||||
"impound_paid": "Betalt %d kr for å hente kjøretøy!",
|
||||
"success": "suksess",
|
||||
"staff_action": "Ansatt handling",
|
||||
"staff_money_removed": "Fjernet %d kr (%s) fra %s",
|
||||
"user_money_removed": "Fjernet %d kr fra %s",
|
||||
"staff_money_added": "Lagt til %d kr (%s) til %s",
|
||||
"user_money_added": "Lagt til %d kr til %s",
|
||||
"staff_money_set": "Stilt inn %s sin (%s) til %d kr",
|
||||
"user_money_set": "Stilt inn %s til %d kr",
|
||||
"job_updated_noti": "Jobb oppdatert til %s, rang %s.",
|
||||
"group_added_noti": "Lagt til gruppe %s, rang %s.",
|
||||
"group_removed_noti": "Fjernet fra gruppe %s.",
|
||||
"no_player_found": "Ingen spiller funnet",
|
||||
"not_enough_cash": "Du har ikke nok kontanter",
|
||||
"player_not_nearby": "Spiller er ikke i nærheten",
|
||||
"cant_give_money": "Kunne ikke gi penger",
|
||||
"money_received": "Penger mottatt",
|
||||
"money_received2": "Mottatt %d kr kontant",
|
||||
"money_given": "Penger gitt",
|
||||
"money_given2": "Du ga %d kr kontant",
|
||||
"player_in_veh": "Spiller i kjøretøy!",
|
||||
"perfect": "Perfekt",
|
||||
"good": "Bra",
|
||||
"bad": "Dårlig",
|
||||
"very_bad": "Veldig dårlig",
|
||||
"veh_make_brand": "Merke",
|
||||
"veh_model": "Modell",
|
||||
"veh_plate": "Skilt",
|
||||
"engine_status": "Motorstatus",
|
||||
"vehicle": "Kjøretøy",
|
||||
"not_found": "ikke funnet",
|
||||
"park_veh": "Parker kjøretøy",
|
||||
"no_vehs_found": "Ingen kjøretøy funnet",
|
||||
"vehicle_impound": "Kjøretøy beslag",
|
||||
"parking_garage": "Parkeringsgarasje",
|
||||
"impound_w_location": "Beslag (%s)",
|
||||
"garage_w_location": "Garasje (%s)",
|
||||
"view_impounded_vehs": "Se beslaglagte kjøretøy",
|
||||
"view_garage": "Se garasje",
|
||||
"personal_vehicle": "Personlig kjøretøy",
|
||||
"keybind_carkey": "Lås/åpne kjøretøy (dobbeltklikk)",
|
||||
"progress_hotwiring": "Tjuvstart",
|
||||
"cruise_control": "Cruise control",
|
||||
"cruise_control_enabled": "Cruise control aktivert",
|
||||
"cruise_control_disabled": "Cruise control deaktivert",
|
||||
"cruise_control_toggle": "Bytt cruise control",
|
||||
"cruise_control_increase": "Cruise control hastighet økt",
|
||||
"seat_shuffle": "Bytt plass i kjøretøy",
|
||||
"discord_text": "Spiller: %s som %s %s",
|
||||
"discord_text_small": "Spiller som: %s %s",
|
||||
"discord_text_server": "Spiller: %s",
|
||||
"pause_menu_cash": "Kontanter: %d",
|
||||
"pause_menu_bank": "Bank: %d",
|
||||
"veh_color_black": "Svart",
|
||||
"veh_color_silver": "Sølv",
|
||||
"veh_color_grey": "Grå",
|
||||
"veh_color_metal": "Metall",
|
||||
"veh_color_graphite": "Grafitt",
|
||||
"veh_color_red": "Rød",
|
||||
"veh_color_orange": "Oransje",
|
||||
"veh_color_gold": "Gull",
|
||||
"veh_color_yellow": "Gul",
|
||||
"veh_color_green": "Grønn",
|
||||
"veh_color_blue": "Blå",
|
||||
"veh_color_bblue": "Lyseblå",
|
||||
"veh_color_bronze": "Bronse",
|
||||
"veh_color_lime": "Lime",
|
||||
"veh_color_champagne": "Champagne",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Elfenben",
|
||||
"veh_color_brown": "Brun",
|
||||
"veh_color_beechwood": "Bøk",
|
||||
"veh_color_sand": "Sand",
|
||||
"veh_color_cream": "Krem",
|
||||
"veh_color_white": "Hvit",
|
||||
"veh_color_steel": "Stål",
|
||||
"veh_color_aluminium": "Aluminium",
|
||||
"veh_color_chrome": "Krom",
|
||||
"veh_color_pink": "Rosa",
|
||||
"veh_color_purple": "Lilla",
|
||||
"veh_color_tan": "Brunlig",
|
||||
"veh_color_alloy": "Aluminiumlegering",
|
||||
"veh_class_compact": "Kompakt",
|
||||
"veh_class_sedan": "Sedan",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupe",
|
||||
"veh_class_muscle": "Muscle",
|
||||
"veh_class_sports_classic": "Sports Classic",
|
||||
"veh_class_sport": "Sport",
|
||||
"veh_class_super": "Super",
|
||||
"veh_class_motorcycle": "Motorsykkel",
|
||||
"veh_class_off_road": "Terreng",
|
||||
"veh_class_industrial": "Industriell",
|
||||
"veh_class_utility": "Nyttig",
|
||||
"veh_class_van": "Varebil",
|
||||
"veh_class_cycle": "Sykkel",
|
||||
"veh_class_boat": "Båt",
|
||||
"veh_class_helicopter": "Helikopter",
|
||||
"veh_class_plane": "Fly",
|
||||
"veh_class_service": "Service",
|
||||
"veh_class_emergency": "Nød",
|
||||
"veh_class_military": "Militær",
|
||||
"veh_class_commercial": "Kommersiell",
|
||||
"veh_class_train": "Tog",
|
||||
"veh_class_open_wheel": "Åpen hjul"
|
||||
}
|
||||
134
locales/ru.json
Normal file
134
locales/ru.json
Normal file
@@ -0,0 +1,134 @@
|
||||
{
|
||||
"not_in_discord": "Ваш Discord не найден, присоединяйтесь к нашему Discord здесь: %s.",
|
||||
"connecting": "Подключение...",
|
||||
"identifier_not_found": "Ваш %s не найден.",
|
||||
"deposit": "Внести",
|
||||
"withdraw": "Снять",
|
||||
"vehicle_ownership_transfered": "Владение передано",
|
||||
"vehicle_ownership_transfered2": "Владение транспортным средством %s было передано.",
|
||||
"vehicle_ownership_received": "Владение получено",
|
||||
"vehicle_ownership_received2": "Вы получили транспортное средство %s.",
|
||||
"keys_shared": "Ключи переданы",
|
||||
"keys_shared2": "Вы передали ключи от транспортного средства %s.",
|
||||
"keys_received": "Ключи получены",
|
||||
"keys_received2": "Вы получили ключи от транспортного средства %s.",
|
||||
"no_signal": "Нет сигнала",
|
||||
"veh_key_disabled": "Ключ от транспортного средства отключен.",
|
||||
"veh_key_disabled2": "Этот ключ отключен и больше не может использоваться.",
|
||||
"veh_far_away": "Транспорт слишком далеко.",
|
||||
"veh_locked": "ЗАПЕРТО",
|
||||
"veh_locked2": "Ваш транспорт теперь заперт.",
|
||||
"veh_unlocked": "ОТКРЫТО",
|
||||
"veh_unlocked2": "Ваш транспорт теперь открыт.",
|
||||
"garage": "Гараж",
|
||||
"no_owned_veh_nearby": "Вблизи не найдено вашего транспортного средства.",
|
||||
"veh_stored_in_garage": "Транспортное средство помещено в гараж.",
|
||||
"impound_reclaim": "Забрать транспорт из штрафстоянки",
|
||||
"impound": "Штрафстоянка",
|
||||
"impound_not_enough": "Цена за возврат %d₽, у вас недостаточно!",
|
||||
"impound_paid": "Оплачено %d₽ за возврат транспортного средства!",
|
||||
"success": "успешно",
|
||||
"staff_action": "Действие персонала",
|
||||
"staff_money_removed": "Удалено %d₽ (%s) у %s",
|
||||
"user_money_removed": "Удалено %d₽ у %s",
|
||||
"staff_money_added": "Добавлено %d₽ (%s) к %s",
|
||||
"user_money_added": "Добавлено %d₽ к %s",
|
||||
"staff_money_set": "Баланс %s (%s) установлен на %d₽",
|
||||
"user_money_set": "Баланс %s установлен на %d₽",
|
||||
"job_updated_noti": "Работа обновлена до %s, ранг %s.",
|
||||
"group_added_noti": "Добавлен в группу %s, ранг %s.",
|
||||
"group_removed_noti": "Удалён из группы %s.",
|
||||
"no_player_found": "Игрок не найден",
|
||||
"not_enough_cash": "У вас недостаточно наличных",
|
||||
"player_not_nearby": "Игрок не рядом",
|
||||
"cant_give_money": "Не удалось передать деньги",
|
||||
"money_received": "Деньги получены",
|
||||
"money_received2": "Получено %d₽ наличными",
|
||||
"money_given": "Деньги переданы",
|
||||
"money_given2": "Вы передали %d₽ наличными",
|
||||
"player_in_veh": "Игрок в транспортном средстве!",
|
||||
"perfect": "Идеально",
|
||||
"good": "Хорошо",
|
||||
"bad": "Плохо",
|
||||
"very_bad": "Очень плохо",
|
||||
"veh_make_brand": "Марка",
|
||||
"veh_model": "Модель",
|
||||
"veh_plate": "Номер",
|
||||
"engine_status": "Состояние двигателя",
|
||||
"vehicle": "Транспортное средство",
|
||||
"not_found": "не найдено",
|
||||
"park_veh": "Припарковать транспорт",
|
||||
"no_vehs_found": "Транспортные средства не найдены",
|
||||
"vehicle_impound": "Штрафстоянка",
|
||||
"parking_garage": "Парковка",
|
||||
"impound_w_location": "Штрафстоянка (%s)",
|
||||
"garage_w_location": "Гараж (%s)",
|
||||
"view_impounded_vehs": "Просмотр транспортных средств на штрафстоянке",
|
||||
"view_garage": "Просмотр гаража",
|
||||
"personal_vehicle": "Личный транспорт",
|
||||
"keybind_carkey": "Открыть/закрыть транспорт (двойной клик)",
|
||||
"progress_hotwiring": "Вскрытие замка",
|
||||
"cruise_control": "Круиз-контроль",
|
||||
"cruise_control_enabled": "Круиз-контроль включен",
|
||||
"cruise_control_disabled": "Круиз-контроль выключен",
|
||||
"cruise_control_toggle": "Переключить круиз-контроль",
|
||||
"cruise_control_increase": "Скорость круиз-контроля увеличена",
|
||||
"seat_shuffle": "Смена места в транспорте",
|
||||
"discord_text": "Играет: %s как %s %s",
|
||||
"discord_text_small": "Играет как: %s %s",
|
||||
"discord_text_server": "Играет: %s",
|
||||
"pause_menu_cash": "Наличные: ₽%d",
|
||||
"pause_menu_bank": "Банк: ₽%d",
|
||||
"veh_color_black": "Черный",
|
||||
"veh_color_silver": "Серебристый",
|
||||
"veh_color_grey": "Серый",
|
||||
"veh_color_metal": "Металлик",
|
||||
"veh_color_graphite": "Графит",
|
||||
"veh_color_red": "Красный",
|
||||
"veh_color_orange": "Оранжевый",
|
||||
"veh_color_gold": "Золотой",
|
||||
"veh_color_yellow": "Желтый",
|
||||
"veh_color_green": "Зеленый",
|
||||
"veh_color_blue": "Синий",
|
||||
"veh_color_bblue": "Ярко-синий",
|
||||
"veh_color_bronze": "Бронзовый",
|
||||
"veh_color_lime": "Лаймовый",
|
||||
"veh_color_champagne": "Шампанское",
|
||||
"veh_color_beige": "Бежевый",
|
||||
"veh_color_ivory": "Слоновая кость",
|
||||
"veh_color_brown": "Коричневый",
|
||||
"veh_color_beechwood": "Бук",
|
||||
"veh_color_sand": "Песочный",
|
||||
"veh_color_cream": "Кремовый",
|
||||
"veh_color_white": "Белый",
|
||||
"veh_color_steel": "Стальной",
|
||||
"veh_color_aluminium": "Алюминий",
|
||||
"veh_color_chrome": "Хром",
|
||||
"veh_color_pink": "Розовый",
|
||||
"veh_color_purple": "Фиолетовый",
|
||||
"veh_color_tan": "Загар",
|
||||
"veh_color_alloy": "Легкосплавный",
|
||||
"veh_class_compact": "Компакт",
|
||||
"veh_class_sedan": "Седан",
|
||||
"veh_class_suv": "Внедорожник",
|
||||
"veh_class_coupe": "Купе",
|
||||
"veh_class_muscle": "Мускул",
|
||||
"veh_class_sports_classic": "Спорт Классик",
|
||||
"veh_class_sport": "Спорт",
|
||||
"veh_class_super": "Супер",
|
||||
"veh_class_motorcycle": "Мотоцикл",
|
||||
"veh_class_off_road": "Внедорожник",
|
||||
"veh_class_industrial": "Промышленный",
|
||||
"veh_class_utility": "Утилитарный",
|
||||
"veh_class_van": "Фургон",
|
||||
"veh_class_cycle": "Велосипед",
|
||||
"veh_class_boat": "Лодка",
|
||||
"veh_class_helicopter": "Вертолет",
|
||||
"veh_class_plane": "Самолет",
|
||||
"veh_class_service": "Служебный",
|
||||
"veh_class_emergency": "Экстренный",
|
||||
"veh_class_military": "Военный",
|
||||
"veh_class_commercial": "Коммерческий",
|
||||
"veh_class_train": "Поезд",
|
||||
"veh_class_open_wheel": "Открытые колеса"
|
||||
}
|
||||
135
locales/sv.json
Normal file
135
locales/sv.json
Normal file
@@ -0,0 +1,135 @@
|
||||
{
|
||||
"not_in_discord": "Din Discord hittades inte, gå med i vår Discord här: %s.",
|
||||
"connecting": "Ansluter...",
|
||||
"identifier_not_found": "Din %s hittades inte.",
|
||||
"deposit": "Sätt in",
|
||||
"withdraw": "Ta ut",
|
||||
"vehicle_ownership_transfered": "Ägarskap överfört",
|
||||
"vehicle_ownership_transfered2": "Fordonets ägarskap för %s har överförts.",
|
||||
"vehicle_ownership_received": "Ägarskap mottaget",
|
||||
"vehicle_ownership_received2": "Mottagit fordonets ägarskap för %s.",
|
||||
"keys_shared": "Nycklar delade",
|
||||
"keys_shared2": "Du har delat fordonsnycklar med %s.",
|
||||
"keys_received": "Nycklar mottagna",
|
||||
"keys_received2": "Du har mottagit fordonsnycklar från %s.",
|
||||
"no_signal": "Ingen signal",
|
||||
"veh_key_disabled": "Fordonsnyckel inaktiverad.",
|
||||
"veh_key_disabled2": "Denna fordonsnyckel har inaktiverats och kan inte längre användas.",
|
||||
"veh_far_away": "Fordonet är för långt borta.",
|
||||
"veh_locked": "LÅST",
|
||||
"veh_locked2": "Ditt fordon är nu låst.",
|
||||
"veh_unlocked": "OLÅST",
|
||||
"veh_unlocked2": "Ditt fordon är nu olåst.",
|
||||
"garage": "Garage",
|
||||
"no_owned_veh_nearby": "Inget ägt fordon hittades i närheten.",
|
||||
"veh_stored_in_garage": "Fordonet har placerats i garaget.",
|
||||
"impound_reclaim": "Återtagning av beslagtaget fordon",
|
||||
"impound": "Beslag",
|
||||
"impound_not_enough": "Priset för att återta är %d kr, du har inte tillräckligt!",
|
||||
"impound_paid": "Betalade %d kr för att återta fordonet!",
|
||||
"success": "framgång",
|
||||
"staff_action": "Personalåtgärd",
|
||||
"staff_money_removed": "Tog bort %d kr (%s) från %s",
|
||||
"user_money_removed": "tog bort %d kr från %s",
|
||||
"staff_money_added": "Lade till %d kr (%s) till %s",
|
||||
"user_money_added": "lade till %d kr till %s",
|
||||
"staff_money_set": "Satte %s:s (%s) till %d kr",
|
||||
"user_money_set": "satte %s till %d kr",
|
||||
"job_updated_noti": "Jobb uppdaterat till %s, rang %s.",
|
||||
"group_added_noti": "Tillagd i gruppen %s, rang %s.",
|
||||
"group_removed_noti": "Borttagen från gruppen %s.",
|
||||
"no_player_found": "Ingen spelare hittades",
|
||||
"not_enough_cash": "Du har inte tillräckligt med kontanter",
|
||||
"player_not_nearby": "Spelaren är inte i närheten",
|
||||
"cant_give_money": "Kunde inte ge pengar",
|
||||
"money_received": "Pengar mottagna",
|
||||
"money_received2": "Mottog %d kr kontant",
|
||||
"money_given": "Pengar givna",
|
||||
"money_given2": "Du gav %d kr kontant",
|
||||
"player_in_veh": "Spelaren är i fordon!",
|
||||
"perfect": "Perfekt",
|
||||
"good": "Bra",
|
||||
"bad": "Dålig",
|
||||
"very_bad": "Mycket dålig",
|
||||
"veh_make_brand": "Märke",
|
||||
"veh_model": "Modell",
|
||||
"veh_plate": "Registreringsskylt",
|
||||
"engine_status": "Motorstatus",
|
||||
"vehicle": "Fordon",
|
||||
"not_found": "hittades inte",
|
||||
"park_veh": "Parkera fordon",
|
||||
"no_vehs_found": "Inga fordon hittades",
|
||||
"vehicle_impound": "Beslagtagna fordon",
|
||||
"parking_garage": "Parkeringsgarage",
|
||||
"impound_w_location": "Beslag (%s)",
|
||||
"garage_w_location": "Parkeringsgarage (%s)",
|
||||
"view_impounded_vehs": "Visa beslagtagna fordon",
|
||||
"view_garage": "Visa garage",
|
||||
"personal_vehicle": "Personligt fordon",
|
||||
"keybind_carkey": "Lås/öppna fordon (dubbelklick)",
|
||||
"progress_hotwiring": "Kopplar om",
|
||||
"cruise_control": "Farthållare",
|
||||
"cruise_control_enabled": "Fordonets farthållare aktiverad",
|
||||
"cruise_control_disabled": "Fordonets farthållare avaktiverad",
|
||||
"cruise_control_toggle": "Växla fordonets farthållare",
|
||||
"cruise_control_increase": "Ökade farthållarens hastighet",
|
||||
"seat_shuffle": "Byt plats i fordonet",
|
||||
"discord_text": "Spelar: %s som %s %s",
|
||||
"discord_text_small": "Spelar som: %s %s",
|
||||
"discord_text_server": "Spelar: %s",
|
||||
"pause_menu_cash": "Kontanter: %d",
|
||||
"pause_menu_bank": "Bank: %d",
|
||||
|
||||
"veh_color_black": "Svart",
|
||||
"veh_color_silver": "Silver",
|
||||
"veh_color_grey": "Grå",
|
||||
"veh_color_metal": "Metall",
|
||||
"veh_color_graphite": "Grafit",
|
||||
"veh_color_red": "Röd",
|
||||
"veh_color_orange": "Orange",
|
||||
"veh_color_gold": "Guld",
|
||||
"veh_color_yellow": "Gul",
|
||||
"veh_color_green": "Grön",
|
||||
"veh_color_blue": "Blå",
|
||||
"veh_color_bblue": "Ljusblå",
|
||||
"veh_color_bronze": "Brons",
|
||||
"veh_color_lime": "Lime",
|
||||
"veh_color_champagne": "Champagne",
|
||||
"veh_color_beige": "Beige",
|
||||
"veh_color_ivory": "Elfenben",
|
||||
"veh_color_brown": "Brun",
|
||||
"veh_color_beechwood": "Bokträ",
|
||||
"veh_color_sand": "Sand",
|
||||
"veh_color_cream": "Kräm",
|
||||
"veh_color_white": "Vit",
|
||||
"veh_color_steel": "Stål",
|
||||
"veh_color_aluminium": "Aluminium",
|
||||
"veh_color_chrome": "Krom",
|
||||
"veh_color_pink": "Rosa",
|
||||
"veh_color_purple": "Lila",
|
||||
"veh_color_tan": "Ljusbrun",
|
||||
"veh_color_alloy": "Legering",
|
||||
"veh_class_compact": "Kompakt",
|
||||
"veh_class_sedan": "Sedan",
|
||||
"veh_class_suv": "SUV",
|
||||
"veh_class_coupe": "Coupé",
|
||||
"veh_class_muscle": "Muskelbil",
|
||||
"veh_class_sports_classic": "Klassisk sportbil",
|
||||
"veh_class_sport": "Sport",
|
||||
"veh_class_super": "Superbil",
|
||||
"veh_class_motorcycle": "Motorcykel",
|
||||
"veh_class_off_road": "Terräng",
|
||||
"veh_class_industrial": "Industri",
|
||||
"veh_class_utility": "Nyttolast",
|
||||
"veh_class_van": "Skåpbil",
|
||||
"veh_class_cycle": "Cykel",
|
||||
"veh_class_boat": "Båt",
|
||||
"veh_class_helicopter": "Helikopter",
|
||||
"veh_class_plane": "Flygplan",
|
||||
"veh_class_service": "Service",
|
||||
"veh_class_emergency": "Utryckning",
|
||||
"veh_class_military": "Militär",
|
||||
"veh_class_commercial": "Kommersiell",
|
||||
"veh_class_train": "Tåg",
|
||||
"veh_class_open_wheel": "Öppen hjulbil"
|
||||
}
|
||||
@@ -1,21 +1,21 @@
|
||||
local moneyTypes = {"bank", "cash"}
|
||||
local moneyActions = {
|
||||
remove = function(player, account, amount)
|
||||
player.deductMoney(account, amount, "Staff action")
|
||||
return ("Removed $%d (%s) to %s"):format(amount, account, player.name), ("removed $%d from %s"):format(amount, account)
|
||||
player.deductMoney(account, amount, locale("staff_action"))
|
||||
return locale("staff_money_removed", amount, account, player.name), locale("user_money_removed", amount, account)
|
||||
end,
|
||||
add = function(player, account, amount)
|
||||
player.addMoney(account, amount, "Staff action")
|
||||
return ("Added $%d (%s) to %s"):format(amount, account, player.name), ("added $%d to %s"):format(amount, account)
|
||||
player.addMoney(account, amount, locale("staff_action"))
|
||||
return locale("staff_money_added", amount, account, player.name), locale("user_money_added", amount, account)
|
||||
end,
|
||||
set = function(player, account, amount)
|
||||
player.setData(account, amount, "Staff action")
|
||||
return ("Set %s's (%s) to $%d"):format(player.name, account, amount), ("set %s to $%d"):format(account, amount)
|
||||
player.setData(account, amount, locale("staff_action"))
|
||||
return locale("staff_money_set", player.name, account, amount), locale("user_money_set", account, amount)
|
||||
end
|
||||
}
|
||||
|
||||
lib.addCommand("setmoney", {
|
||||
help = "Admin command, manage player money.",
|
||||
help = "Admin command, set a players money.",
|
||||
restricted = "group.admin",
|
||||
params = {
|
||||
{
|
||||
@@ -48,17 +48,17 @@ lib.addCommand("setmoney", {
|
||||
local staffMessage, userMessage = action(player, moneyType, args.amount)
|
||||
|
||||
player.notify({
|
||||
title = "Staff action",
|
||||
title = locale("staff_action"),
|
||||
description = userMessage,
|
||||
type = "inform",
|
||||
duration = 10000
|
||||
})
|
||||
|
||||
if not source then return end
|
||||
if not source or source == 0 then return end
|
||||
TriggerClientEvent("chat:addMessage", source, {
|
||||
color = {50, 100, 235},
|
||||
multiline = true,
|
||||
args = {"Staff action", staffMessage}
|
||||
args = {locale("staff_action"), staffMessage}
|
||||
})
|
||||
end)
|
||||
|
||||
@@ -90,17 +90,17 @@ lib.addCommand("setjob", {
|
||||
local jobInfo = player.setJob(job, args.rank)
|
||||
if not player or not jobInfo then return end
|
||||
player.notify({
|
||||
title = "Staff action",
|
||||
description = ("Job updated to %s, rank %s"):format(jobInfo.label, jobInfo.rankName),
|
||||
title = locale("staff_action"),
|
||||
description = locale("job_updated_noti", jobInfo.label, jobInfo.rankName),
|
||||
type = "inform",
|
||||
duration = 10000
|
||||
})
|
||||
|
||||
if not source then return end
|
||||
if not source or source == 0 then return end
|
||||
TriggerClientEvent("chat:addMessage", source, {
|
||||
color = {50, 100, 235},
|
||||
multiline = true,
|
||||
args = {"Staff action", "success"}
|
||||
args = {locale("staff_action"), locale("success")}
|
||||
})
|
||||
end)
|
||||
|
||||
@@ -137,8 +137,8 @@ lib.addCommand("setgroup", {
|
||||
local groupInfo = player.addGroup(args.group, args.rank)
|
||||
if not groupInfo then return end
|
||||
player.notify({
|
||||
title = "Staff action",
|
||||
description = ("Added to group %s, rank %s."):format(groupInfo.label, groupInfo.rankName),
|
||||
title = locale("staff_action"),
|
||||
description = locale("group_added_noti", groupInfo.label, groupInfo.rankName),
|
||||
type = "inform",
|
||||
duration = 10000
|
||||
})
|
||||
@@ -146,8 +146,8 @@ lib.addCommand("setgroup", {
|
||||
local groupInfo = player.removeGroup(args.group)
|
||||
if not groupInfo then return end
|
||||
player.notify({
|
||||
title = "Staff action",
|
||||
description = ("Removed from group %s."):format(groupInfo.label),
|
||||
title = locale("staff_action"),
|
||||
description = locale("group_removed_noti", groupInfo.label),
|
||||
type = "inform",
|
||||
duration = 10000
|
||||
})
|
||||
@@ -155,16 +155,16 @@ lib.addCommand("setgroup", {
|
||||
return
|
||||
end
|
||||
|
||||
if not source then return end
|
||||
if not source or source == 0 then return end
|
||||
TriggerClientEvent("chat:addMessage", source, {
|
||||
color = {50, 100, 235},
|
||||
multiline = true,
|
||||
args = {"Staff action", "success"}
|
||||
args = {locale("staff_action"), locale("success")}
|
||||
})
|
||||
end)
|
||||
|
||||
lib.addCommand("skin", {
|
||||
help = "Admin command, set player into character clothing menu.",
|
||||
help = "Admin command, show character clothing menu for player.",
|
||||
restricted = "group.admin",
|
||||
params = {
|
||||
{
|
||||
@@ -178,7 +178,7 @@ lib.addCommand("skin", {
|
||||
end)
|
||||
|
||||
lib.addCommand("character", {
|
||||
help = "Admin command, set player into character selection menu.",
|
||||
help = "Admin command, show character selection menu for player.",
|
||||
restricted = "group.admin",
|
||||
params = {
|
||||
{
|
||||
@@ -194,84 +194,90 @@ end)
|
||||
lib.addCommand("pay", {
|
||||
help = "give money to nearby player.",
|
||||
params = {
|
||||
{
|
||||
name = "target",
|
||||
type = "playerId",
|
||||
help = "Target player's server id"
|
||||
},
|
||||
{
|
||||
name = "amount",
|
||||
type = "number"
|
||||
type = "number",
|
||||
help = "Amount of cash to give"
|
||||
}
|
||||
}
|
||||
}, function(source, args, raw)
|
||||
if not source then return end
|
||||
local targetPlayer
|
||||
local pedCoords = GetEntityCoords(GetPlayerPed(source))
|
||||
for targetId, targetInfo in pairs(NDCore.players) do
|
||||
local targetCoords = GetEntityCoords(GetPlayerPed(targetId))
|
||||
if #(pedCoords-targetCoords) < 2.0 and targetId ~= source then
|
||||
targetPlayer = targetInfo
|
||||
break
|
||||
end
|
||||
end
|
||||
if not source or source == 0 then return end
|
||||
|
||||
local player = NDCore.getPlayer(source)
|
||||
if not player then return end
|
||||
local success = player.deductMoney("cash", args.amount)
|
||||
local targetPlayer = NDCore.getPlayer(args.target)
|
||||
|
||||
if not player or not targetPlayer then
|
||||
return player.notify({
|
||||
title = "Error",
|
||||
description = locale("no_player_found"),
|
||||
type = "error"
|
||||
})
|
||||
end
|
||||
|
||||
if player.cash < args.amount then
|
||||
return player.notify({
|
||||
title = "Error",
|
||||
description = locale("not_enough_cash"),
|
||||
type = "error"
|
||||
})
|
||||
end
|
||||
|
||||
local playerCoords = GetEntityCoords(GetPlayerPed(player.source))
|
||||
local targetCoords = GetEntityCoords(GetPlayerPed(targetPlayer.source))
|
||||
if #(playerCoords-targetCoords) > 2.0 then
|
||||
return player.notify({
|
||||
title = "Error",
|
||||
description = locale("player_not_nearby"),
|
||||
type = "error"
|
||||
})
|
||||
end
|
||||
|
||||
local success = player.deductMoney("cash", args.amount) and targetPlayer.addMoney("cash", args.amount)
|
||||
if not success then
|
||||
return player.notify({
|
||||
title = "Couldn't give money",
|
||||
title = locale("cant_give_money"),
|
||||
type = "error",
|
||||
duration = 5000
|
||||
})
|
||||
end
|
||||
|
||||
if not targetPlayer or not targetPlayer.addMoney("cash", args.amount) then return end
|
||||
targetPlayer.notify({
|
||||
title = "Money received",
|
||||
description = ("Received $%d in cash"):format(args.amount),
|
||||
title = locale("money_received"),
|
||||
description = locale("money_received2", args.amount),
|
||||
type = "inform",
|
||||
duration = 10000
|
||||
duration = 5000
|
||||
})
|
||||
|
||||
player.notify({
|
||||
title = "Money given",
|
||||
description = ("You gave someone $%d in cash"):format(args.amount),
|
||||
title = locale("money_given"),
|
||||
description = locale("money_given2", args.amount),
|
||||
type = "inform",
|
||||
duration = 10000
|
||||
duration = 5000
|
||||
})
|
||||
end)
|
||||
|
||||
lib.addCommand("unlock", {
|
||||
help = "Admin force unlock vehicles",
|
||||
help = "Admin Command, force unlock a vehicle.",
|
||||
restricted = "group.admin",
|
||||
}, function(source, args, raw)
|
||||
local ped = GetPlayerPed(source)
|
||||
local playerVeh = GetVehiclePedIsIn(ped)
|
||||
local coords = GetEntityCoords(ped)
|
||||
local vehicles = GetAllVehicles()
|
||||
local maxDistance = 2.0
|
||||
local closestVehicle
|
||||
local veh = lib.getClosestVehicle(coords, 2.5, true)
|
||||
|
||||
if not playerVeh or playerVeh == 0 or not DoesEntityExist(playerVeh) then
|
||||
for i=1, #vehicles do
|
||||
local vehicle = vehicles[i]
|
||||
local vehicleCoords = GetEntityCoords(vehicle)
|
||||
local distance = #(coords-vehicleCoords)
|
||||
|
||||
if distance < maxDistance then
|
||||
maxDistance = distance
|
||||
closestVehicle = vehicle
|
||||
end
|
||||
end
|
||||
if not closestVehicle or not DoesEntityExist(closestVehicle) then return end
|
||||
local state = Entity(closestVehicle).state
|
||||
state.locked = false
|
||||
else
|
||||
local state = Entity(playerVeh).state
|
||||
state.hotwired = true
|
||||
end
|
||||
if not veh then return end
|
||||
|
||||
local state = Entity(veh).state
|
||||
state.hotwired = true
|
||||
state.locked = false
|
||||
end)
|
||||
|
||||
lib.addCommand("revive", {
|
||||
help = "Admin command, revive player.",
|
||||
help = "Admin command, revive a player.",
|
||||
restricted = "group.admin",
|
||||
params = {
|
||||
{
|
||||
@@ -287,60 +293,49 @@ lib.addCommand("revive", {
|
||||
end)
|
||||
|
||||
lib.addCommand("dv", {
|
||||
help = "Admin command, delete vehicles within the range.",
|
||||
help = "Admin command, delete vehicles within the range or the closest.",
|
||||
restricted = "group.admin",
|
||||
params = {
|
||||
{
|
||||
name = "range",
|
||||
type = "number",
|
||||
help = "The range to select vehicles for deleteion from",
|
||||
help = "Range to delete vehicles in",
|
||||
optional = true
|
||||
}
|
||||
}
|
||||
}, function(source, args, raw)
|
||||
local ped = GetPlayerPed(source)
|
||||
local veh = GetVehiclePedIsIn(ped)
|
||||
if veh and veh ~= 0 and DoesEntityExist(veh) then
|
||||
DeleteEntity(veh)
|
||||
return TriggerClientEvent("chat:addMessage", source, {
|
||||
color = {50, 100, 235},
|
||||
multiline = true,
|
||||
args = {"Staff action", "deleted 1 vehicle"}
|
||||
})
|
||||
end
|
||||
|
||||
local count = 0
|
||||
local coords = GetEntityCoords(ped)
|
||||
local count = 0
|
||||
local message = nil
|
||||
local veh = lib.getClosestVehicle(coords, 3.0)
|
||||
|
||||
if args.range then
|
||||
for _, veh in ipairs(GetAllVehicles()) do
|
||||
local vehDist = #(GetEntityCoords(veh) - coords)
|
||||
if vehDist < args.range then
|
||||
DeleteEntity(veh)
|
||||
count += 1
|
||||
end
|
||||
local vehicles = lib.getNearbyVehicles(coords, args.range)
|
||||
count = #vehicles
|
||||
|
||||
for i=1, count do
|
||||
local veh = vehicles[i]
|
||||
DeleteEntity(veh.vehicle)
|
||||
end
|
||||
return TriggerClientEvent("chat:addMessage", source, {
|
||||
color = {50, 100, 235},
|
||||
multiline = true,
|
||||
args = {"Staff action", ("deleted %d vehicles"):format(count)}
|
||||
})
|
||||
elseif veh then
|
||||
DeleteEntity(veh)
|
||||
count = 1
|
||||
end
|
||||
|
||||
local closest, dist
|
||||
for _, veh in ipairs(GetAllVehicles()) do
|
||||
local vehDist = #(GetEntityCoords(veh) - coords)
|
||||
if vehDist < 5.0 and not closest or (dist and dist > vehDist) then
|
||||
closest = veh
|
||||
dist = vehDist
|
||||
end
|
||||
local messageLabel = ("%s [dv]"):format(locale("staff_action"))
|
||||
if count == 0 then
|
||||
message = {messageLabel, "no vehicles found"}
|
||||
elseif count == 1 then
|
||||
message = {messageLabel, "deleted 1 vehicle"}
|
||||
else
|
||||
message = {messageLabel, ("deleted %d vehicles"):format(count)}
|
||||
end
|
||||
|
||||
if not closest then return "no vehicle found nearby" end
|
||||
DeleteEntity(closest)
|
||||
TriggerClientEvent("chat:addMessage", source, {
|
||||
color = {50, 100, 235},
|
||||
multiline = true,
|
||||
args = {"Staff action", "deleted 1 vehicle"}
|
||||
args = message
|
||||
})
|
||||
end)
|
||||
|
||||
@@ -411,7 +406,7 @@ lib.addCommand("unfreeze", {
|
||||
end)
|
||||
|
||||
lib.addCommand("vehicle", {
|
||||
help = "Admin command, unfreeze a player.",
|
||||
help = "Admin command, spawn a vehicle.",
|
||||
restricted = "group.admin",
|
||||
params = {
|
||||
{
|
||||
@@ -444,3 +439,45 @@ lib.addCommand("vehicle", {
|
||||
Wait(100)
|
||||
end
|
||||
end)
|
||||
|
||||
lib.addCommand("claim-veh", {
|
||||
help = "Admin command, add a copy of the vehicle you're inside to players garage.",
|
||||
restricted = "group.admin",
|
||||
params = {
|
||||
{
|
||||
name = "target",
|
||||
type = "playerId",
|
||||
help = "Target player's server id"
|
||||
}
|
||||
}
|
||||
}, function(source, args, raw)
|
||||
local player = NDCore.getPlayer(source)
|
||||
if not player then return end
|
||||
|
||||
local targetPlayer = NDCore.getPlayer(args.target)
|
||||
if not targetPlayer then
|
||||
return player.notify({
|
||||
title = "Player not found!",
|
||||
description = "Target player not found, make sure they select a charcter!",
|
||||
type = "error"
|
||||
})
|
||||
end
|
||||
|
||||
|
||||
local properties = lib.callback.await("ND_Vehicles:getPropsFromCurrentVeh", source)
|
||||
if not properties then
|
||||
return player.notify({
|
||||
title = "Vehicle data not found!",
|
||||
description = "The vehicle properties data was not found!",
|
||||
type = "error"
|
||||
})
|
||||
end
|
||||
|
||||
NDCore.setVehicleOwned(targetPlayer.id, properties, true)
|
||||
|
||||
player.notify({
|
||||
title = "Vehicle added!",
|
||||
description = ("The vehicle has now been added to %s's garage!"):format(targetPlayer.name),
|
||||
type = "success"
|
||||
})
|
||||
end)
|
||||
|
||||
@@ -1,117 +0,0 @@
|
||||
-- For support join my discord: https://discord.gg/Z9Mxu72zZ6
|
||||
|
||||
-- Check if discord is connected, and if whitelist is enabled then it will only allow you to join if you have the roles.
|
||||
AddEventHandler("playerConnecting", function(name, setKickReason, deferrals)
|
||||
local player = source
|
||||
local discordIdentifier = NDCore.Functions.GetPlayerIdentifierFromType("discord", player)
|
||||
|
||||
deferrals.defer()
|
||||
Wait(0)
|
||||
deferrals.update("Connecting to discord.")
|
||||
Wait(0)
|
||||
|
||||
if not discordIdentifier then
|
||||
deferrals.done("Your discord isn't connected to FiveM, make sure discord is open and restart FiveM.")
|
||||
else
|
||||
if config.enableDiscordWhitelist then
|
||||
local discordUserId = discordIdentifier:gsub("discord:", "")
|
||||
local discordInfo = NDCore.Functions.GetUserDiscordInfo(discordUserId)
|
||||
for _, whitelistRole in pairs(config.whitelistRoles) do
|
||||
if whitelistRole == 0 or whitelistRole == "0" or (discordInfo and discordInfo.roles[whitelistRole]) then
|
||||
deferrals.done()
|
||||
break
|
||||
end
|
||||
end
|
||||
deferrals.done(config.notWhitelistedMessage)
|
||||
else
|
||||
deferrals.done()
|
||||
end
|
||||
end
|
||||
end)
|
||||
|
||||
-- Getting all the characters the player has and returning them to the client.
|
||||
RegisterNetEvent("ND:GetCharacters", function()
|
||||
local player = source
|
||||
TriggerClientEvent("ND:returnCharacters", player, NDCore.Functions.GetPlayerCharacters(player))
|
||||
end)
|
||||
|
||||
-- Creating a new character.
|
||||
RegisterNetEvent("ND:newCharacter", function(newCharacter)
|
||||
local player = source
|
||||
NDCore.Functions.CreateCharacter(player, newCharacter.firstName, newCharacter.lastName, newCharacter.dob, newCharacter.gender, newCharacter.cash, newCharacter.bank)
|
||||
end)
|
||||
|
||||
-- Update the character info when edited.
|
||||
RegisterNetEvent("ND:editCharacter", function(newCharacter)
|
||||
local player = source
|
||||
local characters = NDCore.Functions.GetPlayerCharacters(player)
|
||||
if not characters[newCharacter.id] then return end
|
||||
NDCore.Functions.UpdateCharacterData(newCharacter.id, newCharacter.firstName, newCharacter.lastName, newCharacter.dob, newCharacter.gender)
|
||||
end)
|
||||
|
||||
-- Delete character from database.
|
||||
RegisterNetEvent("ND:deleteCharacter", function(characterId)
|
||||
local player = source
|
||||
local characters = NDCore.Functions.GetPlayerCharacters(player)
|
||||
if not characters[characterId] then return end
|
||||
NDCore.Functions.DeleteCharacter(characterId)
|
||||
end)
|
||||
|
||||
-- add a player to the table.
|
||||
RegisterNetEvent("ND:setCharacterOnline", function(id)
|
||||
local player = source
|
||||
local characters = NDCore.Functions.GetPlayerCharacters(player)
|
||||
if not characters[id] then return end
|
||||
NDCore.Functions.SetActiveCharacter(player, id)
|
||||
end)
|
||||
|
||||
-- Update the characters clothes.
|
||||
RegisterNetEvent("ND:updateClothes", function(clothing)
|
||||
local player = source
|
||||
local character = NDCore.Players[player]
|
||||
NDCore.Functions.SetPlayerData(character.id, "clothing", clothing)
|
||||
end)
|
||||
|
||||
-- Disconnecting a player
|
||||
RegisterNetEvent("ND:exitGame", function()
|
||||
local player = source
|
||||
DropPlayer(player, "Disconnected.")
|
||||
end)
|
||||
|
||||
-- Remove player from NDCore.Players table when they leave.
|
||||
AddEventHandler("playerDropped", function()
|
||||
local player = source
|
||||
local character = NDCore.Players[player]
|
||||
if character then
|
||||
local ped = GetPlayerPed(player)
|
||||
local lastLocation = GetEntityCoords(ped)
|
||||
NDCore.Functions.UpdateLastLocation(character.id, {x = lastLocation.x, y = lastLocation.y, z = lastLocation.z})
|
||||
end
|
||||
TriggerEvent("ND:characterUnloaded", player, character)
|
||||
character = nil
|
||||
end)
|
||||
|
||||
-- Get player discord info on join.
|
||||
AddEventHandler("playerJoining", function()
|
||||
local src = source
|
||||
|
||||
local discordUserId = NDCore.Functions.GetPlayerIdentifierFromType("discord", src):gsub("discord:", "")
|
||||
local discordInfo = NDCore.Functions.GetUserDiscordInfo(discordUserId)
|
||||
|
||||
NDCore.PlayersDiscordInfo[src] = discordInfo
|
||||
end)
|
||||
|
||||
AddEventHandler("onResourceStart", function(resourceName)
|
||||
if (GetCurrentResourceName() ~= resourceName) then
|
||||
return
|
||||
end
|
||||
Wait(1000)
|
||||
|
||||
if not next(NDCore.PlayersDiscordInfo) then
|
||||
for _, playerId in ipairs(GetPlayers()) do
|
||||
local discordUserId = NDCore.Functions.GetPlayerIdentifierFromType("discord", playerId):gsub("discord:", "")
|
||||
local discordInfo = NDCore.Functions.GetUserDiscordInfo(discordUserId)
|
||||
NDCore.PlayersDiscordInfo[tonumber(playerId)] = discordInfo
|
||||
end
|
||||
end
|
||||
end)
|
||||
@@ -1,3 +1,10 @@
|
||||
function NDCore.getPlayerIdentifierByType(src, indentifierType)
|
||||
if Config.sv_lan then
|
||||
return ("%s:sv_lan"):format(indentifierType)
|
||||
end
|
||||
return GetPlayerIdentifierByType(src, indentifierType)
|
||||
end
|
||||
|
||||
---@param src number
|
||||
---@return table
|
||||
function NDCore.getPlayer(src)
|
||||
@@ -11,7 +18,16 @@ function NDCore.getPlayers(key, value, returnArray)
|
||||
if not key or not value then return NDCore.players end
|
||||
|
||||
local players = {}
|
||||
local keyTypes = {id = "id", firstname = "firstname", lastname = "lastname", gender = "gender", groups = "groups"}
|
||||
local keyTypes = {
|
||||
id = "id",
|
||||
firstname = "firstname",
|
||||
lastname = "lastname",
|
||||
gender = "gender",
|
||||
groups = "groups",
|
||||
job = "job",
|
||||
gender = "gender"
|
||||
}
|
||||
|
||||
local findBy = keyTypes[key] or "metadata"
|
||||
|
||||
if findBy then
|
||||
@@ -34,6 +50,13 @@ function NDCore.getPlayerServerInfo(source)
|
||||
return PlayersInfo[source]
|
||||
end
|
||||
|
||||
function NDCore.getConfig(info)
|
||||
if not info then
|
||||
return Config
|
||||
end
|
||||
return Config[info]
|
||||
end
|
||||
|
||||
---@param fileLocation string|tabale
|
||||
---@return boolean
|
||||
function NDCore.loadSQL(fileLocation, resource)
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
lib.locale()
|
||||
NDCore = {}
|
||||
NDCore.players = {}
|
||||
PlayersInfo = {}
|
||||
@@ -7,6 +8,7 @@ local tempPlayersInfo = {}
|
||||
Config = {
|
||||
serverName = GetConvar("core:serverName", "Unconfigured ND-Core Server"),
|
||||
discordInvite = GetConvar("core:discordInvite", "https://discord.gg/Z9Mxu72zZ6"),
|
||||
discordMemeberRequired = GetConvarInt("core:discordMemeberRequired", 1) == 1,
|
||||
discordAppId = GetConvar("core:discordAppId", "858146067018416128"),
|
||||
discordAsset = GetConvar("core:discordAsset", "andyyy"),
|
||||
discordAssetSmall = GetConvar("core:discordAssetSmall", "andyyy"),
|
||||
@@ -23,14 +25,19 @@ Config = {
|
||||
groups = json.decode(GetConvar("core:groups", "[]")),
|
||||
admins = json.decode(GetConvar("core:admins", "[]")),
|
||||
adminDiscordRoles = json.decode(GetConvar("core:adminDiscordRoles", "[]")),
|
||||
groupRoles = json.decode(GetConvar("core:groupRoles", "[]")),
|
||||
multiCharacter = false,
|
||||
compatibility = json.decode(GetConvar("core:compatibility", "[]"))
|
||||
compatibility = json.decode(GetConvar("core:compatibility", "[]")),
|
||||
sv_lan = GetConvar("sv_lan", "false") == "true",
|
||||
platePattern = GetConvar("core:platePattern", "11AAA111")
|
||||
}
|
||||
|
||||
SetConvarServerInfo("Discord", Config.discordInvite)
|
||||
SetConvarServerInfo("NDCore", GetResourceMetadata(resourceName, "version", 0) or "invalid")
|
||||
SetConvarReplicated("inventory:framework", "nd")
|
||||
|
||||
lib.versionCheck('ND-Framework/ND_Core')
|
||||
|
||||
local function getIdentifierList(src)
|
||||
local list = {}
|
||||
for i=0, GetNumPlayerIdentifiers(src) do
|
||||
@@ -41,13 +48,23 @@ local function getIdentifierList(src)
|
||||
list[identifierType] = identifier
|
||||
end
|
||||
end
|
||||
|
||||
if Config.sv_lan then
|
||||
list[Config.characterIdentifier] = NDCore.getPlayerIdentifierByType(src, Config.characterIdentifier)
|
||||
end
|
||||
|
||||
return list
|
||||
end
|
||||
|
||||
AddEventHandler("playerJoining", function(oldId)
|
||||
local src = source
|
||||
PlayersInfo[src] = tempPlayersInfo[oldId]
|
||||
tempPlayersInfo[oldId] = nil
|
||||
local oldTempId = tonumber(oldId)
|
||||
PlayersInfo[src] = tempPlayersInfo[oldTempId]
|
||||
tempPlayersInfo[oldTempId] = nil
|
||||
|
||||
if Config.sv_lan then
|
||||
lib.addPrincipal(("player.%s"):format(src), "group.admin")
|
||||
end
|
||||
|
||||
if Config.multiCharacter then return end
|
||||
Wait(3000)
|
||||
@@ -93,22 +110,33 @@ AddEventHandler("playerConnecting", function(name, setKickReason, deferrals)
|
||||
local tempSrc = source
|
||||
local identifiers = getIdentifierList(tempSrc)
|
||||
local mainIdentifier = identifiers[Config.characterIdentifier]
|
||||
local discordInfo = {}
|
||||
local discordInfo = nil
|
||||
|
||||
deferrals.defer()
|
||||
Wait(0)
|
||||
|
||||
if mainIdentifier and Config.discordBotToken ~= "false" and Config.discordGuildId ~= "false" and not discordInfo then
|
||||
if mainIdentifier and Config.discordBotToken ~= "false" and Config.discordGuildId ~= "false" then
|
||||
discordInfo = checkDiscordIdentifier(identifiers)
|
||||
if not discordInfo then
|
||||
deferrals.done(("Your discord was not found, join our discord here: %s."):format(Config.discordInvite))
|
||||
if not discordInfo and Config.discordMemeberRequired and not Config.sv_lan then
|
||||
deferrals.done(locale("not_in_discord", Config.discordInvite))
|
||||
Wait(0)
|
||||
end
|
||||
end
|
||||
|
||||
deferrals.update("Connecting...")
|
||||
deferrals.update(locale("connecting"))
|
||||
Wait(0)
|
||||
|
||||
if Config.sv_lan then
|
||||
tempPlayersInfo[tempSrc] = {
|
||||
identifiers = {
|
||||
[Config.characterIdentifier] = "sv_lan"
|
||||
},
|
||||
discord = discordInfo
|
||||
}
|
||||
deferrals.done()
|
||||
return
|
||||
end
|
||||
|
||||
if mainIdentifier then
|
||||
tempPlayersInfo[tempSrc] = {
|
||||
identifiers = identifiers,
|
||||
@@ -116,7 +144,7 @@ AddEventHandler("playerConnecting", function(name, setKickReason, deferrals)
|
||||
}
|
||||
deferrals.done()
|
||||
else
|
||||
deferrals.done(("Your %s was not found."):format(Config.characterIdentifier))
|
||||
deferrals.done(locale("identifier_not_found", Config.characterIdentifier))
|
||||
Wait(0)
|
||||
end
|
||||
end)
|
||||
@@ -136,7 +164,8 @@ AddEventHandler("onResourceStop", function(name)
|
||||
end
|
||||
end)
|
||||
|
||||
SetTimeout(500, function()
|
||||
MySQL.ready(function()
|
||||
Wait(100)
|
||||
NDCore.loadSQL({
|
||||
"database/characters.sql",
|
||||
"database/vehicles.sql"
|
||||
@@ -152,3 +181,10 @@ RegisterNetEvent("ND:playerEliminated", function(info)
|
||||
deathInfo = info
|
||||
})
|
||||
end)
|
||||
|
||||
RegisterNetEvent("ND:updateClothing", function(clothing)
|
||||
local src = source
|
||||
local player = NDCore.getPlayer(src)
|
||||
if not player or not clothing or type(clothing) ~= "table" then return end
|
||||
player.setMetadata("clothing", clothing)
|
||||
end)
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
local avoidSavingLastLocations = {}
|
||||
|
||||
local function removeCharacterFunctions(character)
|
||||
local newData = {}
|
||||
for k, v in pairs(character) do
|
||||
@@ -25,6 +27,7 @@ local function createCharacterTable(info)
|
||||
gender = info.gender,
|
||||
cash = info.cash,
|
||||
bank = info.bank,
|
||||
phonenumber = info.phonenumber,
|
||||
groups = info.groups,
|
||||
metadata = info.metadata,
|
||||
inventory = info.inventory
|
||||
@@ -65,7 +68,7 @@ local function createCharacterTable(info)
|
||||
function self.depositMoney(amount)
|
||||
local amount = tonumber(amount)
|
||||
if not amount or self.cash < amount or amount <= 0 then return end
|
||||
return self.deductMoney("cash", amount, "Deposit") and self.addMoney("bank", amount, "Deposit")
|
||||
return self.deductMoney("cash", amount, locale("deposit")) and self.addMoney("bank", amount, locale("deposit"))
|
||||
end
|
||||
|
||||
---@param amount number
|
||||
@@ -73,7 +76,7 @@ local function createCharacterTable(info)
|
||||
function self.withdrawMoney(amount)
|
||||
local amount = tonumber(amount)
|
||||
if not amount or self.bank < amount or amount <= 0 then return end
|
||||
return self.deductMoney("bank", amount, "Withdraw") and self.addMoney("cash", amount, "Withdraw")
|
||||
return self.deductMoney("bank", amount, locale("withdraw")) and self.addMoney("cash", amount, locale("withdraw"))
|
||||
end
|
||||
|
||||
---@param data string
|
||||
@@ -112,7 +115,8 @@ local function createCharacterTable(info)
|
||||
TriggerEvent("ND:moneyChange", self.source, key, value, "set", reason)
|
||||
end
|
||||
end
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self))
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self), key)
|
||||
TriggerEvent("ND:updateCharacter", self, key)
|
||||
end
|
||||
|
||||
---@param key string|table
|
||||
@@ -126,7 +130,8 @@ local function createCharacterTable(info)
|
||||
else
|
||||
self.metadata[key] = value
|
||||
end
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self))
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self), "metadata")
|
||||
TriggerEvent("ND:updateCharacter", self, "metadata")
|
||||
return self.metadata
|
||||
end
|
||||
|
||||
@@ -142,30 +147,61 @@ local function createCharacterTable(info)
|
||||
-- Unload and save character
|
||||
function self.unload()
|
||||
if not NDCore.players[self.source] then return end
|
||||
|
||||
for name, _ in pairs(self.groups) do
|
||||
lib.removePrincipal(self.source, ("group.%s"):format(name))
|
||||
end
|
||||
|
||||
local ped = GetPlayerPed(self.source)
|
||||
if ped then
|
||||
local coords = GetEntityCoords(ped)
|
||||
local heading = GetEntityHeading(ped)
|
||||
self.setMetadata("location", {
|
||||
x = coords.x,
|
||||
y = coords.y,
|
||||
z = coords.z,
|
||||
w = heading
|
||||
})
|
||||
local saveLocation = true
|
||||
|
||||
for i=1, #avoidSavingLastLocations do
|
||||
local loc = avoidSavingLastLocations[i]
|
||||
if #(loc.coords-coords) < loc.dist then
|
||||
saveLocation = false
|
||||
end
|
||||
end
|
||||
|
||||
if saveLocation then
|
||||
self.setMetadata("location", {
|
||||
x = coords.x,
|
||||
y = coords.y,
|
||||
z = coords.z,
|
||||
w = heading
|
||||
})
|
||||
end
|
||||
end
|
||||
|
||||
self.triggerEvent("ND:characterUnloaded")
|
||||
TriggerEvent("ND:characterUnloaded", self.source, self)
|
||||
|
||||
local saved = self.save()
|
||||
NDCore.players[self.source] = nil
|
||||
|
||||
return saved
|
||||
end
|
||||
|
||||
-- Save character information to database
|
||||
function self.save()
|
||||
local affectedRows = MySQL.update.await("UPDATE nd_characters SET name = ?, firstname = ?, lastname = ?, dob = ?, gender = ?, cash = ?, bank = ?, groups = ?, metadata = ? WHERE charid = ?", {
|
||||
function self.save(key)
|
||||
if key then
|
||||
local charData = self[key]
|
||||
if not charData or type(charData) == "function" then
|
||||
return lib.print.error(key, "Is not valid character data.")
|
||||
end
|
||||
|
||||
if type(charData) == "table" then
|
||||
charData = json.encode(charData)
|
||||
end
|
||||
|
||||
local query = ("UPDATE nd_characters SET `%s` = ? WHERE charid = ?"):format(key)
|
||||
local affectedRows = MySQL.update.await(query, {charData, self.id})
|
||||
return affectedRows > 0
|
||||
end
|
||||
|
||||
local affectedRows = MySQL.update.await("UPDATE nd_characters SET name = ?, firstname = ?, lastname = ?, dob = ?, gender = ?, cash = ?, bank = ?, phonenumber = ?, `groups` = ?, metadata = ? WHERE charid = ?", {
|
||||
self.name,
|
||||
self.firstname,
|
||||
self.lastname,
|
||||
@@ -173,6 +209,7 @@ local function createCharacterTable(info)
|
||||
self.gender,
|
||||
self.cash,
|
||||
self.bank,
|
||||
self.phonenumber,
|
||||
json.encode(self.groups),
|
||||
json.encode(self.metadata),
|
||||
self.id
|
||||
@@ -202,11 +239,24 @@ local function createCharacterTable(info)
|
||||
}
|
||||
|
||||
if licenses then
|
||||
self.metadata.licenses[#licenses+1] = license
|
||||
local found = false
|
||||
|
||||
for i=1, #licenses do
|
||||
if licenses[i].type == licenseType then
|
||||
self.metadata.licenses[i] = license
|
||||
found = true
|
||||
break
|
||||
end
|
||||
end
|
||||
|
||||
if not found then
|
||||
self.metadata.licenses[#licenses+1] = license
|
||||
end
|
||||
else
|
||||
self.metadata.licenses = {license}
|
||||
end
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self))
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self), "metadata")
|
||||
TriggerEvent("ND:updateCharacter", self, "metadata")
|
||||
end
|
||||
|
||||
function self.getLicense(identifier)
|
||||
@@ -252,11 +302,7 @@ local function createCharacterTable(info)
|
||||
|
||||
function self.notify(...)
|
||||
if not self.source then return end
|
||||
if GetResourceState("ModernHUD") == "started" then
|
||||
TriggerClientEvent("ModernHUD:notify", self.source, ...)
|
||||
elseif GetResourceState("ox_lib") == "started" then
|
||||
TriggerClientEvent("ox_lib:notify", self.source, ...)
|
||||
end
|
||||
TriggerClientEvent("ox_lib:notify", self.source, ...)
|
||||
return true
|
||||
end
|
||||
|
||||
@@ -293,6 +339,12 @@ local function createCharacterTable(info)
|
||||
self.addGroup("admin")
|
||||
end
|
||||
end
|
||||
|
||||
for group, role in pairs(Config.groupRoles) do
|
||||
if lib.table.contains(roles, role) then
|
||||
self.addGroup(group)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
for name, _ in pairs(self.groups) do
|
||||
@@ -307,23 +359,38 @@ local function createCharacterTable(info)
|
||||
---@param rank number
|
||||
---@param isJob boolean
|
||||
---@return boolean
|
||||
function self.addGroup(name, rank, isJob)
|
||||
function self.addGroup(name, rank, customGroup, isJob)
|
||||
local groupRank = tonumber(rank) or 1
|
||||
local groupInfo = Config.groups[name]
|
||||
-- if not groupInfo then return end
|
||||
local groupInfo = lib.table.deepclone(Config.groups?[name] or {})
|
||||
local bossRank = groupInfo?.minimumBossRank
|
||||
|
||||
for k, v in pairs(customGroup or {}) do
|
||||
groupInfo[k] = v
|
||||
end
|
||||
|
||||
if isJob then
|
||||
for _, group in pairs(self.groups) do
|
||||
group.isJob = nil
|
||||
end
|
||||
end
|
||||
|
||||
self.groups[name] = {
|
||||
label = groupInfo and groupInfo.label or name,
|
||||
rankName = groupInfo and groupInfo.ranks[groupRank] or groupRank,
|
||||
name = name,
|
||||
label = groupInfo?.label or name,
|
||||
rankName = groupInfo?.ranks?[groupRank] or groupRank,
|
||||
rank = groupRank,
|
||||
isJob = isJob
|
||||
isJob = isJob,
|
||||
isBoss = bossRank and groupRank >= bossRank,
|
||||
metadata = groupInfo.metadata or {}
|
||||
}
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self))
|
||||
|
||||
if not isJob then
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self), "groups")
|
||||
TriggerEvent("ND:updateCharacter", self, "groups")
|
||||
end
|
||||
|
||||
lib.addPrincipal(self.source, ("group.%s"):format(name))
|
||||
|
||||
return self.groups[name]
|
||||
end
|
||||
|
||||
@@ -337,8 +404,16 @@ local function createCharacterTable(info)
|
||||
function self.removeGroup(name)
|
||||
local group = self.groups[name]
|
||||
if not group then return end
|
||||
|
||||
if self.job == name then
|
||||
self.job = nil
|
||||
self.jobInfo = nil
|
||||
end
|
||||
|
||||
self.groups[name] = nil
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self))
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self), "groups")
|
||||
TriggerEvent("ND:updateCharacter", self, "groups")
|
||||
TriggerEvent("ND:groupRemoved", self, group)
|
||||
lib.removePrincipal(self.source, ("group.%s"):format(name))
|
||||
return group
|
||||
end
|
||||
@@ -346,14 +421,15 @@ local function createCharacterTable(info)
|
||||
---@param name string
|
||||
---@param rank number
|
||||
---@return boolean
|
||||
function self.setJob(name, rank)
|
||||
function self.setJob(name, rank, customGroup)
|
||||
self.removeGroup(self.job)
|
||||
local job = self.addGroup(name, rank, true)
|
||||
local jobName, jobInfo = self.getJob()
|
||||
if jobInfo then
|
||||
self.job = jobName
|
||||
self.jobInfo = jobInfo
|
||||
local job = self.addGroup(name, rank, customGroup, true)
|
||||
if job then
|
||||
self.job = job.name
|
||||
self.jobInfo = job
|
||||
end
|
||||
self.triggerEvent("ND:updateCharacter", removeCharacterFunctions(self), "job")
|
||||
TriggerEvent("ND:updateCharacter", self, "job")
|
||||
return job
|
||||
end
|
||||
|
||||
@@ -376,11 +452,40 @@ local function createCharacterTable(info)
|
||||
return self
|
||||
end
|
||||
|
||||
function NDCore.avoidSavingLocation(coords, dist)
|
||||
avoidSavingLastLocations[#avoidSavingLastLocations+1] = { coords = coords, dist = dist}
|
||||
end
|
||||
|
||||
function NDCore.validateCharacterData(charInfo)
|
||||
local errors = {}
|
||||
|
||||
local function checkLength(field, value, maxLength)
|
||||
if type(value) ~= "string" then return end
|
||||
if #value > maxLength then
|
||||
table.insert(errors, string.format("%s is too long (max %d, got %d)", field, maxLength, #value))
|
||||
end
|
||||
end
|
||||
|
||||
if charInfo.name then checkLength("game name", charInfo.name, 50) end
|
||||
if charInfo.firstname then checkLength("firstname", charInfo.firstname, 50) end
|
||||
if charInfo.lastname then checkLength("lastname", charInfo.lastname, 50) end
|
||||
if charInfo.dob then checkLength("dob", charInfo.dob, 50) end
|
||||
if charInfo.gender then checkLength("gender", charInfo.gender, 50) end
|
||||
if type(charInfo.cash) ~= "number" then table.insert(errors, "cash must be a number") end
|
||||
if type(charInfo.bank) ~= "number" then table.insert(errors, "bank must be a number") end
|
||||
|
||||
if #errors > 0 then
|
||||
return false, errors
|
||||
else
|
||||
return true, {}
|
||||
end
|
||||
end
|
||||
|
||||
---@param src number
|
||||
---@param info table
|
||||
---@return table
|
||||
function NDCore.newCharacter(src, info)
|
||||
local identifier = GetPlayerIdentifierByType(src, Config.characterIdentifier)
|
||||
local identifier = NDCore.getPlayerIdentifierByType(src, Config.characterIdentifier)
|
||||
if not identifier then return end
|
||||
|
||||
local charInfo = {
|
||||
@@ -393,12 +498,25 @@ function NDCore.newCharacter(src, info)
|
||||
gender = info.gender or "",
|
||||
cash = info.cash or 0,
|
||||
bank = info.bank or 0,
|
||||
phonenumber = info.phonenumber,
|
||||
groups = info.groups or {},
|
||||
metadata = info.metadata or {},
|
||||
inventory = info.inventory or {},
|
||||
inventory = info.inventory or {}
|
||||
}
|
||||
|
||||
charInfo.id = MySQL.insert.await("INSERT INTO nd_characters (identifier, name, firstname, lastname, dob, gender, cash, bank, groups, metadata) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", {
|
||||
local valid, issues = NDCore.validateCharacterData(charInfo)
|
||||
if not valid then
|
||||
for _, err in ipairs(issues) do
|
||||
Wait(100)
|
||||
TriggerClientEvent("ND:notifyClient", src, {
|
||||
description = err,
|
||||
type = "error"
|
||||
})
|
||||
end
|
||||
return
|
||||
end
|
||||
|
||||
charInfo.id = MySQL.insert.await("INSERT INTO nd_characters (identifier, name, firstname, lastname, dob, gender, cash, bank, phonenumber, `groups`, metadata, inventory) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", {
|
||||
identifier,
|
||||
charInfo.name,
|
||||
charInfo.firstname,
|
||||
@@ -407,8 +525,10 @@ function NDCore.newCharacter(src, info)
|
||||
charInfo.gender,
|
||||
charInfo.cash,
|
||||
charInfo.bank,
|
||||
charInfo.phonenumber,
|
||||
json.encode(charInfo.groups),
|
||||
json.encode(charInfo.metadata)
|
||||
json.encode(charInfo.metadata),
|
||||
json.encode(charInfo.inventory)
|
||||
})
|
||||
|
||||
return createCharacterTable(charInfo)
|
||||
@@ -419,7 +539,7 @@ end
|
||||
function NDCore.fetchCharacter(id, src)
|
||||
local result
|
||||
if src then
|
||||
result = MySQL.query.await("SELECT * FROM nd_characters WHERE charid = ? and identifier = ?", {id, GetPlayerIdentifierByType(src, Config.characterIdentifier)})
|
||||
result = MySQL.query.await("SELECT * FROM nd_characters WHERE charid = ? and identifier = ?", {id, NDCore.getPlayerIdentifierByType(src, Config.characterIdentifier)})
|
||||
else
|
||||
result = MySQL.query.await("SELECT * FROM nd_characters WHERE charid = ?", {id})
|
||||
end
|
||||
@@ -437,6 +557,7 @@ function NDCore.fetchCharacter(id, src)
|
||||
gender = info.gender,
|
||||
cash = info.cash,
|
||||
bank = info.bank,
|
||||
phonenumber = info.phonenumber,
|
||||
groups = json.decode(info.groups),
|
||||
metadata = json.decode(info.metadata),
|
||||
inventory = json.decode(info.inventory)
|
||||
@@ -447,7 +568,7 @@ end
|
||||
---@return table
|
||||
function NDCore.fetchAllCharacters(src)
|
||||
local characters = {}
|
||||
local result = MySQL.query.await("SELECT * FROM nd_characters WHERE identifier = ?", {GetPlayerIdentifierByType(src, Config.characterIdentifier)})
|
||||
local result = MySQL.query.await("SELECT * FROM nd_characters WHERE identifier = ?", {NDCore.getPlayerIdentifierByType(src, Config.characterIdentifier)})
|
||||
|
||||
for i=1, #result do
|
||||
local info = result[i]
|
||||
@@ -462,9 +583,10 @@ function NDCore.fetchAllCharacters(src)
|
||||
gender = info.gender,
|
||||
cash = info.cash,
|
||||
bank = info.bank,
|
||||
phonenumber = info.phonenumber,
|
||||
groups = json.decode(info.groups),
|
||||
metadata = json.decode(info.metadata),
|
||||
inventory = json.decode(info.inventory),
|
||||
inventory = json.decode(info.inventory)
|
||||
})
|
||||
end
|
||||
return characters
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
local ox_inventory
|
||||
local inventoryStarted = false
|
||||
local spawnedPlayerVehicles = {}
|
||||
local vehicleTypes = json.decode(GetResourceKvpString("ND_Core:vehTypes") or "[]")
|
||||
|
||||
NDCore.isResourceStarted("ox_inventory", function(started)
|
||||
inventoryStarted = started
|
||||
@@ -8,23 +9,62 @@ NDCore.isResourceStarted("ox_inventory", function(started)
|
||||
ox_inventory = exports.ox_inventory
|
||||
end)
|
||||
|
||||
local function getVehicleType(model)
|
||||
local tempVehicle = CreateVehicle(model, 0, 0, 0, 0, true, true)
|
||||
local function getVehicleType(coords, model)
|
||||
if vehicleTypes[model] then
|
||||
return vehicleTypes[model]
|
||||
end
|
||||
|
||||
local tempVehicle = CreateVehicle(model, coords.x, coords.y, coords.z-5.0, coords.w, true, false)
|
||||
local time = os.time()
|
||||
while not DoesEntityExist(tempVehicle) and time-os.time() < 5 do Wait(5) end
|
||||
|
||||
|
||||
while not DoesEntityExist(tempVehicle) and os.time()-time < 5 do Wait(0) end
|
||||
if not DoesEntityExist(tempVehicle) then return end
|
||||
local entityType = GetVehicleType(tempVehicle)
|
||||
|
||||
local vehType = GetVehicleType(tempVehicle)
|
||||
DeleteEntity(tempVehicle)
|
||||
return entityType
|
||||
|
||||
vehicleTypes[model] = vehType
|
||||
SetResourceKvp("ND_Core:vehTypes", json.encode(vehicleTypes))
|
||||
|
||||
return vehType
|
||||
end
|
||||
|
||||
local function generatePlate()
|
||||
local plate = {}
|
||||
for i=1, 8 do
|
||||
plate[i] = math.random(0, 1) == 1 and string.char(math.random(65, 90)) or math.random(0, 9)
|
||||
local i = 1
|
||||
local p = 1
|
||||
|
||||
-- ensure pattern exists and pad to 8 chars
|
||||
local pattern = Config.platePattern
|
||||
if #pattern < 8 then
|
||||
pattern = pattern .. string.rep(" ", 8 - #pattern)
|
||||
end
|
||||
|
||||
while i <= 8 do
|
||||
local char = pattern:sub(p, p)
|
||||
|
||||
if char == "^" then
|
||||
-- literal next character
|
||||
p = p + 1
|
||||
plate[i] = pattern:sub(p, p)
|
||||
elseif char == "1" then
|
||||
plate[i] = tostring(math.random(0, 9))
|
||||
elseif char == "A" then
|
||||
plate[i] = string.char(math.random(65, 90)) -- A–Z
|
||||
elseif char == "." then
|
||||
if math.random(0, 1) == 0 then
|
||||
plate[i] = tostring(math.random(0, 9))
|
||||
else
|
||||
plate[i] = string.char(math.random(65, 90))
|
||||
end
|
||||
else
|
||||
plate[i] = char
|
||||
end
|
||||
|
||||
i = i + 1
|
||||
p = p + 1
|
||||
end
|
||||
|
||||
return table.concat(plate)
|
||||
end
|
||||
|
||||
@@ -90,18 +130,35 @@ function NDCore.getVehicle(entity)
|
||||
if saveProperties and self.id and self.owner then
|
||||
local properties = lib.callback.await("ND_Vehicles:getProps", NetworkGetEntityOwner(entity), self.netId)
|
||||
if properties then
|
||||
if self.properties?.callsign then
|
||||
properties.callsign = true
|
||||
end
|
||||
MySQL.query("UPDATE nd_vehicles SET properties = ? WHERE id = ?", {json.encode(properties), self.id})
|
||||
end
|
||||
end
|
||||
DeleteEntity(entity)
|
||||
end
|
||||
|
||||
|
||||
-- remvoe vehicle from db.
|
||||
function self.remove(keepEntity)
|
||||
if not keepEntity and DoesEntityExist(entity) then
|
||||
DeleteEntity(entity)
|
||||
end
|
||||
MySQL.query("DELETE FROM nd_vehicles WHERE id = ?", {self.id})
|
||||
end
|
||||
|
||||
--- set vehicle properties
|
||||
---@param props table
|
||||
function self.setProperties(props)
|
||||
if not DoesEntityExist(entity) then return end
|
||||
local properties = type(props) == "string" and json.decode(props) or props
|
||||
local state = Entity(entity).state
|
||||
|
||||
if self.properties?.callsign then
|
||||
properties.callsign = true
|
||||
end
|
||||
|
||||
state.props = properties
|
||||
self.properties = properties
|
||||
|
||||
@@ -148,13 +205,22 @@ function NDCore.getVehicle(entity)
|
||||
|
||||
function self.setMetadata(key, value)
|
||||
self.metadata[key] = value
|
||||
|
||||
if DoesEntityExist(entity) then
|
||||
local state = Entity(self.entity).state
|
||||
local metadata = state.metadata
|
||||
metadata[key] = value
|
||||
state.metadata = metadata
|
||||
|
||||
if not state.metadata then
|
||||
state.metadata = self.metadata
|
||||
else
|
||||
state.metadata[key] = value
|
||||
end
|
||||
end
|
||||
if not self.id or not self.owner then return end
|
||||
|
||||
if not self.id or not self.owner then
|
||||
lib.print.debug(('Skipped storing metadata for vehicle %s as it does not have an id/owner associated with it.'):format(self.entity))
|
||||
return
|
||||
end
|
||||
|
||||
MySQL.query("UPDATE nd_vehicles SET metadata = ? WHERE id = ?", {json.encode(self.metadata), self.id})
|
||||
end
|
||||
|
||||
@@ -245,14 +311,14 @@ function NDCore.createVehicle(info)
|
||||
end
|
||||
|
||||
local model = info.model or properties.model
|
||||
local vehType = getVehicleType(model)
|
||||
local vehType = getVehicleType(spawnCoords, model)
|
||||
if not vehType then
|
||||
return Citizen.Trace("NDCore.createVehicle", "vehType not found")
|
||||
end
|
||||
|
||||
local veh = CreateVehicleServerSetter(model, vehType, spawnCoords.x, spawnCoords.y, spawnCoords.z, spawnCoords.w)
|
||||
local time = os.time()
|
||||
while not DoesEntityExist(veh) and time-os.time() < 5 do Wait(5) end
|
||||
while not DoesEntityExist(veh) and os.time()-time < 5 do Wait(5) end
|
||||
if not veh or not DoesEntityExist(veh) then
|
||||
return Citizen.Trace("NDCore.createVehicle", "vehicle entity doesn't exist")
|
||||
end
|
||||
@@ -339,14 +405,14 @@ function NDCore.transferVehicleOwnership(vehicleId, fromSource, toSource)
|
||||
end
|
||||
|
||||
playerFrom.notify({
|
||||
title = "Ownership transfered",
|
||||
description = ("Vehicle ownership of %s has been transfered."):format(vehicle.plate),
|
||||
title = locale("vehicle_ownership_transfered"),
|
||||
description = locale("vehicle_ownership_transfered2", vehicle.plate),
|
||||
position = "bottom-right",
|
||||
type = "success"
|
||||
})
|
||||
playerTo.notify({
|
||||
title = "Ownership received",
|
||||
description = ("Received vehicle ownership of %s."):format(vehicle.plate),
|
||||
title = locale("vehicle_ownership_received"),
|
||||
description = locale("vehicle_ownership_received2", vehicle.plate),
|
||||
position = "bottom-right"
|
||||
})
|
||||
return true
|
||||
@@ -380,15 +446,15 @@ function NDCore.shareVehicleKeys(source, target, vehicle)
|
||||
local plate = GetVehicleNumberPlateText(vehicle)
|
||||
|
||||
player.notify({
|
||||
title = "Keys shared",
|
||||
description = ("You've shared vehicle keys to %s."):format(plate),
|
||||
title = locale("keys_shared"),
|
||||
description = locale("keys_shared2", plate),
|
||||
position = "bottom-right",
|
||||
type = "success",
|
||||
type = "success"
|
||||
})
|
||||
targetPlayer.notify({
|
||||
title = "Keys received",
|
||||
description = ("Received vehicle keys to %s."):format(plate),
|
||||
position = "bottom-right",
|
||||
title = locale("keys_received"),
|
||||
description = locale("keys_received2", plate),
|
||||
position = "bottom-right"
|
||||
})
|
||||
return true
|
||||
end
|
||||
@@ -403,14 +469,31 @@ function NDCore.spawnOwnedVehicle(source, vehicleId, coords, heading)
|
||||
if not player then return end
|
||||
|
||||
local vehicle = NDCore.getVehicleById(vehicleId)
|
||||
if not vehicle or not vehicle.available or vehicle.owner ~= player.id then return end
|
||||
if not vehicle or vehicle.owner ~= player.id then return end
|
||||
if not vehicle.available and not vehicle.impounded then return end
|
||||
|
||||
MySQL.query.await("UPDATE nd_vehicles SET stored = ? WHERE id = ?", {0, vehicleId})
|
||||
|
||||
local properties = vehicle.properties
|
||||
if properties.callsign then
|
||||
local callsign = player.getMetadata("callsign")
|
||||
if not callsign or callsign == "" then goto skip end
|
||||
|
||||
callsign = tostring(callsign)
|
||||
if not callsign or callsign:len() ~= 3 then goto skip end
|
||||
|
||||
properties.modFender = tonumber(callsign:sub(1, 1))
|
||||
properties.modRightFender = tonumber(callsign:sub(2, 2))
|
||||
properties.modRoof = tonumber(callsign:sub(3, 3))
|
||||
end
|
||||
|
||||
::skip::
|
||||
|
||||
return NDCore.createVehicle({
|
||||
owner = player.id,
|
||||
model = vehicle.properties.model,
|
||||
model = properties.model,
|
||||
coords = vec4(coords.x, coords.y, coords.z, coords.w or coords.heading or heading),
|
||||
properties = vehicle.properties,
|
||||
properties = properties,
|
||||
vehicleId = vehicleId,
|
||||
source = source
|
||||
})
|
||||
@@ -421,16 +504,16 @@ local function toggleVehicleLock(source, entity, nearby, metadata)
|
||||
|
||||
if metadata and not metadata.keyEnabled then
|
||||
return player.notify({
|
||||
title = "No signal",
|
||||
description = "Vehicle key disabled.",
|
||||
title = locale("no_signal"),
|
||||
description = locale("veh_key_disabled"),
|
||||
type = "error",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
})
|
||||
elseif not nearby then
|
||||
return player.notify({
|
||||
title = "No signal",
|
||||
description = "Vehicle to far away.",
|
||||
title = locale("no_signal"),
|
||||
description = locale("veh_far_away"),
|
||||
type = "error",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
@@ -444,16 +527,16 @@ local function toggleVehicleLock(source, entity, nearby, metadata)
|
||||
player.triggerEvent("ND_Vehicles:keyFob", vehicle.netId)
|
||||
if locked then
|
||||
return player.notify({
|
||||
title = "LOCKED",
|
||||
description = "Your vehicle has now been locked.",
|
||||
title = locale("veh_locked"),
|
||||
description = locale("veh_locked2"),
|
||||
type = "success",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
})
|
||||
end
|
||||
player.notify({
|
||||
title = "UNLOCKED",
|
||||
description = "Your vehicle has now been unlocked.",
|
||||
title = locale("veh_unlocked"),
|
||||
description = locale("veh_unlocked2"),
|
||||
type = "inform",
|
||||
position = "bottom-right",
|
||||
duration = 3000
|
||||
@@ -567,12 +650,24 @@ RegisterNetEvent("ND_Vehicles:toggleVehicleLock", function(netId)
|
||||
end)
|
||||
|
||||
-- locking of npc vehicles, if the players spawns inside a vehicle it won't be locked.
|
||||
RegisterNetEvent("entityCreated", function(entity)
|
||||
AddEventHandler("entityCreated", function(entity)
|
||||
local time = os.time()
|
||||
while not DoesEntityExist(entity) and os.time()-time < 5 do Wait(50) end
|
||||
|
||||
if not DoesEntityExist(entity) or GetEntityType(entity) ~= 2 then return end
|
||||
|
||||
local state = Entity(entity).state
|
||||
if state.owner or state.locked ~= nil then return end
|
||||
|
||||
time = os.time()
|
||||
local driver = GetPedInVehicleSeat(entity, -1)
|
||||
while DoesEntityExist(entity) and driver == 0 and os.time()-time < 2 do
|
||||
driver = GetPedInVehicleSeat(entity, -1)
|
||||
Wait(100)
|
||||
end
|
||||
|
||||
if not DoesEntityExist(entity) then return end
|
||||
|
||||
if DoesEntityExist(driver) and IsPedAPlayer(driver) then
|
||||
state.locked = false
|
||||
state.hotwired = true
|
||||
@@ -630,16 +725,16 @@ RegisterNetEvent("ND_Vehicles:storeVehicle", function(netId)
|
||||
local player = NDCore.getPlayer(src)
|
||||
if not vehicle.setStatus("stored", true) or not player or player.id ~= vehicle.owner then
|
||||
return player.notify({
|
||||
title = "Garage",
|
||||
description = "No owned vehicle found nearby.",
|
||||
title = locale("garage"),
|
||||
description = locale("no_owned_veh_nearby"),
|
||||
type = "error",
|
||||
position = "bottom",
|
||||
duration = 3000
|
||||
})
|
||||
end
|
||||
player.notify({
|
||||
title = "Garage",
|
||||
description = "Vehicle stored in garage.",
|
||||
title = locale("garage"),
|
||||
description = locale("veh_stored_in_garage"),
|
||||
type = "success",
|
||||
position = "bottom",
|
||||
duration = 3000
|
||||
@@ -665,28 +760,29 @@ RegisterNetEvent("ND_Vehicles:takeVehicle", function(vehId, locations)
|
||||
local vehicle = NDCore.getVehicleById(vehId)
|
||||
local player = NDCore.getPlayer(src)
|
||||
if not player or not vehicle or vehicle.owner ~= player.id then return end
|
||||
|
||||
local info = NDCore.spawnOwnedVehicle(src, vehicle.id, isParkingAvailable(locations))
|
||||
if not info then return end
|
||||
TriggerClientEvent("ND_Vehicles:blip", src, info.netId, true)
|
||||
|
||||
if vehicle.impounded then
|
||||
local reclaimPrice = vehicle.metadata.impoundReclaimPrice or 200
|
||||
if not player.deductMoney("bank", reclaimPrice, "Vehicle impound reclaim") then
|
||||
if not player.deductMoney("bank", reclaimPrice, locale("impound_reclaim")) then
|
||||
return player.notify({
|
||||
title = "Impound",
|
||||
description = ("Price to reclaim is $%d, you don't have enough!"):format(reclaimPrice),
|
||||
title = locale("impound"),
|
||||
description = locale("impound_not_enough", reclaimPrice),
|
||||
type = "error",
|
||||
position = "bottom"
|
||||
})
|
||||
end
|
||||
player.notify({
|
||||
title = "Impound",
|
||||
description = ("Paid $%d to reclaim vehicle!"):format(reclaimPrice),
|
||||
title = locale("impound"),
|
||||
description = locale("impound_paid", reclaimPrice),
|
||||
type = "success",
|
||||
position = "bottom"
|
||||
})
|
||||
MySQL.query.await("UPDATE nd_vehicles SET impounded = ? WHERE id = ?", {0, vehicle.id})
|
||||
end
|
||||
|
||||
local info = NDCore.spawnOwnedVehicle(src, vehicle.id, isParkingAvailable(locations))
|
||||
if not info then return end
|
||||
TriggerClientEvent("ND_Vehicles:blip", src, info.netId, true)
|
||||
end)
|
||||
|
||||
lib.callback.register("ND_Vehicles:getOwnedVehicles", function(src)
|
||||
@@ -694,3 +790,30 @@ lib.callback.register("ND_Vehicles:getOwnedVehicles", function(src)
|
||||
if not player then return end
|
||||
return NDCore.getVehicles(player.id)
|
||||
end)
|
||||
|
||||
AddEventHandler("ND:characterLoaded", function(player)
|
||||
local ownedExistingVehicles = {}
|
||||
local ownedVehicles = NDCore.getVehicles(player.id)
|
||||
local vehicles = GetAllVehicles()
|
||||
local vehiclesToImpound = {}
|
||||
|
||||
for i=1, #vehicles do
|
||||
local veh = vehicles[i]
|
||||
local state = Entity(veh).state
|
||||
if state.owner == player.id then
|
||||
ownedExistingVehicles[#ownedExistingVehicles+1] = state.id
|
||||
end
|
||||
end
|
||||
|
||||
for i=1, #ownedVehicles do
|
||||
local veh = ownedVehicles[i]
|
||||
if veh and not veh.stored and not veh.impounded and not lib.table.contains(ownedExistingVehicles, veh.id) then
|
||||
vehiclesToImpound[#vehiclesToImpound+1] = veh.id
|
||||
end
|
||||
end
|
||||
|
||||
if #vehiclesToImpound == 0 then return end
|
||||
|
||||
local query = ("UPDATE nd_vehicles SET impounded = ? WHERE owner = ? AND id IN (%s)"):format(table.concat(vehiclesToImpound, ", "))
|
||||
MySQL.rawExecute(query, {1, player.id})
|
||||
end)
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
NDCore = exports["ND_Core"]:GetCoreObject()
|
||||
@@ -1,30 +0,0 @@
|
||||
local startedResources = {}
|
||||
local callbacks = {}
|
||||
|
||||
AddEventHandler("onResourceStart", function(resourceName)
|
||||
startedResources[resourceName] = true
|
||||
local callback = callbacks[resourceName]
|
||||
if not callback then return end
|
||||
callback(true)
|
||||
end)
|
||||
|
||||
AddEventHandler("onResourceStop", function(resourceName)
|
||||
startedResources[resourceName] = nil
|
||||
local callback = callbacks[resourceName]
|
||||
if not callback then return end
|
||||
callback(false)
|
||||
end)
|
||||
|
||||
function isResourceStarted(resourceName, cb)
|
||||
local started = GetResourceState(resourceName) == "started"
|
||||
startedResources[resourceName] = started
|
||||
|
||||
if cb then
|
||||
callbacks[resourceName] = cb
|
||||
cb(started)
|
||||
end
|
||||
|
||||
return started
|
||||
end
|
||||
|
||||
exports("isResourceStarted", isResourceStarted)
|
||||
Reference in New Issue
Block a user