Merge branch 'main' into patch-4

This commit is contained in:
Kakarot
2022-06-15 17:29:18 -07:00
committed by GitHub
3 changed files with 34 additions and 3 deletions
+1
View File
@@ -134,6 +134,7 @@ RegisterNetEvent('QBCore:Command:SpawnVehicle', function(vehName)
local vehicle = CreateVehicle(hash, GetEntityCoords(ped), GetEntityHeading(ped), true, false)
TaskWarpPedIntoVehicle(ped, vehicle, -1)
SetVehicleFuelLevel(vehicle, 100.0)
SetVehicleDirtLevel(vehicle, 0.0)
SetModelAsNoLongerNeeded(hash)
TriggerEvent("vehiclekeys:client:SetOwner", QBCore.Functions.GetPlate(vehicle))
end)
+31
View File
@@ -0,0 +1,31 @@
local Translations = {
error = {
not_online = 'O jogador não está online',
wrong_format = 'Formato inválido',
missing_args = 'Nem todos os argumentos foram inseridos (x, y, z)',
missing_args2 = 'Todos os argumentos devem ser preenchidos!',
no_access = 'Sem acesso a este comando',
company_too_poor = 'Sua compania está quebrada',
item_not_exist = 'O item não existe',
too_heavy = 'Inventário cheio',
duplicate_license = 'Licença duplicada da Rockstar encontrada',
no_valid_license = 'Nenhuma licença válida da Rockstar encontrada',
not_whitelisted = 'Você não tem whitelist neste servidor'
},
success = {},
info = {
received_paycheck = 'Você recebeu seu salário de %{value}€',
job_info = 'Emprego: %{value} | Grau: %{value2} | Serviço: %{value3}',
gang_info = 'Gang: %{value} | Grau: %{value2}',
on_duty = 'Você agora está de plantão!',
off_duty = 'Você agora está de folga!',
checking_ban = 'Olá %s. Estamos verificando se você foi banido.',
join_server = 'Bem-vindo %s a {Server Name}.',
checking_whitelisted = 'Olá %s. Estamos verificando sua whitelist.'
}
}
Lang = Locale:new({
phrases = Translations,
warnOnMissing = true
})
+2 -3
View File
@@ -135,14 +135,13 @@ end)
RegisterNetEvent('QBCore:Server:SetMetaData', function(meta, data)
local src = source
local Player = QBCore.Functions.GetPlayer(src)
if not Player then return end
if meta == 'hunger' or meta == 'thirst' then
if data > 100 then
data = 100
end
end
if Player then
Player.Functions.SetMetaData(meta, data)
end
Player.Functions.SetMetaData(meta, data)
TriggerClientEvent('hud:client:UpdateNeeds', src, Player.PlayerData.metadata['hunger'], Player.PlayerData.metadata['thirst'])
end)