Citizen.CreateThread(function()
while true do
Citizen.Wait(0)
local player = GetPlayerPed(-1)
if(IsPedInAnyVehicle(player, false)) then
local speed = GetEntitySpeed(player);
local kmh = speed * 3.6;
if kmh > 100 then
if bigmap == true then
SetRadarZoomLevelThisFrame(600 + kmh)
else
SetRadarZoomLevelThisFrame(50 + kmh)
end
end
end
if bigmap then
SetBigmapActive(true,false)
else
SetBigmapActive(false,false)
end
if IsControlJustReleased(1,20) then
if bigmap then
bigmap = false
TriggerEvent("pNotify:SendNotification", {text = "Large Map Deactivate ", type = "success", timeout = 1400, layout = "centerLeft"})
else
bigmap = true
TriggerEvent("pNotify:SendNotification", {text = "Large Map Activate", type = "success", timeout = 1400, layout = "centerLeft"})
end
end
end
end)