Cách thêm code alert check free fire open or off for LUA script
3 minute read
Theo yêu cầu của nhiều ae bảo mình share code check ff on hay off thì hôm nay mình sẽ share nha!
Dán code sau vào đầu script lua của bạn
LUA
------code tính time // code by Nguyen xuan dung☭
Time = os.clock()
------ code check xem có mở ff ko?
b = [[
20245
Trung #95149204|95149204|10|42200000|0|0|0|0|rwxp|/data/app/com.dts.freefireth-1/lib/arm/libil2cpp.so|686204
]]
fileData = gg.EXT_STORAGE .. "/[###].dat"
io.output(fileData):write(b):close()
gg.loadList(fileData, gg.LOAD_APPEND)
r = gg.getListItems()
getReset = gg.getValues(r)
gg.clearList()
os.remove(fileData)
memFrom, memTo, lib, num, lim, results, src, ok = 0, -1, nil, 0, 32, {}, nil, false function name(n) local srd = gg;if lib ~= n then lib = n ranges = srd.getRangesList(lib) if #ranges == 0 then gg.alert("🇻🇳lỗi vào Game Free Fire để chạy script🇻🇳\n🇻🇳Vui Lòng Mở Free Fire Và Chọn Giá Trị Cao Nhất Để Khởi Động🇻🇳") gg.setVisible(true) os.remove(gg.EXT_STORAGE .. "/Android/data/com.dts.freefireth/files/reportnew.db", gg.LOAD_APPEND) os.remove(gg.EXT_STORAGE .. "/Android/data/com.dts.freefireth/files/ymrtc_log.txt", gg.LOAD_APPEND) print([[ ]].. string.format("ᴛʜờɪ ɢɪᴀɴ ᴄʜạʏ sᴄʀɪᴘᴛ : %.2f ɢɪᴀ̂ʏ🇻🇳", os.clock() - Time) ..[[ ]]) print("🇻🇳lỗi vào Game Free Fire để chạy script🇻🇳\n🇻🇳Vui Lòng Mở Free Fire Và Chọn Giá Trị Cao Nhất Để Khởi Động🇻🇳") os.exit() else memFrom = ranges[1].start memTo = ranges[#ranges]['end'] end end end function hex2tbl(hex) ret = {} hex:gsub('%S%S', function (ch) ret[#ret + 1] = ch return '' end) return ret end function original(orig) tbl = hex2tbl(orig) len = #tbl if len == 0 then return end used = len if len > lim then used = lim end s = '' for i = 1, used do if i ~= 1 then s = s..';' end v = tbl[i] if v == '??' or v == '**' then v = '0~~0' end s = s..v..'r' end s = s..'::'..used gg.searchNumber(s, 1, false, gg.SIGN_EQUAL, memFrom, memTo) if len > used then for i = used + 1, len do v = tbl[i] if v == '??' or v == '**' then v = 256 else v = ('0x'..v) + 0 if v > 127 then v = v - 256 end end tbl[i] = v end end found = gg.getResultCount(); results = {} count = 0 checked = 0 while true do if checked >= found then break end all = gg.getResults(8) total = #all start = checked if checked + used > total then break end for i, v in ipairs(all) do v.address = v.address + myoffset end gg.loadResults(all) while start < total do good = true offset = all[1 + start].address - 1 if used < len then get = {} for i = lim + 1, len do get[i - lim] = {address = offset + i, flags = 1, value = 0} end get = gg.getValues(get) for i = lim + 1, len do ch = tbl[i] if ch ~= 256 and get[i - lim].value ~= ch then good = false break end end end if good then count = count + 1 results[count] = offset checked = checked + used else del = {} for i = 1, used do del[i] = all[i + start] end gg.removeResults(del) end start = start + used end end end function replaced(repl) num = num + 1 tbl = hex2tbl(repl) if src ~= nil then source = hex2tbl(src) for i, v in ipairs(tbl) do if v ~= '??' and v ~= '**' and v == source[i] then tbl[i] = '**' end end src = nil end cnt = #tbl set = {} s = 0 for _, addr in ipairs(results) do for i, v in ipairs(tbl) do if v ~= '??' and v ~= '**' then s = s + 1 set[s] = { ['address'] = addr + i,['value'] = v..'r', ['flags'] = 1,} end end end if s ~= 0 then gg.setValues(set) end ok = true end
Tiếp theo dán code bên dưới vào đằng sau fuction xxxx() hoặc then bất kì nới muốn hiển thị thông báo trong script lua cảu bạn là xong!
LUA
gg.setRanges(gg.REGION_CODE_APP | gg.REGION_CODE_SYS)
name("libil2cpp.so")
Đăng nhận xét