Esx_bennys help for only mecano job grade boss

hello i try put only for mecano job grade boss, any help?

Code:

Citizen.CreateThread(function()
	while true do
		Wait(0)
		local playerPed = GetPlayerPed(-1)
		if IsPedInAnyVehicle(playerPed, false) then
			local coords      = GetEntityCoords(GetPlayerPed(-1))
			local currentZone = nil
			local zone 		  = nil
			local lastZone    = nil
			if (PlayerData.job ~= nil and PlayerData.job.name == 'mecano') or Config.IsMecanoJobOnly == false then
				for k,v in pairs(Config.Zones) do
					if(GetDistanceBetweenCoords(coords, v.Pos.x, v.Pos.y, v.Pos.z, true) < v.Size.x) then
						isInLSMarker  = true

						SetTextComponentFormat("STRING")
						AddTextComponentString(v.Hint)
						DisplayHelpTextFromStringLabel(0, 0, 1, -1)

						break
					else
						isInLSMarker  = false
					end
				end
			end

			if IsControlJustReleased(0, 38) and not lsMenuIsShowed and isInLSMarker then				
				lsMenuIsShowed = true

				local vehicle = GetVehiclePedIsIn(playerPed, false)
				FreezeEntityPosition(vehicle, true)

				myCar = ESX.Game.GetVehicleProperties(vehicle)

				ESX.UI.Menu.CloseAll()
				GetAction({value = 'main'})
			end

			if isInLSMarker and not hasAlreadyEnteredMarker then
				hasAlreadyEnteredMarker = true
			end

			if not isInLSMarker and hasAlreadyEnteredMarker then
				hasAlreadyEnteredMarker = false
			end

		end
	end
end)

Please do not create new topics for support/questions related to existing resources/menus/mods.

Only ask questions or request support in the original resource topic, or on whatever site/page you got the resource from (for example: create an issue on the GitHub page of the resource that you downloaded).

That way the original resource creator will get a notification and be able to help properly. This also helps to reduce duplicate topics of the same issue, because everything will be inside the original topic, allowing everyone to see all issues and solutions in one place.

Thanks for keeping the forums tidy. :mascot:

1 Like