Advertisement
AbhiModszYT

WarRobots

Jul 9th, 2025
218
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 5.23 KB | Science | 0 0
  1. local targetPackage = "com.pixonic.wwr"
  2. local scriptVersion = "11.2.0"
  3. local Update = "2025/07/10"
  4.  
  5. function showApkInfo()
  6.     local info = gg.getTargetInfo()
  7.     local is64 = info.x64 and "64-bit" or "32-bit"
  8.     local packageName = gg.getTargetPackage()
  9.     local version = info.versionName or "Unknown"
  10.     if version ~= scriptVersion then
  11.         gg.alert("Please update scripts!\nScript version: " .. scriptVersion .. "\nAPK version: " .. version)
  12.         os.exit()
  13.     end
  14.     local message = string.format(
  15.         "APK Info :\n\nApk Name : War Robots\nPackage : %s\nGame Version : %s\nScript Version :%s\nArchitecture : %s\n Update : %s\nScript By : AbhiModszYT",
  16.         packageName, version, scriptVersion, is64, Update
  17.     )
  18.     gg.alert(message)
  19. end
  20.  
  21. function checkArch()
  22.     local info = gg.getTargetInfo()
  23.     if info.x64 then
  24.         gg.toast("Please Install 32-bit APK")
  25.         os.exit()
  26.     else
  27.         gg.toast("32-bit Architecture Detected")
  28.         gg.sleep(5000)
  29.     end
  30. end
  31. showApkInfo()
  32. checkArch()
  33.  
  34.  
  35. local n, startAddress, endAddress = nil, 0, 0
  36. local originalValues = {}
  37.  
  38. local function name(lib)
  39.     if n == lib then
  40.         return startAddress, endAddress
  41.     end
  42.     local ranges = gg.getRangesList(lib or 'libil2cpp.so')
  43.     for i, v in ipairs(ranges) do
  44.         if v.state == "Xa" then
  45.             startAddress = v.start
  46.             endAddress = ranges[#ranges]['end']
  47.             break
  48.         end
  49.     end
  50.     return startAddress, endAddress
  51. end
  52.  
  53. local function hexToBytes(hex)
  54.     local t = {}
  55.     for h in string.gmatch(hex, "%S%S") do
  56.         table.insert(t, tonumber(h, 16))
  57.     end
  58.     return t
  59. end
  60.  
  61. local function togglePatch(libname, offset, hex, label)
  62.     name(libname)
  63.     local address = startAddress + offset
  64.     local newBytes = hexToBytes(hex)
  65.     local byteCount = #newBytes
  66.     local readTable = {}
  67.     for i = 0, byteCount - 1 do
  68.         table.insert(readTable, {address = address + i, flags = gg.TYPE_BYTE})
  69.     end
  70.     local currentValues = gg.getValues(readTable)
  71.     local key = string.format("%s_%X", libname, offset)
  72.  
  73.     if originalValues[key] == nil then
  74.         originalValues[key] = {}
  75.         for i, v in ipairs(currentValues) do
  76.             table.insert(originalValues[key], v.value)
  77.         end
  78.  
  79.         local patchTable = {}
  80.         for i, b in ipairs(newBytes) do
  81.             table.insert(patchTable, {
  82.                 address = address + i - 1,
  83.                 flags = gg.TYPE_BYTE,
  84.                 value = b
  85.             })
  86.         end
  87.         gg.setValues(patchTable)
  88.         gg.toast(label .. " Enabled")
  89.     else
  90.         local restoreTable = {}
  91.         for i, val in ipairs(originalValues[key]) do
  92.             table.insert(restoreTable, {
  93.                 address = address + i - 1,
  94.                 flags = gg.TYPE_BYTE,
  95.                 value = val
  96.             })
  97.         end
  98.         gg.setValues(restoreTable)
  99.         originalValues[key] = nil
  100.         gg.toast(label .. " Disabled")
  101.     end
  102. end
  103. local patches = {
  104.     {name = "Speed Hack", offset = 0x3274468, hex = "A0 00 45 E3 1E FF 2F E1"},
  105.     {name = "No Gravity", offset = 0x858B214, hex = "7F 0F 4F E3 1E FF 2F E1"},
  106.     {name = "20m distance", offset = 0x259A390, hex = "A0 01 44 E3 1E FF 2F E1"},
  107.     {name = "No Cd Module", offset = 0x32714F4, hex = "00 00 A0 E3 1E FF 2F E1"},
  108.     {name = "No Cooldown Skills 1", offset = 0x3274498, hex = "00 00 A0 E3 1E FF 2F E1"},
  109.     {name = "No Duration Skills 1", offset = 0x32744F8, hex = "00 00 A0 E3 1E FF 2F E1"},
  110.     {name = "No Cooldown Skills 2", offset = 0x32744B8, hex = "00 00 A0 E3 1E FF 2F E1"},
  111.     {name = "No Duration Skills 2", offset = 0x3274518, hex = "00 00 A0 E3 1E FF 2F E1"},
  112.     {name = "Don't Lock Module By StatusEffect", offset = 0x3274618, hex = "00 00 A0 E3 1E FF 2F E1"},
  113.     {name = "Don't Lock Ability By StatusEffect", offset = 0x3274604, hex = "00 00 A0 E3 1E FF 2F E1"},
  114.     {name = "Don't Lock Ability1 ByPilot", offset = 0x32745D0, hex = "00 00 A0 E3 1E FF 2F E1"},
  115.     {name = "Don't Lock Ability2 ByPilot", offset = 0x32745F0, hex = "00 00 A0 E3 1E FF 2F E1"},
  116.     {name = "Spider Game Weapon Range", offset = 0x3271434, hex = "00 00 04 E3 1C 06 44 E3 1E FF 2F E1"},
  117.     {name = "Auto Abilitie v2", offset = 0x33345DC, hex = "00 F0 20 E3 1E FF 2F E1"},
  118.     {name = "Auto Abilitie v3", offset = 0x33345F4, hex = "00 F0 20 E3 1E FF 2F E1"}
  119. }
  120.  
  121. local function isPatchEnabled(libname, offset)
  122.     local key = string.format("%s_%X", libname, offset)
  123.     return originalValues[key] ~= nil
  124. end
  125.  
  126. local function main()
  127.     local menuItems = {}
  128.  
  129.     for i, patch in ipairs(patches) do
  130.         local status = isPatchEnabled("libil2cpp.so", patch.offset) and "✅" or "❌"
  131.         table.insert(menuItems, string.format("%s %s", patch.name, status))
  132.     end
  133.     table.insert(menuItems, "Exit Script")
  134.  
  135.     local menu = gg.choice(menuItems, nil, "Hacks : Enabled ✅ / Disabled ❌")
  136.  
  137.     if not menu then return end
  138.  
  139.     if menu == #menuItems then
  140.         os.exit()
  141.     else
  142.         local patch = patches[menu]
  143.         togglePatch("libil2cpp.so", patch.offset, patch.hex, patch.name)
  144.     end
  145. end
  146.  
  147. while true do
  148.     if gg.isVisible() then
  149.         gg.setVisible(false)
  150.         main()
  151.     end
  152.     gg.sleep(10)
  153. end
  154.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement