keblade07

Untitled

May 29th, 2018
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.45 KB | None | 0 0
  1.  
  2. Attached = false
  3. Timer = createTimer(nil)
  4. MemScanCount = 0
  5. MemScanCountMax = 10
  6.  
  7. ProcessFound = function()
  8.         local scan = createMemScan(true)
  9.         memscan_returnOnlyOneResult(scan, true)
  10.         memscan_firstScan(scan, soExactValue, vtByteArray, rtTruncated, "D9 00 8B 46 20 8B 8A 2C 01 00 00 D9 1C 24 8B", nil, 0x00000000, 0xFFFFFFFF, "*W", fsmNotAligned, nil, true, false, false, false)
  11.         memscan_waitTillDone(scan)
  12.  
  13.         local result = memscan_getOnlyResult(scan)
  14.  
  15.         if result == nil then
  16.                 MemScanCount = MemScanCount + 1
  17.                 if not (MemScanCount > MemScanCountMax) then
  18.                         sleep(100)
  19.                         ProcessFound()
  20.                 else
  21.                         showMessage"Failed to hook to Roblox. Run the script before opening up Roblox."
  22.                 end
  23.         else
  24.                 result = string.format("%x", result)
  25.                 result = ("0"):rep(8-#result) .. result
  26.  
  27.                 writeBytes(result, 0x90, 0x90)
  28.         end
  29. end
  30.  
  31. timer_setInterval(Timer, 100)
  32. timer_onTimer(Timer, function()
  33.         if getProcessIDFromProcessName"RobloxPlayerBeta.exe" then
  34.                 if not Attached then
  35.                         Attached = true
  36.                         openProcess(getProcessIDFromProcessName"RobloxPlayerBeta.exe")
  37.                         ProcessFound()
  38.                 end
  39.         else
  40.                 Attached = false
  41.         end
  42. end)
Add Comment
Please, Sign In to add comment