Run menu check and anti-wanted every frame

This commit is contained in:
ElPumpo
2018-12-30 20:57:42 +01:00
parent 6c32c9ede0
commit c95ac3b87f
5 changed files with 31 additions and 6 deletions
+2 -2
View File
@@ -480,7 +480,7 @@ end)
Citizen.CreateThread(function()
while true do
Citizen.Wait(10)
Citizen.Wait(0)
if IsControlJustReleased(0, Keys['F2']) and GetLastInputMethod(2) and not isDead and not ESX.UI.Menu.IsOpen('default', 'es_extended', 'inventory') then
ESX.ShowInventory()
@@ -515,7 +515,7 @@ if Config.DisableWantedLevel then
Citizen.CreateThread(function()
while true do
Citizen.Wait(10)
Citizen.Wait(0)
local playerId = PlayerId()
if GetPlayerWantedLevel(playerId) ~= 0 then