mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-08-29 01:01:22 +00:00
Merge pull request #1673 from Mr-Snaeky/Mr-Snaeky-patch-1
Create ar.lua
This commit is contained in:
@@ -586,6 +586,11 @@ ESX.SecureNetEvent('esx:updatePlayerData', function(key, val)
|
||||
ESX.SetPlayerData(key, val)
|
||||
end)
|
||||
|
||||
---@param command string
|
||||
ESX.SecureNetEvent("esx:executeCommand", function(command)
|
||||
ExecuteCommand(command)
|
||||
end)
|
||||
|
||||
AddEventHandler("onResourceStop", function(resource)
|
||||
if Core.Events[resource] then
|
||||
for i = 1, #Core.Events[resource] do
|
||||
|
||||
@@ -949,6 +949,17 @@ function CreateExtendedPlayer(playerId, identifier, group, accounts, inventory,
|
||||
self.triggerEvent('esx:updatePlayerData', 'metadata', self.metadata)
|
||||
end
|
||||
|
||||
---@param command string
|
||||
---@return nil
|
||||
function self.executeCommand(command)
|
||||
if type(command) ~= "string" then
|
||||
error("xPlayer.executeCommand must be of type string!")
|
||||
return
|
||||
end
|
||||
|
||||
self.triggerEvent("esx:executeCommand", command)
|
||||
end
|
||||
|
||||
for _, funcs in pairs(Core.PlayerFunctionOverrides) do
|
||||
for fnName, fn in pairs(funcs) do
|
||||
self[fnName] = fn(self)
|
||||
|
||||
@@ -26,9 +26,11 @@ function Callbacks:Execute(cb, ...)
|
||||
|
||||
if not success then
|
||||
print(("[^1ERROR^7] Failed to execute Callback with RequestId: ^5%s^7"):format(self.currentId))
|
||||
error(errorString)
|
||||
print("^3Callback Error:^7 " .. tostring(errorString)) -- just log, don't throw
|
||||
self.currentId = nil
|
||||
return
|
||||
end
|
||||
|
||||
self.currentId = nil
|
||||
end
|
||||
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
Locales["ar"] = {
|
||||
["male"] = "ذكر",
|
||||
["female"] = "أنثى",
|
||||
["select_char"] = "اختيار شخصية",
|
||||
["select_char_description"] = "اختر شخصية للعب بها.",
|
||||
["create_char"] = "شخصية جديدة",
|
||||
["char_play"] = "العب",
|
||||
["char_play_description"] = "الدخول إلى المدينة.",
|
||||
["char_disabled"] = "معطلة",
|
||||
["char_disabled_description"] = "لا يمكن استخدام هذه الشخصية.",
|
||||
["char_delete"] = "حذف",
|
||||
["char_delete_description"] = "حذف هذه الشخصية نهائيًا.",
|
||||
["char_delete_confirmation"] = "تأكيد الحذف",
|
||||
["char_delete_confirmation_description"] = "هل أنت متأكد من حذف الشخصية المحددة؟",
|
||||
["char_delete_yes_description"] = "نعم، أنا متأكد من حذف الشخصية المحددة",
|
||||
["char_delete_no_description"] = "لا، العودة إلى خيارات الشخصية",
|
||||
["character"] = "الشخصية: %s",
|
||||
["return"] = "رجوع",
|
||||
["return_description"] = "العودة لاختيار الشخصية.",
|
||||
["command_setslots"] = "تحديد عدد خانات الشخصيات للاعب",
|
||||
["command_remslots"] = "إزالة عدد خانات الشخصيات للاعب",
|
||||
["command_enablechar"] = "تفعيل شخصية معينة للاعب",
|
||||
["command_disablechar"] = "تعطيل شخصية معينة للاعب",
|
||||
["command_charslot"] = "رقم خانة الشخصية",
|
||||
["command_identifier"] = "معرّف اللاعب",
|
||||
["command_slots"] = "عدد الخانات",
|
||||
["slotsadd"] = "تم تعيين %s خانات إلى %s",
|
||||
["slotsrem"] = "تمت إزالة الخانات من %s",
|
||||
["charenabled"] = "تم تفعيل الشخصية #%s لـ %s",
|
||||
["chardisabled"] = "تم تعطيل الشخصية #%s لـ %s",
|
||||
["charnotfound"] = "الشخصية #%s لـ %s غير موجودة",
|
||||
}
|
||||
Reference in New Issue
Block a user