Advertisement
davedumas0

Untitled

Sep 19th, 2017
250
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 2.34 KB | None | 0 0
  1.     local disable = true
  2. Citizen.CreateThread(function()
  3.     while true do
  4.         Citizen.Wait(0)
  5.         if disable == true then
  6.         scaleform = RequestScaleformMovie("DISRUPTION_LOGISTICS")
  7.          if HasScaleformMovieLoaded(scaleform) then
  8.           if IsInputJustDisabled(2) then
  9.             PushScaleformMovieFunction(scaleform, "SET_MOUSE_INPUT")
  10.             PushScaleformMovieFunctionParameterFloat(GetDisabledControlNormal(2, 239))
  11.             PushScaleformMovieFunctionParameterFloat(GetDisabledControlNormal(2, 240))
  12.             PopScaleformMovieFunctionVoid()
  13.             SetInputExclusive(2, 237)
  14.             EnableControlAction(2, 237, 1)
  15.             Set_2dLayer(4)
  16.             PushScaleformMovieFunction(scaleform, "SET_BUTTON_STATES")
  17.             SetInputExclusive(2, 205)
  18.             EnableControlAction(2, 205, 1)
  19.             SetInputExclusive(2, 206)
  20.             EnableControlAction(2, 206, 1)
  21.              if IsControlJustPressed(2, 205) then
  22.               CallScaleformMovieFunctionFloatParams(scaleform, "SET_INPUT_EVENT", 205.0, -1082130432, -1082130432, -1082130432, -1082130432)
  23.              end
  24.               if IsControlJustPressed(2, 206) then
  25.                CallScaleformMovieFunctionFloatParams(scaleform, "SET_INPUT_EVENT", 206.0, -1082130432, -1082130432, -1082130432, -1082130432)
  26.               end
  27.           end
  28.             PopScaleformMovieFunctionVoid()
  29.             DrawScaleformMovieFullscreen(scaleform, 255, 255, 255, 255, 0)
  30.             if IsControlJustPressed(2, 237) then
  31.              CallScaleformMovieFunctionFloatParams(scaleform, "SET_INPUT_EVENT", 237.0, -1082130432, -1082130432, -1082130432, -1082130432)
  32.             end
  33.          end
  34.           SetInputExclusive(2, 199)
  35.           EnableControlAction(2, 199, 1)
  36.           HideHelpTextThisFrame()
  37.           HideHudAndRadarThisFrame()
  38.           HideScriptedHudComponentThisFrame(19)
  39.           HideHudComponentThisFrame(4)
  40.           HideHudComponentThisFrame(5)
  41.           HideHudComponentThisFrame(13)
  42.           HideHudComponentThisFrame(3)
  43.        else
  44.          SetScaleformMovieAsNoLongerNeeded(scaleform)
  45.         end
  46.     end
  47. end)
  48.  
  49. Citizen.CreateThread(function()
  50.     while true do
  51.       EnableControlAction(1, 44, 1)
  52.       if IsControlJustPressed(1, 44) then
  53.       Citizen.Trace("is true "..tostring(disable))
  54.        disable = not disable
  55.       Citizen.Trace("is true "..tostring(disable))
  56.       end
  57.         Citizen.Wait(0)
  58.         if disable then
  59.             SetScaleformMovieAsNoLongerNeeded(scaleform)
  60.         end
  61.     end
  62. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement