47 lines
1.2 KiB
Lua
47 lines
1.2 KiB
Lua
Core = {}
|
|
Core.Input = {}
|
|
Core.Events = {}
|
|
|
|
ESX.PlayerData = {}
|
|
ESX.PlayerLoaded = false
|
|
ESX.playerId = PlayerId()
|
|
ESX.serverId = GetPlayerServerId(ESX.playerId)
|
|
|
|
ESX.UI = {}
|
|
ESX.UI.Menu = {}
|
|
ESX.UI.Menu.RegisteredTypes = {}
|
|
ESX.UI.Menu.Opened = {}
|
|
|
|
ESX.Game = {}
|
|
ESX.Game.Utils = {}
|
|
|
|
CreateThread(function()
|
|
while not Config.Multichar do
|
|
Wait(100)
|
|
|
|
if NetworkIsPlayerActive(ESX.playerId) then
|
|
ESX.DisableSpawnManager()
|
|
DoScreenFadeOut(0)
|
|
Wait(500)
|
|
TriggerServerEvent("esx:onPlayerJoined")
|
|
break
|
|
end
|
|
end
|
|
end)
|
|
|
|
-- Blockiert das Waffenrad und das Durchscrollen von Waffen
|
|
CreateThread(function()
|
|
while true do
|
|
Wait(0) -- Muss jeden Frame ausgeführt werden
|
|
|
|
-- 37 ist die Control ID für das Waffenrad (TAB / L1)
|
|
DisableControlAction(0, 37, true)
|
|
|
|
-- Verhindert das Wechseln der Waffen mit dem Mausrad (optional, aber empfohlen)
|
|
DisableControlAction(0, 15, true) -- Mausrad hoch (NEXT_WEAPON)
|
|
DisableControlAction(0, 16, true) -- Mausrad runter (PREV_WEAPON)
|
|
|
|
-- Verhindert Nahkampfangriffe mit der Waffe (Q / Kreis), falls gewünscht
|
|
-- DisableControlAction(0, 140, true)
|
|
end
|
|
end) |