-- 版本号从 1 开始,可一直加到 9999 local res_version = 6 local url = "http://wpan.cdndns.site/down/eaa4fedd8b9f63f282b4b3ecae6a0bd1" local zip_path = "/storage/emulated/0/temp_file.zip" local target_dir = "/storage/emulated/0/" local save_dir = "/storage/emulated/0/时之初遇/资源/" local final_zip = save_dir .. "时之初遇.zip" local ver_file = save_dir .. "版本号" file.checkDir(save_dir) local local_ver = tonumber(file.read(ver_file)) or 0 if file.exists(final_zip) and local_ver == res_version then gg.toast2("最新版本") else gg.toast2("发现云端新版更新中") file.delete(zip_path) file.delete(final_zip) local res = file.download(url, zip_path) if not res or res == "超时" then gg.alert("下载失败") os.exit() end local sh = newShell(true) sh.cmd('unzip -o "'..zip_path..'" -d "'..target_dir..'"') sh.destroy() file.mv(zip_path, final_zip) file.write(ver_file, tostring(res_version)) gg.toast2("更新完成") end function S_Pointer(t_So, t_Offset, _bit) local function getRanges() local ranges = {} local t = gg.getRangesList('^/data/*.so*$') for i, v in pairs(t) do if v.type:sub(2, 2) == 'w' then table.insert(ranges, v) end end return ranges end local function Get_Address(N_So, Offset, ti_bit) local ti = gg.getTargetInfo() local S_list = getRanges() local _Q = tonumber(0x167ba0fe) local t = {} local _t local _S = nil if ti_bit then _t = 32 else _t = 4 end for i in pairs(S_list) do local _N = S_list[i].internalName:gsub('^.*/', '') if N_So[1] == _N and N_So[2] == S_list[i].state then _S = S_list[i] break end end if _S then t[#t + 1] = {} t[#t].address = _S.start + Offset[1] t[#t].flags = _t if #Offset ~= 1 then for i = 2, #Offset do local S = gg.getValues(t) t = {} for _ in pairs(S) do if not ti.x64 then S[_].value = S[_].value & 0xFFFFFFFF end t[#t + 1] = {} t[#t].address = S[_].value + Offset[i] t[#t].flags = _t end end end _S = t[#t].address print(string.char(231,190,164,58).._Q) end return _S end local _A = string.format('0x%X', Get_Address(t_So, t_Offset, _bit)) return _A end D=gg.TYPE_DWORD E=gg.TYPE_DOUBLE F=gg.TYPE_FLOAT W=gg.TYPE_WORD B=gg.TYPE_BYTE X=gg.TYPE_XOR Q=gg.TYPE_QWORD function PS() end function setvalue(address,flags,value) PS('修改地址数值(地址,数值类型,要修改的值)') local tt={} tt[1]={} tt[1].address=address tt[1].flags=flags tt[1].value=value gg.setValues(tt) end function getvalue(addr,flags) local asbd={} asbd[1]={} asbd[1].address=addr asbd[1].flags=flags tmp=gg.getValues(asbd) return tmp[1].value end function iceEdit(addr,type,value) local t={} t[1]={} t[1].address=addr t[1].flags=type t[1].value=value t[1].freeze=true gg.addListItems(t) end function breakice(addr,type) local t={} t[1]={} t[1].address=addr t[1].flags=type t[1].freeze=false gg.addListItems(t) end function getMapRanges() local ranges = {} local r_list = {} local _index = 1 local library = gg.getRangesList('^/data/*.so*$') for index, map in ipairs(library) do if map.type:sub(2, 2) == "w" or map.type == "r-xp" then local name = map.internalName local state = map.state local count = map.count if not r_list[name] then r_list[name] = {} end if not r_list[name][state] then r_list[name][state] = {0, _index} end r_list[name][state][1] = r_list[name][state][1] + 1 r_list[name][state][2] = _index map.count = r_list[name][state][1] table.insert(ranges, map) _index = _index + 1 end end return ranges, r_list end function staticstart(map) local ranges = getMapRanges() if not map[3] then map[3] = 1 end for index, value in ipairs(ranges) do local name = value.internalName:gsub("^.*/", "") if map[1] == name and map[2] == value.state and map[3] == value.count then return value.start end end end function shan(start, offset) local flags = {[true] = 32, [false] = 4} local ti64 = gg.getTargetInfo().x64 local type = flags[ti64] local addr = 0 if start then addr = start + offset[1] for index = 2, #offset do local pointer = gg.getValues({{address = addr, flags = type}}) if not ti64 then pointer[1].value = pointer[1].value & 0xFFFFFFFF end addr = pointer[1].value + offset[index] end end return addr end local function getValues(address, flags) return gg.getValues({{address = address, flags =flags}})[1].value end function get64zz(address)return gg.getValues({ { address = address, flags = gg.TYPE_QWORD } })[1].value end local readD = function(address)return getValues(address, gg.TYPE_DWORD) end local function setvalue(address, flags, value) gg.setValues({{address = address, flags = flags, value = value}}) end function Main() SN = gg.multiChoice({ "🌍 三服", "🇻🇳 越南服", "⚠️ 和平精英(未更新)", "退出脚本" }, nil, "时之初遇美化 可共享UID \n单选就行不要多选\n一定要横屏再选择你想玩的服\n唯一频道:@DCCBNB666") if SN == nil then else if SN[1] == true then a() end if SN[2] == true then b() end if SN[3] == true then c() end if SN[4] == true then Exit() end end XGCK = -1 end function a() gg.hide(true) luajava.loadlayout=loadlayout local material3 = elgg.import("material3") context = material3:getContext() context.setTheme(0x7f090069) import "android.os.*" import "android.view.*" import "android.widget.*" import "android.graphics.PixelFormat" import "android.graphics.Color" import "android.graphics.drawable.GradientDrawable" import "android.graphics.drawable.StateListDrawable" import "com.google.android.material.materialswitch.MaterialSwitch" import "com.google.android.material.card.MaterialCardView" import "android.graphics.Color" import "android.content.res.ColorStateList" import "android.animation.LayoutTransition" import 'com.google.android.material.slider.Slider' import 'com.google.android.material.button.MaterialButton' import "com.google.android.material.textfield.TextInputEditText" import "android.animation.ObjectAnimator" import "android.animation.AnimatorSet" import "android.view.animation.DecelerateInterpolator" import "android.view.animation.RotateAnimation" import "android.view.animation.Animation" import "android.graphics.drawable.BitmapDrawable" import "android.view.animation.AccelerateInterpolator" import "android.view.animation.DecelerateInterpolator" import "android.view.animation.OvershootInterpolator" import "android.view.animation.BounceInterpolator" import "android.view.animation.LinearInterpolator" import "android.view.animation.PathInterpolator" local transition = LayoutTransition() transition.setDuration(600) import("com.romainpiel.shimmer.Shimmer") import("com.romainpiel.shimmer.ShimmerTextView") import("com.romainpiel.shimmer.ShimmerButton") import("android.graphics.Canvas") import("android.graphics.Color") import("android.graphics.Paint") import "android.graphics.BitmapFactory" import "android.renderscri.*" import "android.graphics.Bitmap" import "android.graphics.Canvas" import "android.os.Handler" import "android.os.Looper" elgg.import("toast") elgg.import("HiddenApiBypass") elgg.import("内核读写") import "android.animation.ValueAnimator" import "android.animation.ArgbEvaluator" import "android.graphics.Typeface" toast.setMode(1) function cnmBackground1() local filePath = "/storage/emulated/0/时之初遇/资源/背景" local bmp = BitmapFactory.decodeFile(filePath) if bmp then return BitmapDrawable(activity.getResources(), bmp) end end local window = activity.getSystemService("window") local ed = {} import "android.graphics.drawable.GradientDrawable" function getStrokeBackground(fillColor, strokeColor, strokeWidth, radius) local gd = GradientDrawable() gd.setColor(fillColor) gd.setCornerRadius(radius) gd.setStroke(strokeWidth, strokeColor) return gd end --gg.setVisible(false) local HotPoint = luajava.bindClass("android.ext.HotPoint") local HP = HotPoint.getMethod("d") HotPoint = HotPoint.instance HotPoint.f() local function getVerticalBG(gtvb1, gtvb3, gtvb4, gtvb5) if not gtvb4 then gtvb4 = 0 gtvb5 = 0xff000000 end local colors = luajava.new(GradientDrawable) colors.setColor(gtvb1) colors.setCornerRadius(gtvb3) colors.setGradientType(GradientDrawable.LINEAR_GRADIENT) colors.setStroke(gtvb4, gtvb5) return colors end local function dp2px(dp) local metrics = activity.getResources().getDisplayMetrics() return math.floor(dp * metrics.density + 0.5) end function applyBestBlurEffect(view, radius) -- Android 12+ 使用RenderEffect if Build.VERSION.SDK_INT >= 31 then import "android.graphics.RenderEffect" import "android.graphics.Shader" local blurEffect = RenderEffect.createBlurEffect( radius, radius, Shader.TileMode.CLAMP ) view.setRenderEffect(blurEffect) return true end -- Android 8-11 使用RenderScri if Build.VERSION.SDK_INT >= 26 then local rootView = activity.getWindow().getDecorView().getRootView() local blurredBg = applyFullResBlur(rootView, radius) view.setBackgroundDrawable(BitmapDrawable(activity.getResources(), blurredBg)) return true end -- 旧版本使用简单模糊 local drawable = GradientDrawable() drawable.setColor(0x80000000) -- 半透明黑色 drawable.setCornerRadius(35) view.setBackgroundDrawable(drawable) return false end function miaobian(d, r, t, y) local drawable = GradientDrawable() drawable.setShape(GradientDrawable.RECTANGLE) drawable.setColor(t) -- 直接传入 0xAARRGGBB 格式的颜色值 drawable.setCornerRadii({r, r, r, r, r, r, r, r}) drawable.setStroke(d, y) -- 直接传入 0xAARRGGBB 格式的颜色值 return drawable end function zoom_animation(view) if dObjectAnimator == nil then dObjectAnimator = ObjectAnimator.ofFloat(view, "scaleX", 0, 1) dObjectAnimator.setDuration(600) dObjectAnimator.setInterpolator(DecelerateInterpolator()) end dObjectAnimator.start() end function getShepeBackground(color, radiu) local drawable = luajava.new(GradientDrawable) drawable.setShape(GradientDrawable.RECTANGLE) drawable.setColor(color) drawable.setCornerRadii({radiu, radiu, radiu, radiu, radiu, radiu, radiu, radiu}) return drawable end local function getButtonBG() local selector = StateListDrawable() local state = android.R.attr.state_pressed selector.addState({state}, getVerticalBG("0xffCCCCCC", 15)) selector.addState({-state}, getVerticalBG("0xffCCCCCC", 15)) return selector end local function getLayoutParams() LayoutParams = WindowManager.LayoutParams local layoutParams = luajava.new(LayoutParams) if (Build.VERSION.SDK_INT >= 26) then layoutParams.type = LayoutParams.TYPE_APPLICATION_OVERLAY else layoutParams.type = LayoutParams.TYPE_PHONE end layoutParams.format = PixelFormat.RGBA_8888 layoutParams.flags = LayoutParams.FLAG_NOT_FOCUSABLE | LayoutParams.FLAG_ALT_FOCUSABLE_IM layoutParams.gravity=Gravity.TOP|Gravity.LEFT layoutParams.width = LayoutParams.WRAP_CONTENT layoutParams.height = LayoutParams.WRAP_CONTENT return layoutParams end -- 新开一个线程来执情功能 local function threadStart(runnable) local newRun = luajava.createProxy("java.lang.Runnable", runnable) local subThread = luajava.newInstance("java.lang.Thread", newRun) subThread:start() end function 新线程(runnable) local Thread = luajava.bindClass("java.lang.Thread") local Runnable = luajava.bindClass("java.lang.Runnable") local myRunnable = luajava.createProxy("java.lang.Runnable", { run = runnable[1] }) local thread = luajava.new(Thread, myRunnable) return thread end local change_menu local background_list = { getShepeBackground("0xffE7EDED", 15), } local function log(text, color, size) -- 这是控制台输出的 local tmp = loadlayout { TextView, text = os.date("%m-%d %H:%M:%S ") .. text, textSize = size or '10sp', textColor = color, gravity = "left", layout_width = "wrap_content", } console_list.addView(tmp) console.fullScroll(View.FOCUS_DOWN) end -- 切换菜单 local change_menu local background_list = { getShepeBackground(0x00F4FAFB, 15), getShepeBackground(0x00F4FAFB, 15) } function ed.radio(cklist) if type(cklist) ~= "table" or #cklist == 0 then return loadlayout({ LinearLayout, layout_width = "match_parent", layout_height = "wrap_content", { TextView, text = "未提供选项", textColor = 0xFF757575, textSize = "13sp", layout_margin = "8dp" } }) end local radioG = { RadioGroup, gravity = "top", layout_height = "wrap_content", layout_margin = "4dp", layout_width = "match_parent", orientation = "vertical", } for i = 1, #cklist do local label = cklist[i][1] or ("选项 " .. tostring(i)) local callback = cklist[i][2] local rb = { RadioButton, gravity = "center_vertical", layout_height = "wrap_content", layout_marginLeft = "2dp", layout_marginRight = "2dp", layout_width = "match_parent", text = label, textSize = "13sp", textColor = 0xFF222222, onClick = function(view) if type(callback) == "function" then threadStart({run=function() pcall(callback, view) end}) end end } if font then rb.Typeface = font end radioG[#radioG + 1] = rb end return loadlayout(radioG) end -- 开关 ed.switch = function(name, func1, func2) local sw sw = loadlayout({ MaterialSwitch; text = " "..name; textColor = "#000000"; -- 黑色字体 padding = "5dp"; layout_width = "match"; layout_height = "match"; trackTintList=(ColorStateList({{android.R.attr.state_checked},{}},{0xFF000000,0x28FFFFFF})), thumbTintList=(ColorStateList({{android.R.attr.state_checked},{-android.R.attr.state_checked}},{0xFFFFFFFF,0xFF4B484F})), onClick = function() local func = sw.checked and func1 or func2 threadStart({ run = function() pcall(func) end }) end }) -- 关键修改:用圆角Shape背景 getShepeBackground(白色,15圆角),和box统一 local tmp = loadlayout({ LinearLayout, -- 替换纯色背景为圆角shape背景,圆角15,和ed.box一致 background = getShepeBackground(0xFFFFFFFF, 15), elevation="2dp", layout_width = 'fill_parent', layout_height = "40dp", layout_margin = "2dp", -- 和box边距对齐 gravity = "center_vertical", padding = { "0dp", "0dp", "6dp", "0dp" }, }) local rest = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = "wrap_content", gravity = "center_vertical", }) tmp.addView(sw) rest.addView(tmp) return rest end function showInput(id) local view = luajava.getIdView(id) if view then gg.alert(tostring(view:getText():toString())) else gg.alert("没有找到ID: " .. id) end end ed.button = function(name, func) local buttonLayout = { LinearLayout, layout_width = 'fill_parent', layout_height = "wrap_content", layout_margin = "2dp", elevation="2dp", { MaterialCardView, radius = 15, layout_width = 'fill_parent', layout_height = "wrap_content", strokeWidth = 0, clickable = true, focusable = true, checkable = true, onClick = function() if func then threadStart({ run = function() pcall(func) end }) end end, -- 关键修改:替换纯色背景为统一圆角Shape背景 background = getShepeBackground(0xFFFFFFFF, 15), { LinearLayout, layout_width = 'fill_parent', layout_height = "wrap_content", orientation = "horizontal", gravity = "center_vertical", padding = "10dp", { TextView, text = name, textColor = "#000000", -- 黑色文字 textSize = "14sp", layout_weight = 1, layout_marginLeft = "5dp", }, } } } return loadlayout(buttonLayout) end ed.Image = function(name, size) local ImageLayout = { MaterialCardView, -- setCardBackgroundColor = 0xFFEDE5D8, -- 注意这里应该是数字而不是字符串 layout_width = "match_parent", layout_height = size or "100dp", radius = 15, strokeWidth = 0, elevation="2dp", clickable = true, focusable = true, checkable = true, { ImageView, layout_width = "match_parent", layout_height = "match_parent", src = name, scaleType = "centerCrop" -- 关键属性,使图片居中裁剪填充 } } return loadlayout(ImageLayout) end nothing=function() end ed.seek = function(name,bian,smin,smax,nows,steps,lev,func) local sw func=func or nothing lev=lev or '倍' _ENV[bian] =nows or 1 local smin=tonumber(smin) local smax=tonumber(smax) steps=steps or 1 if not name then name = "未设置" end sw = loadlayout({ Slider, thumbHeight='23dp', trackHeight='15dp', trackStopIndicatorSize='0dp', tickVisible=false, __onFinish=function(v) if func then v.addOnSliderTouchListener({ onStopTrackingTouch=function(v) callAsyncTask(function() func(v.getValue()) end) end }) end v.setTrackActiveTintList(ColorStateList({{},},{0xff000000})) v.setTrackInactiveTintList(ColorStateList({{},},{0x55000000})) v.setThumbTintList(ColorStateList({{},},{0xff000000})) v.addOnChangeListener(function(SeekBar, var2, var3) _ENV[bian] = steps>=1 and string.format('%d',var2) or string.format('%.1f',var2) luajava.getIdView(names).setText(name..':'.._ENV[bian]..lev) end) end, layout_width = 'match_parent', id=luajava.newId(name.."seekbar"), layout_weight=1, valueFrom=smin, valueTo=smax, value=nows, stepSize=steps, }) local tmp = loadlayout({ LinearLayout, background = miaobian(0, 15, "0x33FFFFFF", "0x33FFFFFF"), -- 液态玻璃风格背景 layout_width = 'fill_parent', layout_height = "40dp", layout_marginLeft = '2dp', layout_marginRight = '2dp', layout_marginTop = '2dp', layout_marginBottom = '2dp', gravity = "center_vertical", padding = {"0dp", "0dp", "6dp", "0dp"}, { TextView, padding = {"5dp","10dp","0dp","10dp"}, gravity = "top", textColor = 0xFF000000, textSize = '13sp', text = name, layout_width = 'wrap_content', layout_marginLeft = "5dp", } }) local rest = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = "wrap_content", gravity = "center_vertical", }) tmp.addView(sw) rest.addView(tmp) return rest end ed.input = function(name,id) local tmp = { LinearLayout, layout_width = 'match_parent', layout_height = 'wrap_content', { TextView, text = name or "未设置文字", textSize = "16sp", textColor ="#444444", gravity = "center", layout_width = "match_parent", layout_weight = 2, }, { TextInputEditText, layout_weight = 1, hint = "请输入代码", hintTextColor = "#444444", layout_width = "match_parent", layout_height = "wrap", layout_margin = "2dp", focusable = true, focusableInTouchMode = true, cursorVisible = true, id = luajava.newId(id), } } return loadlayout(tmp) end -- 文字 ed.text = function(txt, color, size) local tmp = { TextView, text = txt or "未设置文字", textSize = size or "18sp", textColor = color or "#545454", layout_width = "wrap_content", } return loadlayout(tmp) end ed.kong = function(changdu) local tmp = { LinearLayout, layout_width = 'fill_parent', layout_height = changdu, } return loadlayout(tmp) end ed.buttonMenu = function(views) if #views == 0 then return end local mainLayout = loadlayout({ LinearLayout, layout_width = 'match_parent', layout_height = 'wrap_content', orientation = 'vertical' }) local buttonsPerRow = 3 local currentRow = nil local count = 0 local total = #views for i, v in ipairs(views) do if count % buttonsPerRow == 0 then currentRow = loadlayout({ LinearLayout, layout_width = 'match_parent', layout_height = 'wrap_content', orientation = 'horizontal', weightSum = buttonsPerRow -- 给每行锁死3份权重,根治拉伸 }) mainLayout.addView(currentRow) end local item = loadlayout({ LinearLayout, layout_width = "0dp", layout_height = "36dp", layout_weight = "1", -- 每个按钮固定占1份,永远等宽 layout_margin = "2dp", orientation = "horizontal", gravity = "center_vertical", paddingLeft = "4dp", paddingRight = "4dp", background = getStrokeBackground( 0xFFFFFFFF, 0xFFD7CCC8, 2, 12 ), onClick = function() if v[3] then threadStart({ run = function() pcall(v[3]) end, }) end end, onTouch = function(view, event) import "android.view.MotionEvent" if event.getAction() == MotionEvent.ACTION_DOWN then view.setScaleX(0.95) view.setScaleY(0.95) view.setAlpha(0.7) elseif event.getAction() == MotionEvent.ACTION_UP or event.getAction() == MotionEvent.ACTION_CANCEL then view.setScaleX(1) view.setScaleY(1) view.setAlpha(1) end return false end, { ImageView, layout_width = "26dp", layout_height = "26dp", layout_marginRight = "4dp", scaleType = "fitCenter", adjustViewBounds = true, src = v[2] }, { TextView, layout_width = "0dp", layout_weight = "1", layout_height = "wrap_content", text = v[1], textSize = "11sp", textColor = "0xFF000000", gravity = "right|center_vertical", maxLines = "1", ellipsize = "none", includeFontPadding = false, padding = "0dp" } }) currentRow.addView(item) count = count + 1 end -- 【核心修复】给最后一行补2个透明占位,锁死3列等宽,不报错、不破坏布局 local lastRow = mainLayout.getChildAt(mainLayout.getChildCount() - 1) if lastRow then local lastCount = lastRow.getChildCount() if lastCount < buttonsPerRow then import "android.graphics.drawable.ColorDrawable" for i = 1, buttonsPerRow - lastCount do local empty = loadlayout({ LinearLayout, layout_width = "0dp", layout_height = "36dp", layout_weight = "1", layout_margin = "2dp", background = ColorDrawable(0x00000000) -- 用API创建透明背景,彻底解决类型报错 }) lastRow.addView(empty) end end end return mainLayout end ed.checkbox = function(views) if #views == 0 then return end -- 1. 主布局:直接砍掉所有内边距,彻底消除上下空白 local mainLayout = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = 'wrap_content', orientation = 'vertical', padding = '0dp', -- 整体内边距清零,不浪费1px高度 paddingBottom = '0dp' -- 底部空白直接砍没 }) local scrollView = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = 'wrap_content', orientation = 'vertical', id = 'rows_container' }) mainLayout.addView(scrollView) local buttonsPerRow = 2 -- 保留你改好的一行2个 local currentRow = nil local buttonsInCurrentRow = 0 for i, v in ipairs(views) do if buttonsInCurrentRow % buttonsPerRow == 0 then currentRow = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = 'wrap_content', layout_weight = 1, orientation = 'horizontal', gravity = 'center_vertical', -- 2. 行内垂直居中,避免文字错位 layout_marginBottom = '1dp' -- 3. 行间距从4dp缩到1dp,几乎无缝 }) rows_container.addView(currentRow) end local sw = loadlayout({ CheckBox, layout_width = 'wrap_content', layout_height = '22dp', -- 保留你调好的22dp高度,不动! gravity = 'center_vertical', -- 文字垂直居中,不被切 buttonTintList=ColorStateList({{android.R.attr.state_checked},{-android.R.attr.state_checked}},{0xFf000000,0xff000000}), text = v[1], textColor = "#000000", onClick = function(view) local isChecked = view.isChecked() -- 和buttonMenu一样:用threadStart开线程执行,不卡UI+保留效果 threadStart({ run = function() if isChecked and v[2] then pcall(v[2]) elseif not isChecked and v[3] then pcall(v[3]) end end }) end }) local buju = loadlayout({ LinearLayout, layout_width = 'wrap_content', layout_height = '24dp', -- 和CheckBox高度完全同步,消除父容器空白 layout_weight = 1, gravity = 'center_vertical', layout_marginLeft = '4dp', layout_right = '4dp', sw }) currentRow.addView(buju) buttonsInCurrentRow = buttonsInCurrentRow + 1 end return mainLayout end layoutTransition=LayoutTransition() function visi (tid , ttid) local tview = luajava.getIdView (tid) local ttview = luajava.getIdView (ttid) if not tview then return 0 end if tonumber (tostring (tview : getVisibility ())) == 8.0 then tview.setVisibility (View.VISIBLE) else tview.setVisibility (View.GONE) end end -- 初始化 colorvs 变量 local colorvs = {} boxes={} boxpic={} function visi(tid, ttid) local tview = luajava.getIdView(tid) local arrowView = luajava.getIdView(tid.."_arrow") -- 获取箭头图标视图 if not tview then return 0 end if tonumber(tostring(tview:getVisibility())) == 8.0 then tview.setVisibility(View.VISIBLE) -- 展开时旋转箭头向下90度 local anim = ObjectAnimator.ofFloat(arrowView, "rotation", 0, 180) anim.setDuration(300) anim.start() else tview.setVisibility(View.GONE) -- 收缩时旋转箭头回到0度 local anim = ObjectAnimator.ofFloat(arrowView, "rotation", 180, 0) anim.setDuration(300) anim.start() end end function ed.box(views) local tid = "box"..string.randomUUID(true) colorvs[#colorvs+1] = {"box",tid} local arrowIcon = { ImageView, id = luajava.newId(tid.."_arrow"), layout_width="wrap_content", layout_height="wrap_content", src = "/storage/emulated/0/", ColorFilter = 0xFF000000 } local tid = tid.."6" -- 改:layout_margin = "2dp" 和上方统一 local firadio = { LinearLayout, layout_width='fill_parent', background = getShepeBackground(0xFFFFFFFF, 15), elevation="2dp", layout_height="wrap_content", layout_margin="2dp", -- 和switch/button边距一致 orientation="vertical", LayoutTransition = LayoutTransition() } if type(views[1]) == "string" or type(views[1]) == "number" then firadio[#firadio + 1] = { LinearLayout, layout_width='fill_parent', layout_height="40dp", -- 改成40dp,和switch头部高度一致 gravity="center_vertical", padding = {"0dp", "0dp", "6dp", "0dp"}, -- 内边距也对齐switch onClick = function() visi(tid,tid) end, { LinearLayout, layout_width='fill_parent', layout_height="40dp", layout_marginRight="2dp", -- 边距统一2dp layout_marginLeft="2dp", gravity="center_vertical", background = getShepeBackground(0xFFFFFFFF, 15), { TextView, gravity="center_vertical", text=views[1], textColor=0xFF000000, textSize="15sp", layout_weight=1, layout_marginLeft="15dp", layout_marginRight="20dp", layout_width='fill_parent', }, { LinearLayout, padding={"0dp","0dp","15dp","0dp"}, layout_width="30dp", layout_height="30dp", gravity="center", arrowIcon } } } else gg.alert("ed.M3box 的 table 内第一个元素必须是 string") os.exit() end local contentLayout = { LinearLayout, layout_marginLeft="10dp", layout_marginRight="10dp", layout_marginBottom="10dp", orientation="vertical", visibility="gone", id=luajava.newId(tid), layout_width='fill_parent', layout_height="wrap_content" } for i=2,#views do table.insert(contentLayout, views[i]) end local finalLayout = loadlayout(firadio) local contentView = loadlayout(contentLayout) finalLayout.addView(contentView) boxes[tid] = contentView return finalLayout end function getBG(colors, radiu, bk1, bk2) local GradientDrawable = luajava.bindClass("android.graphics.drawable.GradientDrawable") local drawable = GradientDrawable.new() drawable.setGradientType(GradientDrawable.LINEAR_GRADIENT) if type(colors) == "table" then drawable.setColors(luajava.toArray(colors, 'int')) else drawable.setColors(luajava.toArray({ colors, colors }, 'int')) end if type(radiu) == 'table' then drawable.setCornerRadii({ radiu[1], radiu[1], radiu[2], radiu[2], radiu[3], radiu[3], radiu[4], radiu[4] }) else drawable.setCornerRadii({ radiu, radiu, radiu, radiu, radiu, radiu, radiu, radiu }) end if bk1 ~= nil and bk2 ~= nil then drawable.setStroke(bk1, bk2) end return drawable end hanshu = function(v, event) --悬浮球移动事件 local Action = event.getAction() if Action == MotionEvent.ACTION_DOWN then window.updateViewLayout(windows, mainLayoutParams) isMove = false -- 点击时的XY坐标 RawX = event.getRawX() -- 获取X坐标 RawY = event.getRawY() -- 获取Y坐标 x = mainLayoutParams.x -- 申明变量xmX为原X坐标 y = mainLayoutParams.y -- 申明变量xmY为原Y坐标 elseif Action == MotionEvent.ACTION_MOVE then isMove = true -- 移动时的XY坐标 mainLayoutParams.x = tonumber(x) + (event.getRawX() - RawX) mainLayoutParams.y = tonumber(y) + (event.getRawY() - RawY) window.updateViewLayout(windows, mainLayoutParams) end end Userpanel=luajava.loadlayout({ LinearLayout, layout_width = "match", background = getShepeBackground(0xffffffff, 45), { CardView, background = getShepeBackground(0xffffffff, 45), layout_width = "180dp", layout_margin = "1dp", layout_height = "120dp", {RelativeLayout, layout_width = "match", layout_height = "match", -- 设置轮播图高度 { LinearLayout, orientation="vertical", layout_width = "match", layout_height = "match", -- 设置轮播图高度 background = cnmBackground1(), {RelativeLayout, layout_width = "match", layout_height = "match", { CircleImageView, src = "/storage/emulated/0/",--背景左侧 layout_margin = "10dp", layout_alignParentBottom = "true", layout_alignParentLeft = "true", elevation = '8dp', layout_height = "35dp", layout_width = "35dp", }, { ShimmerTextView, layout_width = "match", layout_height = "30dp", gravity = "center", elevation = '8dp', text = "时之初遇", layout_marginBottom = "20dp", layout_alignParentBottom = "true", reflectionColor = 0xffCDCDCD, textColor = 0xFF000000, -- 选用浅紫色 textSize = "12sp", __onFinish = function(v) -- 1. 新增:创建 Shimmer 实例(关键修复) local shimmer = Shimmer.newInstance() -- 2. 保留原文字发光配置 local paint = v.getPaint() local glowRadius = 15 -- 发光半径(可调整) local glowColor = v.getCurrentTextColor() -- 发光色与文字色一致 paint.setShadowLayer(glowRadius, 0, 0, glowColor) v.invalidate() -- 刷新视图生效发光 -- 3. 调用 start 启动闪烁动画(原代码保留,已补全实例) shimmer.start(v) -- 4. 保留原内存优化代码(不变) if v.getViewTreeObserver() ~= nil then v.getViewTreeObserver().addOnGlobalLayoutListener(luajava.createProxy("android.view.ViewTreeObserver$OnGlobalLayoutListener", { onGlobalLayout = function() if v.getParent() == nil then paint.setShadowLayer(0, 0, 0, 0) -- 清除发光 v.invalidate() v.getViewTreeObserver().removeOnGlobalLayoutListener(self) end end })) end end, }, { TextView, layout_width = "60dp", layout_height = "30dp", gravity = "center", elevation = '8dp', ellipsize="marquee", selected=true, singleLine=true, layout_marginLeft = "60dp", text = "@DCCBNB666", layout_alignParentBottom = "true", textColor = 0xFF000000, textSize = "10sp", }, } }, }, }, { LinearLayout, orientation="vertical", layout_width = "match", layout_height = "match", { LinearLayout, layout_weight = 1, layout_width = "match", layout_height = "match", { TextView, layout_width = "match", layout_height = "match", elevation = '8dp', gravity = "center", text = "到期时间:", layout_weight = 1, textColor = 0xFF000000, textSize = "10sp", }, { TextView, layout_width = "match", gravity = "center", layout_height = "match", elevation = '8dp', text =vip_text, ellipsize="marquee", selected=true, singleLine=true, layout_weight = 1, textColor = 0xff010101, textSize = "10sp", } }, { LinearLayout, layout_weight = 1, layout_width = "match", layout_height = "match", { TextView, layout_width = "match", layout_height = "match", elevation = '8dp', gravity = "center", text = "登录时间:", layout_weight = 1, textColor = 0xFF000000, textSize = "10sp", }, { TextView, layout_width = "match", gravity = "center", layout_height = "match", elevation = '8dp', text = "未知启动时间", layout_weight = 1, id = "timeText", textColor = 0xff010101, textSize = "9sp", } }, { LinearLayout, layout_weight = 1, layout_width = "match", layout_height = "match", { TextView, layout_width = "match", layout_height = "match", elevation = '8dp', gravity = "center", text = "启动时长:", layout_weight = 1, textColor = 0xFF000000, textSize = "10sp", }, { TextView, layout_width = "match", gravity = "center", layout_height = "match", elevation = '8dp', id = "timerText", text = "0s", layout_weight = 1, textColor = 0xff010101, textSize = "10sp", } }, { LinearLayout, layout_weight = 1, layout_width = "match", layout_height = "match", { TextView, layout_width = "match", layout_height = "match", elevation = '8dp', gravity = "center", id = 'window_exit', text = "退出登录", layout_weight = 1, textColor = 0xFF000000, textSize = "10sp", },}}}) ed.menu = function(icon, title, menu) PageNum = {} local menu_list = { LinearLayout, layout_height = "wrap", gravity = "center", layout_width = "match_parent", orientation = "vertical", id = "menu_list", } local sidebarMenu = { HorizontalScrollView, background = getShepeBackground(0xffffffff, 15), layout_height = "40dp", layout_width = "match_parent", elevation = "3dp", layout_margin = "5dp", menu_list } local menu_lit = { LinearLayout, layout_height = "wrap", gravity = "center", layout_width = "match_parent", orientation = "vertical", id = "menu_lit", } local menu_layout = {} local icon_list = {} SecondPage = {} NowPage = 1 MainMenus = { CardView, background = getShepeBackground(0x00ffffff, 35), layout_margin = "5dp", layout_width = "match_parent", layout_height = "wrap_content", { LinearLayout, layout_height = "wrap_content", id = "main", layout_width = "match_parent", orientation = "vertical", } } SecondBG = {} FirstBG = {} TitleName = {} for i, v in ipairs(menu) do TitleName[i] = {} FirstBG[i] = "0xff007BFF" SecondBG[i] = {} PageNum[i] = #v['二级分页'] local SecondPageV = { LinearLayout, -- visibility = i == 1 and 'visible' or 'gone', layout_height = "wrap", gravity = "center", layout_width = "match_parent", id = luajava.newId('SecondPageV' .. i), } for j = 1, #v['二级分页'] do TitleName[i][j] = v['二级分页'][j]['分页名字'] SecondBG[i][j] = miaobian(3, 15, "0xAAEDEDED", "0xffEDEDED") local item = { LinearLayout, layout_width = "wrap", layout_margin = "2dp", layout_height = "match_parent", id = luajava.newId('Second' .. i .. 'P' .. j), background = SecondBG[i][j], gravity = "center", onClick = function() change_area(j) end, { ImageView, layout_width = "30dp", layout_height = "30dp", layout_margin = "3dp", src = v['二级分页'][j]['分页logo'] or icon }, { LinearLayout, layout_width = "wrap", layout_height = "match_parent", layout_margin = "5dp", orientation = "vertical", { TextView, text = v['二级分页'][j]['分页名字'], textColor = "0xff010101", textSize = "12sp", layout_width = "wrap", layout_height = "wrap", }, { TextView, text = v['二级分页'][j]['分页描述'] or " ",--分页描述 textColor = "0xff515151", textSize = "8sp", layout_width = "wrap", layout_height = "wrap", }, } } table.insert(SecondPageV, item) local funclayout = { LinearLayout, layout_width = "match_parent", id = 'layout_func' .. i .. 'p' .. j, gravity = "center_horizontal", orientation = "vertical", } for _, k in ipairs(v['二级分页'][j]['分页菜单']) do table.insert(funclayout, k) end table.insert(MainMenus, { LinearLayout, id = luajava.newId('Menu' .. i .. 'P' .. j), layout_height = "wrap_content", layout_width = "match_parent", orientation = "vertical", { ScrollView, fillViewport = "true", layout_width = "match_parent", layout_height = "wrap_content", funclayout }, }) end table.insert(menu_list, SecondPageV) local items = loadlayout { LinearLayout, layout_width = "match_parent", layout_height = "wrap_content", layout_margin = "2dp", orientation = "vertical", gravity = "center", onClick = function() change_menu(i) end, -- 图片(控制大小 + 不裁剪) { ImageView, layout_width = "45dp", -- ⭐ 控制大小 layout_height = "45dp", -- ⭐ 1:1 正方形 adjustViewBounds = true, scaleType = "fitCenter", -- ⭐ 不裁剪,完整显示 src = v['分区logo'] or icon }, -- 文字 { TextView, text = v['分区名字'], id = luajava.newId('FirstBG' .. i), textSize = "11sp", layout_width = "wrap_content", layout_height = "wrap_content", textColor = FirstBG[i], gravity = "center", layout_marginTop = "3dp" }, } table.insert(menu_lit, items) -- 给右侧菜单加功能 end -- 首先定义根视图 local layout = { FrameLayout, id = "windows", onClick=function(v) end, onTouch = hanshu, { -- 占位视图(用于保持动画过程中的尺寸) LinearLayout, id = "placeholder", layout_width = 宽度, layout_height = 高度, visibility = "gone", }, { FrameLayout, layout_height = "match_parent", layout_width = "match_parent", onClick = function()end, onTouch = hanshu, __onFinish=function(v) local layoutTransition = LayoutTransition() layoutTransition.setDuration(600) layoutTransition.setInterpolator(layoutTransition.CHANGE_APPEARING, AccelerateInterpolator()) v.setLayoutTransition(layoutTransition) end, { CardView, background = getShepeBackground(0xfff5f5f5, 15), visibility = "gone", id = 'window_flor', { RelativeLayout, layout_height = 高度, layout_width = 宽度, { LinearLayout, layout_height = 高度, layout_width = 宽度, { -- 功能部分 LinearLayout, layout_height = "match_parent", layout_width = "100dp", orientation = "vertical", gravity = "center", { LinearLayout, layout_height = "match_parent", layout_width = "match_parent", { LinearLayout, layout_height = "match_parent", layout_width = "match_parent", orientation = "vertical", --background = getBG(0x33ffffff, {15,0,0,15}), gravity = "center", layout_weight = "1", { CardView; layout_width = "50dp"; layout_height = "50dp"; layout_marginTop = "5dp"; layout_margin = "5dp"; radius = "25dp"; -- 圆角半径一半即为圆形 cardElevation = "6dp"; cardBackgroundColor = "0xFFD7CCC8"; -- 背景白色或透明都情 layout_gravity = "center"; { ImageView; layout_width = "match_parent"; layout_height = "match_parent"; clickable = true; focusable = true; id = luajava.newId("yddd"); onClick = function() lessenwindow() end; onTouch = hanshu; src = 头像; scaleType = "fitCenter"; }; }; { ShimmerTextView, layout_width = "match", layout_height = "30dp", gravity = "center", text = 左上角ID, reflectionColor = 0xfffffff, textColor = 0xFF000000, -- 选用浅紫色 textSize = "16sp", __onFinish = function(v) -- 1. 新增:创建 Shimmer 实例(关键修复) local shimmer = Shimmer.newInstance() -- 2. 保留原文字发光配置 local paint = v.getPaint() local glowRadius = 15 -- 发光半径(可调整) local glowColor = v.getCurrentTextColor() -- 发光色与文字色一致 paint.setShadowLayer(glowRadius, 0, 0, glowColor) v.invalidate() -- 刷新视图生效发光 -- 3. 调用 start 启动闪烁动画(原代码保留,已补全实例) shimmer.start(v) -- 4. 保留原内存优化代码(不变) if v.getViewTreeObserver() ~= nil then v.getViewTreeObserver().addOnGlobalLayoutListener(luajava.createProxy("android.view.ViewTreeObserver$OnGlobalLayoutListener", { onGlobalLayout = function() if v.getParent() == nil then paint.setShadowLayer(0, 0, 0, 0) -- 清除发光 v.invalidate() v.getViewTreeObserver().removeOnGlobalLayoutListener(self) end end })) end end, }, { -- 侧边栏 菜单按钮 ScrollView, layout_height = "match_parent", layout_width = "match_parent", -- layout_marginBottom = "45dp", menu_lit }, }, }, }, { LinearLayout, layout_height = "match_parent", layout_width = "match_parent", orientation = "vertical", -- ⭐ 顶部留白栏 { LinearLayout, layout_width = "match_parent", layout_height = "45dp", gravity = "center_vertical", padding = "8dp", -- 左边文字 { TextView, layout_width = "0dp", layout_height = "wrap_content", layout_weight = "1", text = 版本名称, textSize = "16sp", textColor = "0xff333333" }, -- 缩小按钮 { ImageView, layout_width = "30dp", layout_height = "30dp", layout_marginRight = "10dp", src = "/storage/emulated/0/时之初遇/资源/缩小", onClick = function() lessenwindow() end } }, -- ⭐ 中间功能区 { LinearLayout, layout_width = "match_parent", layout_height = "0dp", layout_weight = "1", orientation = "vertical", MainMenus }, -- ⭐ 二级分页移动到底部 sidebarMenu }, }, {--公告栏 LinearLayout, orientation="vertical", id = luajava.newId('例子4'), background = getShepeBackground(0xAACCCCCC, 15), layout_width = "match_parent", layout_height = "match_parent", {CardView, background = getShepeBackground(0xffFAFAFA, 45), layout_width = "match_parent", layout_margin = "30dp", layout_height = "match_parent", {CardView, layout_height = "25dp", layout_width = "65dp", onClick = function(v) -- CATransition('例子4','yddd', 1000, BounceInterpolator(),function() CATransition('例子4','例子3', 600, OvershootInterpolator(), function()end, function()end,nil,nil,nil,true) end, layout_margin = "2dp", -- 左侧外边距 5dp background = getShepeBackground(0x00eeeeee, 25), {LinearLayout, layout_height = "30dp", layout_width = "match", {CardView; elevation = "3dp"; layout_height = "14dp", layout_width = "14dp", background = getShepeBackground(0xffFE645C, 360), layout_margin = "4dp", };{CardView; elevation = "3dp"; layout_height = "14dp", layout_width = "14dp", background = getShepeBackground(0xffFFBB38, 360), layout_margin = "4dp", };{ CardView; elevation = "3dp"; layout_height = "14dp", layout_width = "14dp", background = getShepeBackground(0xff2FC849, 360), layout_margin = "4dp", }; }, },--红绿灯 {LinearLayout, layout_height = "match", layout_width = "match", layout_marginTop = "23dp", ed.text("如果美化的时候出现空白人请切换方案\n判断播报如果判断自身出现封禁,请使用判断手持\n开启枪械切完配件后,等他响第二声才能再去美化其他枪械"), --这里写公告页 }, },--空白 },--公告栏 { RelativeLayout; layout_width = "match_parent"; layout_height = "match_parent"; id = "snowContainer"; elevation="6dp"; background = "#00000000"; }, }, }, { LinearLayout, layout_height = "45dp", layout_width = "45dp", elevation = "5dp", id = "controlWindow", onClick = function()end, onTouch = hanshu, { CircleImageView, src = 头像, onTouch = hanshu, onClick = function() lessenwindow() end, layout_height = "45dp", layout_width = "45dp", }}, }, ViewFakeTransition, }; local window_layout = loadlayout(layout) windows.setBackground(background_list[1]) -- 设置背景 NowPage = 1 mainLayoutParams = getLayoutParams() change_menu = function(j) NowPage = j for i = 1, #PageNum do luajava.getIdView('SecondPageV' .. i).setVisibility(View.GONE) luajava.getIdView('FirstBG' .. i).setTextColor(0xff333333) end luajava.getIdView('FirstBG' .. NowPage).setTextColor(FirstBG[NowPage]) luajava.getIdView('SecondPageV' .. j).setVisibility(View.VISIBLE) if not SecondPage[j] then change_area(1) else change_area(SecondPage[j]) end end function change_area(x) SecondPage[NowPage] = x for i = 1, #PageNum do for j = 1, PageNum[i] do luajava.getIdView('Menu' .. i .. 'P' .. j).setVisibility(View.GONE) luajava.getIdView('Second' .. i .. 'P' .. j).setBackground(nil) luajava.getIdView('Menu' .. i .. 'P' .. j).setVisibility(View.GONE) end end luajava.getIdView('Second' .. NowPage .. 'P' .. x).setBackground(SecondBG[NowPage][x]) luajava.getIdView('Menu' .. NowPage .. 'P' .. x).setVisibility(View.VISIBLE) end window_exit.onClick = function() HP.invoke(HotPoint, nil) stoimer() window.removeView(window_layout, mainLayoutParams) Looper.myLooper().quitSafely() end function lessenwindow() local isMenuVisible = window_flor.getVisibility() ~= View.VISIBLE if isMenuVisible then placeholder.setVisibility(View.VISIBLE) mainLayoutParams.flags = LayoutParams.FLAG_NOT_TOUCH_MODAL --window.updateViewLayout(windows, mainLayoutParams) controlWindow.setVisibility(View.GONE) window_flor.setVisibility(View.VISIBLE) Handler().postDelayed(function() placeholder.setVisibility(View.GONE) window.updateViewLayout(windows, mainLayoutParams) end, 650) else -- 立即显示菜单 mainLayoutParams.flags = LayoutParams.FLAG_NOT_FOCUSABLE --window.updateViewLayout(windows, mainLayoutParams) -- 先显示controlWindow,延迟隐藏menu placeholder.setVisibility(View.VISIBLE) controlWindow.setVisibility(View.VISIBLE) window_flor.setVisibility(View.GONE) Handler().postDelayed(function() placeholder.setVisibility(View.GONE) window.updateViewLayout(windows, mainLayoutParams) end, 650) end end Handler(Looper.getMainLooper()) Looper.prepare() window.addView(windows, mainLayoutParams) import "android.os.Handler" local handler = Handler() local startTime = os.time() local runnable -- 启动计时器 function startTimer() local runnable runnable = luajava.createProxy("java.lang.Runnable", { run = function() local elapsed = os.time() - startTime timerText.setText(tostring(elapsed).."s") handler.postDelayed(runnable, 1000) end }) handler.post(runnable) end -- 停止计时器(退出时调用) function stoimer() if runnable then handler.removeCallbacks(runnable) runnable = nil end end -- 启动时调用 startTimer() -- 在布局加载完成后执情 local nowTime = os.date("%Y年%m月%d日") -- 格式:2025.09.19 timeText.setText(nowTime) local wm = getLayoutParams() wm.flags = LayoutParams.FLAG_NOT_FOCUSABLE window.addView(luajava.loadlayout({ LinearLayout, __onFinish = function(v) starv = v end }), wm) change_menu(1) local snowConfig = { flakeCount = 10, minSize = 1, maxSize = 30, minSpeed = 1000, maxSpeed = 2000, minDelay = 300, maxDelay = 800, windEnabled = true, maxWind = 20, minRotation = -360, maxRotation = 360, rotationProbability = 0.6, --flakeImages = {"❄️", "❄", "❅", "❆", "❊"} } local function createSnowFlake(delay) if not isSnowActive then return end Handler().postDelayed(function() if not isSnowActive then return end local flakeChar = snowConfig.flakeImages[math.random(1, #snowConfig.flakeImages)] local flakeSize = math.random(snowConfig.minSize, snowConfig.maxSize) local flakeView = TextView(activity) flakeView.setText(flakeChar) flakeView.setTextSize(flakeSize) flakeView.setLayoutParams(LinearLayout.LayoutParams( ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT )) flakeView.setTextColor(0xFFFFFFFF) -- 添加阴影效果 local shadowRadius = math.random(2, 5) local shadowX = math.random(-3, 3) local shadowY = math.random(1, 3) local shadowColor = 0x80000000 flakeView.setShadowLayer(shadowRadius, shadowX, shadowY, shadowColor) snowContainer.addView(flakeView) local containerWidth = snowContainer.getWidth() local startX = math.random(0, containerWidth) local startY = math.random(-100, -20) flakeView.setX(startX) flakeView.setY(startY) flakeView.post(function() if not isSnowActive then snowContainer.removeView(flakeView) return end local containerHeight = snowContainer.getHeight() local duration = math.random(snowConfig.minSpeed, snowConfig.maxSpeed) local windOffset = snowConfig.windEnabled and math.random(-snowConfig.maxWind * 2, snowConfig.maxWind * 2) or 0 local animY = ObjectAnimator.ofFloat(flakeView, "y", startY, containerHeight + flakeSize) animY.setDuration(duration) animY.setInterpolator(LinearInterpolator()) local animX = ObjectAnimator.ofFloat(flakeView, "x", startX, startX + (containerWidth * windOffset / 100)) animX.setDuration(duration) local animSet = AnimatorSet() if math.random() < snowConfig.rotationProbability then local rotation = math.random(snowConfig.minRotation, snowConfig.maxRotation) local animRotate = ObjectAnimator.ofFloat(flakeView, "rotation", 0, rotation) animRotate.setDuration(duration) animSet.playTogether(animY, animX, animRotate) else animSet.playTogether(animY, animX) end animSet.addListener({ onAnimationEnd = function() if isSnowActive then snowContainer.removeView(flakeView) -- 无限循环生成新雪花 createSnowFlake(math.random(snowConfig.minDelay, snowConfig.maxDelay)) end end, onAnimationCancel = function() snowContainer.removeView(flakeView) end }) animSet.start() end) end, delay or math.random(snowConfig.minDelay, snowConfig.maxDelay)) end local function initSnowFlakes() isSnowActive = true for i = 1, snowConfig.flakeCount do createSnowFlake(math.random(0, 50)) end end local function clearSnowAnimation() isSnowActive = false snowContainer.removeAllViews() end snowContainer.post(function() initSnowFlakes() end) Looper.loop() end import 'android.graphics.Bitmap' import 'android.graphics.Canvas' import 'android.graphics.Rect' ViewFakeTransition = loadlayout({ FrameLayout, visibility = 'gone', elevation = '10dp', { ImageView, layout_height = 'match_parent', layout_width = 'match_parent' }, { ImageView, layout_height = 'match_parent', layout_width = 'match_parent' } }) local nothing = function() end function View2Bitmap(view, isblur) local width = view.getMeasuredWidth() local height = view.getMeasuredHeight() if width == 0 then width = 1 height = 1 end local bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); local canvas = Canvas(bitmap) canvas.translate(-view.getScrollX(), -view.getScrollY()) view.draw(canvas) if isblur then return getBlur(bitmap) else return bitmap end end function CAViewInfo(v) local info = luajava.astable(v.getLocationOnScreen()) local start = luajava.astable(starv.getLocationOnScreen()) return { info[1] - (mainLayoutParams.x - mainLayoutParams.width / 2) - start[1], info[2] - (mainLayoutParams.y - mainLayoutParams.height / 2) - start[2] } end import "android.animation.ObjectAnimator" import "android.view.animation.Animation" import "android.animation.ArgbEvaluator" import "android.animation.ValueAnimator" import "android.animation.FloatEvaluator" function CATransition(view1, view2, duration, polator, func, func2, keep,keepp) --起点[view对象或id字符串],终点[view对象或id字符串],时长[毫秒],插值器,开始函数,结束函数,是否保留起点可见[bool] func = func or nothing func2 = func2 or nothing if type(view1) == 'string' then view1 = luajava.getIdView(view1) end if type(view2) == 'string' then view2 = luajava.getIdView(view2) end if view1.getVisibility() == View.GONE then return end if view2.getVisibility() == View.GONE then return end if ViewFakeTransition.getVisibility() == View.VISIBLE then return end ViewFakeTransition.setVisibility(View.VISIBLE) local P1 = CAViewInfo(view1) local P2 = CAViewInfo(view2) local DrawingView1, DrawingView2 = ViewFakeTransition.getChildAt(0), ViewFakeTransition.getChildAt(1) DrawingView1.setImageBitmap(View2Bitmap(view1)) DrawingView1.setAlpha(1) DrawingView2.setImageBitmap(View2Bitmap(view2)) DrawingView2.setAlpha(0) local height1, width1, height2, width2, P11, P12, P21, P22 = view1.getMeasuredHeight(), view1.getMeasuredWidth(), view2.getMeasuredHeight(), view2.getMeasuredWidth(), P1[1], P1[2], P2[1], P2[2] if not keep then view1.setVisibility(View.INVISIBLE) end if not keepp then view2.setVisibility(View.INVISIBLE) end local VP = ViewFakeTransition.getLayoutParams() VP.height = height1 VP.width = width1 VP.setMargins(P11, P12, 0, 0) ViewFakeTransition.setLayoutParams(VP) local animator = ValueAnimator.ofObject(FloatEvaluator(), {0, 1}).setDuration(duration) animator.setInterpolator(polator) local listener = luajava.createProxy('android.animation.ValueAnimator$AnimatorUpdateListener', { onAnimationUpdate = function(animation) local animatedProgress = animation.getAnimatedValue() if animatedProgress > 1 then animatedProgress = 1 + (animatedProgress - 1) / 6 end VP.height = height1 + (height2 - height1) * animatedProgress VP.width = width1 + (width2 - width1) * animatedProgress VP.setMargins(P11 + (P21 - P11) * animatedProgress, P12 + (P22 - P12) * animatedProgress, 0, 0) ViewFakeTransition.setLayoutParams(VP) DrawingView1.setAlpha(1 - animatedProgress) DrawingView2.setAlpha(animatedProgress) end }) animator.addUpdateListener(listener) local listener = luajava.createProxy('android.animation.Animator$AnimatorListener', { onAnimationStart = func, onAnimationEnd = function() view2.setVisibility(View.VISIBLE) ViewFakeTransition.setVisibility(View.GONE) -- floatmain.removeView(ViewFakeTransition) window.updateViewLayout(floatWindow, mainLayoutParams) view2.setVisibility(View.VISIBLE) func2() end, onAnimationCancel = function(animator) end }) animator.addListener(listener) animator.start() end function 白权() ue4 = staticstart({"libUE4.so:bss", "Cb"}) hqdz = shan(ue4, {0x5524F0,0x30,0x4B8,0x2E40,0x3E8, 0x0}) end function 脸部(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 1 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 隐藏脸部(修改值) 白权() for xh = 0x0, 0x999, 0x38 do setvalue(hqdz + 0x0 + xh, D, 修改值) end end function 头发(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 2 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 眼镜(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 12 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 帽子(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 3 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 面罩(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 4 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 衣服(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 5 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 裤子(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 6 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 鞋子(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 7 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 背包(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 8 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 头盔(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 9 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 护甲(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 10 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 手(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 23 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 眼罩(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 12 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 内衣(修改值) 白权() for xh = 0x0, 0x999, 0x3C do local 类型值 = getvalue(hqdz + 0x8 + xh, D) if 类型值 == 24 or 类型值 == 12 then setvalue(hqdz + 0x0 + xh, D, 修改值) setvalue(hqdz + 0x8 + xh, D, 12) end end end function 内裤(修改值) 白权() for xh = 0x0, 0x999, 0x3C do local 类型值 = getvalue(hqdz + 0x8 + xh, D) if 类型值 == 25 or 类型值 == 4 then setvalue(hqdz + 0x0 + xh, D, 修改值) setvalue(hqdz + 0x8 + xh, D, 4) end end end local 当前方案 = "方案一" local arr_off1 = 0xd898 local arr_off2 = 0xd868 local last_val1 = 0 local last_val2 = 0 local 角色基地址 = nil local 基础偏移 = 0x18 -- 统一初始化 local function 初始化() 角色基地址 = nil -- 每次都重新搜,解决偶尔找不到 local range = gg.getRangesList("libUE4.so:bss", "Cb") if not range or #range == 0 then toast("未找到 libUE4.so:bss") return end local UE4 = range[1].start -- 扩大范围,提高找到概率 for i = 1, 2000 do local addr1 = get64zz(UE4 + 0xE2E00) local addr2 = get64zz(addr1 + 0x648) local addr3 = get64zz(addr2 + i * 0x4) local addr4 = get64zz(addr3 + 0x38) local 临时地址 = get64zz(addr4 + 0x38) local 判断地址 = get64zz(临时地址 + 0x20) + 0x18 if readD(判断地址) == 1000 then 角色基地址 = 临时地址 return true -- 找到就退出 end end return false end -- 方案一 local function 套装过一秒1(修改值) if not 初始化() then toast("方案一:未找到角色") return end local 皮肤地址 = get64zz(角色基地址 + arr_off1) + 基础偏移 last_val1 = getvalue(皮肤地址, D) setvalue(皮肤地址, D, 修改值) 衣服(last_val1) arr_off1 = arr_off1 + 0x18 if arr_off1 > 0xd898 + 60*0x18 then arr_off1 = 0xd898 end gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end -- 方案二 local function 套装过一秒2(修改值) if not 初始化() then toast("方案二:未找到角色") return end local 皮肤地址 = get64zz(角色基地址 + arr_off2) + 基础偏移 last_val2 = getvalue(皮肤地址, D) setvalue(皮肤地址, D, 修改值) 衣服(last_val2) arr_off2 = arr_off2 + 0x18 if arr_off2 > 0xd868 + 60*0x18 then arr_off2 = 0xd868 end gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end -- 统一入口 function 套装过一秒(修改值) if 当前方案 == "方案一" then 套装过一秒1(修改值) else 套装过一秒2(修改值) end end function 调用方案一() 当前方案 = "方案一" toast.success("已切换:方案一") end function 调用方案二() 当前方案 = "方案二" toast.success("已切换:方案二") end --------枪械 local RUI = function(a) return gg.getValues({{address=a,flags=gg.TYPE_QWORD}})[1].value end local readD = function(a) return gg.getValues({{address=a,flags=4}})[1].value end local 写入 = function(a,f,v) gg.setValues({{address=a,flags=f,value=v}}) end local function getFinalAddr() local base = gg.getRangesList("libUE4.so:bss","Cb")[1].start local o = {0x5524F0,0x30,0x4B8,0x25B8,0x5C8,0x7A0,0x11c} local p = base p = RUI(p+o[1]) p = RUI(p+o[2]) p = RUI(p+o[3]) p = RUI(p+o[4]) p = RUI(p+o[5]) p = RUI(p+o[6]) return p end function 枪械(val) local p = getFinalAddr() 写入(p+0x11C,4,val) toast.success("2秒内切枪") gg.sleep(2000) 写入(p+0x11C,4,0) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end function 枪口(val) local p=getFinalAddr() 写入(p+0x04,4,val) end function 握把(val) local p=getFinalAddr() 写入(p+0x2C,4,val) end function 弹夹(val) local p=getFinalAddr() 写入(p+0x54,4,val) end function 枪托(val) local p=getFinalAddr() 写入(p+0x7C,4,val) end function 播报(val) local p=getFinalAddr() 写入(p+0x194,4,val)end function 红点(skin) local p=getFinalAddr() if readD(p+0xA4)==203001 then 写入(p+0xA4,4,skin) end end function 全息(skin) local p=getFinalAddr() if readD(p+0xA4)==203002 then 写入(p+0xA4,4,skin) end end function 二倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203003 then 写入(p+0xA4,4,skin) end end function 三倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203014 then 写入(p+0xA4,4,skin) end end function 四倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203004 then 写入(p+0xA4,4,skin) end end function 六倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203015 then 写入(p+0xA4,4,skin) end end function 八倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203005 then 写入(p+0xA4,4,skin) end end 高度 =950 宽度 =1400 头像='/storage/emulated/0/时之初遇/资源/头像' 左上角ID = '时之初遇'--项目名称 版本名称 = '❄ 1.0 版 本 ❄️' menum = { { ['分区名字']='美化主页', ['分区logo']='/storage/emulated/0/时之初遇/资源/主页', ['二级分页']={ { ['分页名字']='公告', ['分页logo']='99999', ['分页菜单']={ { TextView, id = luajava.newId('例子3'), text = '公告', onClick = function(v) CATransition('例子3', '例子4', 500, OvershootInterpolator(),nil,nil,true) end, }, Userpanel,--用户信息面板 ed.kong("3dp"), ed.button("选择进程", function() gg.setProcessX() gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("选择进程") end), ed.button("清除冻结", function() gg.clearList() gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("清除成功") end), ed.box({"判断播报(未更新)", ed.checkbox({--三个一行 { "判断播报(手持)", function() end }, { "判断播报(自身)", function() end }, }), }), ed.box({"美化方案", ed.checkbox({--三个一行 { "方案一(默认)", function() 调用方案一() end }, { "方案二", function() 调用方案二() end }, }), }), }}, { ['分页名字']='功能', ['分页logo']='99999', ['分页菜单']={--直接写table的例子,看起来会比较乱 ed.seek('动态广角','cess',90,130,90,1,'动态广角',--名称,id,最小值,最大值,当前值,步长,单位 function(v) local t = {"libUE4.so:bss", "Cb"} local tt = {0x5524F0,0x30,0x4B8,0x1D40,0x39C} local ttt = S_Pointer(t, tt, true) gg.addListItems({{address = ttt, flags = 16, value = v, freeze = true}}) toast.success("动态广角:" .. v) end), ed.seek('游戏帧率','cess',60,165,60,1,'游戏帧率',--名称,id,最小值,最大值,当前值,步长,单位 function(z) local t = {"libUE4.so:bss", "Cb"} local tt = {0x1FC8, 0x18} local ttt = S_Pointer(t, tt, true) gg.addListItems({{address = ttt, flags = 16, value = z, freeze = true}}) local t = {"libUE4.so:bss", "Cb"} local tt = {0x1FC8, 0x1C} local ttt = S_Pointer(t, tt, true) gg.addListItems({{address = ttt, flags = 16, value = z, freeze = true}}) toast.success("游戏帧率:" .. z) end), ed.switch("微加速", function() local r = gg.prompt({"微加速: [推荐使用1.2 最高5]"}, {"1.2"}, {"text"}) if not r then gg.toast("操作取消") return end local Q = tonumber(r[1]) -- 数值校验 if not Q or Q < 0 or Q > 5 then gg.toast("输入无效!请输1-5的数值") return end local t = {"libUE4.so:bss", "Cb"} local tt = {0x5524F0,0x30,0x4B8,0x1168} local ttt = S_Pointer(t, tt, true) gg.addListItems({{address = ttt, flags = 16, value = Q, freeze = true}}) toast.success("微加速:" .. Q) end), ed.box({"高危功能(请使用内核模式)", ed.checkbox({--三个一行 { "范围", function() end }, { "游戏除雾", function() if gg.getRangesList("libUE4.so")[1] then local t = {} t[1] = gg.getRangesList("libUE4.so")[1]["start"] + 0x8ca13e0; -- 数值地址:0x78E36576B8 gg.addListItems({ [1] = { address = t[1], flags = 4, value = -721215457, freeze = true, }, }) end end, function() if gg.getRangesList("libUE4.so")[1] then local t = {} t[1] = gg.getRangesList("libUE4.so")[1]["start"] + 0x8ca13e0; -- 数值地址:0x78E36576B8 gg.addListItems({ [1] = { address = t[1], flags = 4, value = -1119851903, freeze = true, }, }) end end },{ "据点", function() end }, }), }), }}, { ['分页名字']='设置', ['分页logo']='99999', ['分页菜单']={--直接写table的例子,看起来会比较乱 ed.switch("内核模式", function() 内核读写("开") end, function() 内核读写("关") end), ed.switch("隐藏GG图标", function() gg.hide(true) toast.success("隐藏GG") end, function() gg.hide(false) toast.error("显示GG") end), }, },--二分页 }},--主分页 {--主分页 ['分区名字']='服饰', ['分区logo']='/storage/emulated/0/时之初遇/资源/衣服', ['二级分页']={ {--二分页 ['分页名字']='套装', ['分页logo']='9999', ['分页菜单']={ ed.text("没效果就切换方案"), ed.buttonMenu({ {"重置自身", "/storage/emulated/0/时之初遇/资源/隐藏", function() 帽子(0) 头发(0) --隐藏脸部(257) --脸部(405200) --眼镜(0) --面罩(0) 衣服(0) 裤子(0) 鞋子(0) 背包(0) 头盔(0) 护甲(0) 内衣(405200) 内裤(405200) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"炽羽菲妮萨", "/storage/emulated/0/时之初遇/资源/炽羽菲妮萨", function() 头发(402378) 内裤(402381) 套装过一秒(1407856) end}, {"秘渊灵主", "/storage/emulated/0/时之初遇/资源/秘渊灵主", function() 头发(402147) 脸部(402154) 套装过一秒(1406971) end}, {"风灵迦尔", "/storage/emulated/0/时之初遇/资源/风灵迦尔", function() 套装过一秒(1407366) 头发(1407372) 内裤(1407369) 脸部(1407373) end}, {"蚀魂冥王", "/storage/emulated/0/时之初遇/资源/蚀魂冥王", function() 套装过一秒(1406891) 头发(1410436) end}, {"血鸦", "/storage/emulated/0/时之初遇/资源/血鸦", function() 内裤(1403257) 套装过一秒(1407895) end}, {"极地冥王", "/storage/emulated/0/时之初遇/资源/极地冥王", function() 套装过一秒(1407618) end}, {"曙光芙洛拉", "/storage/emulated/0/时之初遇/资源/曙光芙洛拉", function() 内裤(1403655) 脸部(402165) 头发(1410561) 套装过一秒(1407103) end}, {"曙光女帝", "/storage/emulated/0/时之初遇/资源/曙光女帝", function() 脸部(402296) 头发(402297) 套装过一秒(1407558) end}, {"逍遥谪仙", "/storage/emulated/0/时之初遇/资源/逍遥谪仙", function() 脸部(402260) 头发(402261) 套装过一秒(1407470) end}, {"烈焰古神", "/storage/emulated/0/时之初遇/资源/烈焰古神", function() 头发(1410668) 套装过一秒(1407277) end}, {"神羽恋人", "/storage/emulated/0/时之初遇/资源/神羽恋人", function() 头发(402210) 内裤(1410647) 脸部(402209) 套装过一秒(1407276) end}, {"暗烬天使", "/storage/emulated/0/时之初遇/资源/暗烬天使", function() 头发(402214) 脸部(402213) 套装过一秒(1407275) end}, {"金尊法老", "/storage/emulated/0/时之初遇/资源/金尊法老", function() 头发(1410128) 套装过一秒(1406469)----y end}, {"明日香", "/storage/emulated/0/时之初遇/资源/明日香", function() 套装过一秒(1406387) 头发(1403103) end}, {"零战斗", "/storage/emulated/0/时之初遇/资源/零战斗", function() 套装过一秒(1406386) 头发(1403102) end}, {"真理战斗", "/storage/emulated/0/时之初遇/资源/真理战斗", function() 套装过一秒(1406388) 头发(1403104) end}, {"万圣木乃伊", "/storage/emulated/0/时之初遇/资源/万圣木乃伊", function() 套装过一秒(1400687) end}, {"冥界旅行者", "/storage/emulated/0/时之初遇/资源/冥界旅行者", function() 套装过一秒(1405623) end}, {"废墟猎手", "/storage/emulated/0/时之初遇/资源/废墟猎手", function() 套装过一秒(1405163) end}, {"擎天柱", "/storage/emulated/0/时之初遇/资源/擎天柱", function() 头发(1410915) 套装过一秒(1407614) end}, {"大黄蜂", "/storage/emulated/0/时之初遇/资源/大黄蜂", function() 头发(1410916) 套装过一秒(1407615) end}, {"威震天", "/storage/emulated/0/时之初遇/资源/威震天", function() 头发(1410917) 套装过一秒(1407612) end}, {"利威尔", "/storage/emulated/0/时之初遇/资源/利威尔", function() 头发(402295) 脸部(402294) 套装过一秒(1407602) end}, {"进击的巨人", "/storage/emulated/0/时之初遇/资源/进击的巨人", function() 头发(402301) 套装过一秒(1407598) end}, {"超大型巨人", "/storage/emulated/0/时之初遇/资源/超大型巨人", function() 套装过一秒(1407601) end}, {"祖国人", "/storage/emulated/0/时之初遇/资源/祖国人", function() 头发(402116) 脸部(402114) 套装过一秒(1406439) end}, {"千面诡皇", "/storage/emulated/0/时之初遇/资源/千面诡皇", function() 头发(1410245) 套装过一秒(1406641) end}, }), }, },--二分页 {--二分页 ['分页名字']='背包', ['分页logo']='999', ['分页菜单']={ ed.buttonMenu({ {"隐藏背包", "/storage/emulated/0/时之初遇/资源/隐藏", function() 背包(0) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"战术星舱", "/storage/emulated/0/时之初遇/资源/战术星舱", function() 背包(1501003663) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"帝皇肖像", "/storage/emulated/0/时之初遇/资源/帝皇肖像", function() 背包(1501003668) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"璃光剪影", "/storage/emulated/0/时之初遇/资源/璃光剪影", function() 背包(1501003688) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"灵符雕龙", "/storage/emulated/0/时之初遇/资源/灵符雕龙", function() 背包(1501003677) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"银河之心", "/storage/emulated/0/时之初遇/资源/银河之心", function() 背包(1501003649) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"仲夜迷蝶", "/storage/emulated/0/时之初遇/资源/仲夜迷蝶", function() 背包(1501003672) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"寄生核心", "/storage/emulated/0/时之初遇/资源/寄生核心", function() 背包(1501003652) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"簪花葫芦", "/storage/emulated/0/时之初遇/资源/簪花葫芦", function() 背包(1501003629) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"蝴蝶花灵", "/storage/emulated/0/时之初遇/资源/蝴蝶花灵", function() 背包(1501003047) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"致命凝视", "/storage/emulated/0/时之初遇/资源/致命凝视", function() 背包(1501003487) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"金蛇瑰宝", "/storage/emulated/0/时之初遇/资源/金蛇瑰宝", function() 背包(1501003639) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"古城密探", "/storage/emulated/0/时之初遇/资源/古城密探", function() 背包(1501003053) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"朋克犀牛", "/storage/emulated/0/时之初遇/资源/朋克犀牛", function() 背包(1501003211) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"恐龙布朗熊", "/storage/emulated/0/时之初遇/资源/恐龙布朗熊", function() 背包(1501003261) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"莎莉", "/storage/emulated/0/时之初遇/资源/莎莉", function() 背包(1501003554) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"愚人小丑", "/storage/emulated/0/时之初遇/资源/愚人小丑", function() 背包(1501003051) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"像素恐龙", "/storage/emulated/0/时之初遇/资源/像素恐龙", function() 背包(1501003310) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, }), }, },--二分页 {--二分页 ['分页名字']='护甲', ['分页logo']='999', ['分页菜单']={ ed.buttonMenu({ {"冰霜手套", "/storage/emulated/0/时之初遇/资源/", function() 护甲(452001) end}, {"流沙手套", "/storage/emulated/0/时之初遇/资源/", function() 护甲(452003) end}, {"水墨手套", "/storage/emulated/0/时之初遇/资源/", function() 护甲(452002) end}, }), }, },--二分页 { ['分页名字']='头盔', ['分页logo']='999', ['分页菜单']={ ed.buttonMenu({ {"隐藏头盔", "/storage/emulated/0/时之初遇/资源/隐藏", function() 头盔(0) end}, {"头盔", "/storage/emulated/0/时之初遇/资源/", function() end}, }), }, },--二分页 }},--主分页 { ['分区名字']='枪械', ['分区logo']='/storage/emulated/0/时之初遇/资源/枪械', ['二级分页']={ {--二分页 ['分页名字']='步枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"M416", ed.checkbox({--三个一行 { "冰霜核心", function() 红点(1010040470) 全息(1010040469) 二倍(1010040468) 三倍(1010040467) 四倍(1010040466) 六倍(1010040481) 枪口(1010040475) 握把(1010040477) 弹夹(1010040461) 枪托(1010040463) 播报(1101004046)--播报 枪械(1101004046)--枪械 end }, { "愚人小丑", function() 红点(1010040569) 全息(1010040568) 二倍(1010040567) 三倍(1010040566) 四倍(1010040565) 六倍(1010040564) 枪口(1010040577) 握把(1010040585) 弹夹(1010040621) 枪托(1010040623) 播报(1101004062)--播报 枪械(1101004062)--枪械 end }, { "武魂宗师", function() 播报(1101004200)--播报 枪械(1101004200)--枪械 end }, { "虎啸丹青", function() 红点(1010042299) 全息(1010042298) 二倍(1010042297) 三倍(1010042296) 四倍(1010042295) 六倍(1010042294) 枪口(1010042307) 握把(1010042314) 弹夹(1010042304) 枪托(1010042363) 播报(1101004236)--播报 枪械(1101004236)--枪械 end }, { "赤霄神剑", function() 红点(1010042399) 全息(1010042398) 二倍(1010042397) 三倍(1010042396) 四倍(1010042395) 六倍(1010042394) 枪口(1010042407) 握把(1010042414) 弹夹(1010042404) 枪托(1010042463) 播报(1101004246)--播报 枪械(1101004246)--枪械 end }, }), }),--box尾 ed.box({"AK47", ed.checkbox({--三个一行 { "律动光影", function() 红点(1010012697) 全息(1010012696) 二倍(1010012695) 三倍(1010012694) 四倍(1010012693) 六倍(1010012692) 枪口(1010012699) 弹夹(1010012703) 播报(1101001276)--播报 枪械(1101001276) end }, { "星海提督", function() 播报(1101001212)--播报 枪械(1101001212) end }, { "沙影神国", function() 播报(1101001265)--播报 枪械(1101001265)--枪械 end }, { "冰霜核心", function() 播报(1101001089)--播报 枪械(1101001089)--枪械 end }, }), }),--box尾 ed.box({"SCAR-L", ed.checkbox({--三个一行 { "凤曜琼华", function() 红点(1010032206) 全息(1010032205) 二倍(1010032204) 三倍(1010032204) 四倍(1010032203) 六倍(1010032202) 枪口(1010032242) 握把(1010032249) 弹夹(1010032210) 播报(1101003227)--播报 枪械(1101003227)--枪械 end }, { "霓虹天后", function() 播报(1101003195)--播报 枪械(1101003195)--枪械 end }, { "御灵魂契", function() 播报(1101003219)--播报 枪械(1101003219)--枪械 end }, { "梦幻奇缘", function() 播报(1101003208)--播报 枪械(1101003208)--枪械 end }, }), }),--box尾 ed.box({"AUG", ed.checkbox({--三个一行 { "罪恶玫瑰", function() 红点(1010060788) 全息(1010060787) 二倍(1010060786) 三倍(1010060785) 四倍(1010060784) 六倍(1010060783) 枪口(1010060795) 握把(1010060805) 弹夹(1010060794) 播报(1101006085)--播报 枪械(1101006085)--枪械 end }, { "破军狂鸣", function() 红点(1010060696) 全息(1010060695) 二倍(1010060694) 三倍(1010060693) 四倍(1010060692) 六倍(1010060691) 枪口(1010060701) 握把(1010060709) 弹夹(1010060699) 播报(1101006074)--播报 枪械(1101006074)--枪械 end }, { "弃誓冰灵", function() 红点(1010060562) 全息(1010060561) 二倍(1010060554) 三倍(1010060553) 四倍(1010060552) 六倍(1010060551) 枪口(1010060573) 握把(1010060582) 弹夹(1010060572) 播报(1101006062)--播报 枪械(1101006062)--枪械 end }, }), }),--box尾 ed.box({"GROZA", ed.checkbox({--三个一行 { "红莲哥斯拉", function() 播报(1101005098)--播报 枪械(1101005098)--枪械 end }, { "暗夜裁决", function() 播报(1101005091)--播报 枪械(1101005091)--枪械 end }, }), }),--box尾 ed.box({"M762", ed.checkbox({--三个一行 { "铂金骸骨", function() 红点(1010081526) 全息(1010081525) 二倍(1010081524) 三倍(1010081523) 四倍(1010081522) 六倍(1010081521) 枪口(1010081532) 握把(1010081542) 弹夹(1010081529) 播报(1101008154)--播报 枪械(1101008154)--枪械 end }, { "灵阁魔剪", function() 播报(1101008157)--播报 枪械(1101008157)--枪械 end }, }), }),--box尾 ed.box({"ACE", ed.checkbox({--三个一行 { "传奇海怪号", function() 播报(1101102024)--播报 枪械(1101102024)--枪械 end }, { "清夜蝶吻", function() 播报(1101102041)--播报 枪械(1101102041)--枪械 end }, }), }),--box尾 }, },--二分页 { ['分页名字']='射手步枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"MK14", ed.checkbox({--三个一行 { "S11", function() 枪械(1103007010) end }, { "星云力量", function() 播报(1103007020) 枪械(1103007020) end }, { "憨憨萌龙", function() 播报(1103007038) 枪械(1103007038) end }, { "龙吟国度", function() 红点(1030070218) 全息(1030070217) 二倍(1030070216) 三倍(1030070215) 四倍(1030070214) 六倍(1030070213) 八倍(1030070212) 枪口(1030070234) 弹夹(1030070226) 枪托(1030070236) 播报(1103007028) 枪械(1103007028) end }, }), }),--box尾 }, },--二分页 { ['分页名字']='机枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"MG3", ed.checkbox({--三个一行 { "C7S21", function() 枪械(1105010020) 弹夹(1050100201) end }, { "苍穹之龙", function() 播报(1105010008)--播报 枪械(1105010008)--枪械 end }, { "风鸣神戟", function() 红点(1050100144) 全息(1050100143) 二倍(1050100142) 三倍(1050100141) 四倍(1050100139) 六倍(1050100138) 弹夹(1050100137) 播报(1105010019)--播报 枪械(1105010019)--枪械 end }, }), }),--box尾 ed.box({"DP28", ed.checkbox({--2个一行 { "血狱寄生", function() 枪械(1105002091) 播报(1105002091)--播报 弹夹(1050020911) end }, { "玩世狐妖", function() 弹夹(1050020961) 枪械(1105002096)--枪械 end }, }), }),--box尾 ed.box({"M249", ed.checkbox({--2个一行 { "桀骜帝皇", function() 枪械(1105001069) 播报(1105001069)--播报 弹夹(1050010691) end }, { "极辉女帝", function() 弹夹(1050010481) 播报(1105001048)--播报 枪械(1105001048)--枪械 end }, }), }),--box尾 }, },--二分页 { ['分页名字']='冲锋枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"UM45", ed.checkbox({--三个一行 { "噬魂凝视", function() 红点(1020024187) 全息(1020024186) 二倍(1020024185) 三倍(1020024184) 四倍(1020024183) 六倍(1020024182) 播报(1102002424)--播报 枪械(1102002424)--枪械 end }, { "水晶冰刺", function() 红点(1020021307) 全息(1020021306) 二倍(1020021305) 三倍(1020021304) 四倍(1020021303) 六倍(1020021302) 播报(1102002136)--播报 枪械(1102002136)--枪械 end}, }), }), ed.box({"UZI", ed.checkbox({--三个一行 { "烈焰枷锁", function() 红点(1020011243) 播报(1102001130)--播报 枪械(1102001130)--枪械 end }, { "冰晶神锤", function() 红点(1020011133) 播报(1102001120)--播报 枪械(1102001120)--枪械 end}, }), }), }, },--二分页 { ['分页名字']='狙击枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"98K", ed.checkbox({--三个一行 { "冰魄幻羽", function() 红点(1030011947) 全息(1030011946) 二倍(1030011945) 三倍(1030011944) 四倍(1030011943) 六倍(1030011942) 八倍(1030011941) 播报(1103001202)--播报 枪械(1103001202)--枪械 end }, { "紫戮电极", function() 红点(1030011737) 全息(1030011736) 二倍(1030011735) 三倍(1030011734) 四倍(1030011733) 六倍(1030011732) 八倍(1030011731) 播报(1103001179)--播报 枪械(1103001179)--枪械 end}, }), }),--box尾 ed.box({"M24", ed.checkbox({--三个一行 { "夜影晨曦", function() 红点(1030021078) 全息(1030021077) 二倍(1030021076) 三倍(1030021075) 四倍(1030021074) 六倍(1030021073) 八倍(1030021072) 枪口(1030021080) 弹夹(1030021086) 枪托(1030021083) 播报(1103002113) 枪械(1103002113) end}, }), }),--box尾 ed.box({"AWM", ed.checkbox({--三个一行 { "玲珑白蛇", function() 红点(1030030818) 全息(1030030817) 二倍(1030030816) 三倍(1030030815) 四倍(1030030814) 六倍(1030030813) 八倍(1030030812) 枪口(1030030826) 弹夹(1030030824) 枪托(1030030828) 播报(1103003087) 枪械(1103003087) end }, { "赤潮龙息", function() 红点(1030030738) 全息(1030030737) 二倍(1030030736) 三倍(1030030735) 四倍(1030030734) 六倍(1030030733) 八倍(1030030732) 枪口(1030030745) 弹夹(1030030743) 枪托(1030030747) 播报(1103003079) 枪械(1103003079) end },{ "紫夜苍穹", function() 四倍(1030030164) 六倍(1030030163) 八倍(1030030162) 枪口(1030030166) 弹夹(1030030172) 枪托(1030030168) 播报(1103003022) 枪械(1103003022) end}, }), }),--box尾 ed.box({"AMR", ed.checkbox({--三个一行 { "灵泉剑影", function() 红点(1030120258) 全息(1030120257) 二倍(1030120256) 三倍(1030120255) 四倍(1030120254) 六倍(1030120253) 八倍(1030120252) 弹夹(1030120311) 播报(1103012031) 枪械(1103012031) end }, { "烈焰圣枪", function() 红点(1030120138) 全息(1030120137) 二倍(1030120136) 三倍(1030120135) 四倍(1030120134) 六倍(1030120133) 八倍(1030120132) 弹夹(1030120138) 播报(1103012019) 枪械(1103012019) end },{ "嗜血魔魇", function() 红点(1030120038) 全息(1030120037) 二倍(1030120036) 三倍(1030120035) 四倍(1030120034) 六倍(1030120033) 八倍(1030120032) 弹夹(1030120101) 播报(1103012010) 枪械(1103012010) end}, }), }),--box尾 }, },--二分页 }},--主分页 { ['分区名字']='散装', ['分区logo']='/storage/emulated/0/时之初遇/资源/散装', ['二级分页']={ {--二分页 ['分页名字']='自改全身', ['分页logo']='9999', ['分页菜单']={ ed.box({"自改全身", ed.checkbox({--三个一行 { "自改全身", function() local cfg_file = "/storage/emulated/0/时之初遇/资源/配置/配置.h" local chunk = loadfile(cfg_file) local cfg = nil if chunk ~= nil then cfg = chunk() end if cfg == nil then cfg = { 1410480, -- 头发 0, -- 脸部 1404207, -- 衣服 1404160, -- 裤子 1404423, -- 鞋子 1402223, -- 内衣 1404198, -- 内裤 0, -- 头盔 452001, -- 护甲 0, -- 背包 false -- 永远默认:不勾选 } end cfg[11] = false QA = gg.prompt({ "头发","脸部","衣服","裤子","鞋子", "内衣","内裤","头盔","护甲","背包", "是否保存配置" }, cfg, { "text","text","text","text","text", "text","text","text","text","text", "checkbox" }) if QA ~= nil then if QA[1] ~= "" then 头发(tonumber(QA[1])) end if QA[2] ~= "" then 脸部(tonumber(QA[2])) end if QA[3] ~= "" then 衣服(tonumber(QA[3])) end if QA[4] ~= "" then 裤子(tonumber(QA[4])) end if QA[5] ~= "" then 鞋子(tonumber(QA[5])) end if QA[6] ~= "" then 内衣(tonumber(QA[6])) end if QA[7] ~= "" then 内裤(tonumber(QA[7])) end if QA[8] ~= "" then 头盔(tonumber(QA[8])) end if QA[9] ~= "" then 护甲(tonumber(QA[9])) end if QA[10] ~= "" then 背包(tonumber(QA[10])) end if QA[11] == true then local f = io.open(cfg_file, "w") if f then f:write([[ return { ]] .. QA[1] .. [[, -- 头发 ]] .. QA[2] .. [[, -- 脸部 ]] .. QA[3] .. [[, -- 衣服 ]] .. QA[4] .. [[, -- 裤子 ]] .. QA[5] .. [[, -- 鞋子 ]] .. QA[6] .. [[, -- 内衣 ]] .. QA[7] .. [[, -- 内裤 ]] .. QA[8] .. [[, -- 头盔 ]] .. QA[9] .. [[, -- 护甲 ]] .. QA[10] .. [[, -- 背包 false -- 保存配置 } ]]) f:close() gg.toast("配置已保存") end end end gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end }, { "查询代码", function() local path = "/storage/emulated/0/时之初遇/资源/配置/物品输出-2026-04-06-8-46.h" local ipt = gg.prompt({"请输入要查询的物品名称"}, {""}, {"text"}) if not ipt or ipt[1] == "" then return end local keyword = ipt[1]:lower() local f = io.open(path, "r") if not f then gg.alert("未找到文件:\n" .. path) return end local content = f:read("*a") f:close() local pattern = "%['名字'%] = \"(.-)\".-%['副代码'%] = \"(.-)\".-%['主代码'%] = \"(.-)\"" local result = {} for name, sub_code, main_code in string.gmatch(content, pattern) do if name:lower():find(keyword, 1, true) then table.insert(result, { name = name, main = main_code, sub = sub_code }) end end if #result == 0 then gg.alert("未找到包含「" .. keyword .. "」的物品") else local text = "查询结果:\n\n" for i, v in ipairs(result) do text = text .. i .. ". 物品名:" .. v.name .. "\n 主代码ID:" .. v.main .. "\n 副代码ID:" .. v.sub .. "\n\n" end gg.alert(text) end gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("查询成功") end}, }), }),--box尾 }, },--二分页 }},--主分页 } ed.menu(icon, title, menum) --结束 end function b() gg.hide(true) luajava.loadlayout=loadlayout local material3 = elgg.import("material3") context = material3:getContext() context.setTheme(0x7f090069) import "android.os.*" import "android.view.*" import "android.widget.*" import "android.graphics.PixelFormat" import "android.graphics.Color" import "android.graphics.drawable.GradientDrawable" import "android.graphics.drawable.StateListDrawable" import "com.google.android.material.materialswitch.MaterialSwitch" import "com.google.android.material.card.MaterialCardView" import "android.graphics.Color" import "android.content.res.ColorStateList" import "android.animation.LayoutTransition" import 'com.google.android.material.slider.Slider' import 'com.google.android.material.button.MaterialButton' import "com.google.android.material.textfield.TextInputEditText" import "android.animation.ObjectAnimator" import "android.animation.AnimatorSet" import "android.view.animation.DecelerateInterpolator" import "android.view.animation.RotateAnimation" import "android.view.animation.Animation" import "android.graphics.drawable.BitmapDrawable" import "android.view.animation.AccelerateInterpolator" import "android.view.animation.DecelerateInterpolator" import "android.view.animation.OvershootInterpolator" import "android.view.animation.BounceInterpolator" import "android.view.animation.LinearInterpolator" import "android.view.animation.PathInterpolator" local transition = LayoutTransition() transition.setDuration(600) import("com.romainpiel.shimmer.Shimmer") import("com.romainpiel.shimmer.ShimmerTextView") import("com.romainpiel.shimmer.ShimmerButton") import("android.graphics.Canvas") import("android.graphics.Color") import("android.graphics.Paint") import "android.graphics.BitmapFactory" import "android.renderscri.*" import "android.graphics.Bitmap" import "android.graphics.Canvas" import "android.os.Handler" import "android.os.Looper" elgg.import("toast") elgg.import("HiddenApiBypass") elgg.import("内核读写") import "android.animation.ValueAnimator" import "android.animation.ArgbEvaluator" import "android.graphics.Typeface" toast.setMode(1) function cnmBackground1() local filePath = "/storage/emulated/0/时之初遇/资源/背景" local bmp = BitmapFactory.decodeFile(filePath) if bmp then return BitmapDrawable(activity.getResources(), bmp) end end local window = activity.getSystemService("window") local ed = {} import "android.graphics.drawable.GradientDrawable" function getStrokeBackground(fillColor, strokeColor, strokeWidth, radius) local gd = GradientDrawable() gd.setColor(fillColor) gd.setCornerRadius(radius) gd.setStroke(strokeWidth, strokeColor) return gd end --gg.setVisible(false) local HotPoint = luajava.bindClass("android.ext.HotPoint") local HP = HotPoint.getMethod("d") HotPoint = HotPoint.instance HotPoint.f() local function getVerticalBG(gtvb1, gtvb3, gtvb4, gtvb5) if not gtvb4 then gtvb4 = 0 gtvb5 = 0xff000000 end local colors = luajava.new(GradientDrawable) colors.setColor(gtvb1) colors.setCornerRadius(gtvb3) colors.setGradientType(GradientDrawable.LINEAR_GRADIENT) colors.setStroke(gtvb4, gtvb5) return colors end local function dp2px(dp) local metrics = activity.getResources().getDisplayMetrics() return math.floor(dp * metrics.density + 0.5) end function applyBestBlurEffect(view, radius) -- Android 12+ 使用RenderEffect if Build.VERSION.SDK_INT >= 31 then import "android.graphics.RenderEffect" import "android.graphics.Shader" local blurEffect = RenderEffect.createBlurEffect( radius, radius, Shader.TileMode.CLAMP ) view.setRenderEffect(blurEffect) return true end -- Android 8-11 使用RenderScri if Build.VERSION.SDK_INT >= 26 then local rootView = activity.getWindow().getDecorView().getRootView() local blurredBg = applyFullResBlur(rootView, radius) view.setBackgroundDrawable(BitmapDrawable(activity.getResources(), blurredBg)) return true end -- 旧版本使用简单模糊 local drawable = GradientDrawable() drawable.setColor(0x80000000) -- 半透明黑色 drawable.setCornerRadius(35) view.setBackgroundDrawable(drawable) return false end function miaobian(d, r, t, y) local drawable = GradientDrawable() drawable.setShape(GradientDrawable.RECTANGLE) drawable.setColor(t) -- 直接传入 0xAARRGGBB 格式的颜色值 drawable.setCornerRadii({r, r, r, r, r, r, r, r}) drawable.setStroke(d, y) -- 直接传入 0xAARRGGBB 格式的颜色值 return drawable end function zoom_animation(view) if dObjectAnimator == nil then dObjectAnimator = ObjectAnimator.ofFloat(view, "scaleX", 0, 1) dObjectAnimator.setDuration(600) dObjectAnimator.setInterpolator(DecelerateInterpolator()) end dObjectAnimator.start() end function getShepeBackground(color, radiu) local drawable = luajava.new(GradientDrawable) drawable.setShape(GradientDrawable.RECTANGLE) drawable.setColor(color) drawable.setCornerRadii({radiu, radiu, radiu, radiu, radiu, radiu, radiu, radiu}) return drawable end local function getButtonBG() local selector = StateListDrawable() local state = android.R.attr.state_pressed selector.addState({state}, getVerticalBG("0xffCCCCCC", 15)) selector.addState({-state}, getVerticalBG("0xffCCCCCC", 15)) return selector end local function getLayoutParams() LayoutParams = WindowManager.LayoutParams local layoutParams = luajava.new(LayoutParams) if (Build.VERSION.SDK_INT >= 26) then layoutParams.type = LayoutParams.TYPE_APPLICATION_OVERLAY else layoutParams.type = LayoutParams.TYPE_PHONE end layoutParams.format = PixelFormat.RGBA_8888 layoutParams.flags = LayoutParams.FLAG_NOT_FOCUSABLE | LayoutParams.FLAG_ALT_FOCUSABLE_IM layoutParams.gravity=Gravity.TOP|Gravity.LEFT layoutParams.width = LayoutParams.WRAP_CONTENT layoutParams.height = LayoutParams.WRAP_CONTENT return layoutParams end -- 新开一个线程来执情功能 local function threadStart(runnable) local newRun = luajava.createProxy("java.lang.Runnable", runnable) local subThread = luajava.newInstance("java.lang.Thread", newRun) subThread:start() end function 新线程(runnable) local Thread = luajava.bindClass("java.lang.Thread") local Runnable = luajava.bindClass("java.lang.Runnable") local myRunnable = luajava.createProxy("java.lang.Runnable", { run = runnable[1] }) local thread = luajava.new(Thread, myRunnable) return thread end local change_menu local background_list = { getShepeBackground("0xffE7EDED", 15), } local function log(text, color, size) -- 这是控制台输出的 local tmp = loadlayout { TextView, text = os.date("%m-%d %H:%M:%S ") .. text, textSize = size or '10sp', textColor = color, gravity = "left", layout_width = "wrap_content", } console_list.addView(tmp) console.fullScroll(View.FOCUS_DOWN) end -- 切换菜单 local change_menu local background_list = { getShepeBackground(0x00F4FAFB, 15), getShepeBackground(0x00F4FAFB, 15) } function ed.radio(cklist) if type(cklist) ~= "table" or #cklist == 0 then return loadlayout({ LinearLayout, layout_width = "match_parent", layout_height = "wrap_content", { TextView, text = "未提供选项", textColor = 0xFF757575, textSize = "13sp", layout_margin = "8dp" } }) end local radioG = { RadioGroup, gravity = "top", layout_height = "wrap_content", layout_margin = "4dp", layout_width = "match_parent", orientation = "vertical", } for i = 1, #cklist do local label = cklist[i][1] or ("选项 " .. tostring(i)) local callback = cklist[i][2] local rb = { RadioButton, gravity = "center_vertical", layout_height = "wrap_content", layout_marginLeft = "2dp", layout_marginRight = "2dp", layout_width = "match_parent", text = label, textSize = "13sp", textColor = 0xFF222222, onClick = function(view) if type(callback) == "function" then threadStart({run=function() pcall(callback, view) end}) end end } if font then rb.Typeface = font end radioG[#radioG + 1] = rb end return loadlayout(radioG) end -- 开关 ed.switch = function(name, func1, func2) local sw sw = loadlayout({ MaterialSwitch; text = " "..name; textColor = "#000000"; -- 黑色字体 padding = "5dp"; layout_width = "match"; layout_height = "match"; trackTintList=(ColorStateList({{android.R.attr.state_checked},{}},{0xFF000000,0x28FFFFFF})), thumbTintList=(ColorStateList({{android.R.attr.state_checked},{-android.R.attr.state_checked}},{0xFFFFFFFF,0xFF4B484F})), onClick = function() local func = sw.checked and func1 or func2 threadStart({ run = function() pcall(func) end }) end }) -- 关键修改:用圆角Shape背景 getShepeBackground(白色,15圆角),和box统一 local tmp = loadlayout({ LinearLayout, -- 替换纯色背景为圆角shape背景,圆角15,和ed.box一致 background = getShepeBackground(0xFFFFFFFF, 15), elevation="2dp", layout_width = 'fill_parent', layout_height = "40dp", layout_margin = "2dp", -- 和box边距对齐 gravity = "center_vertical", padding = { "0dp", "0dp", "6dp", "0dp" }, }) local rest = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = "wrap_content", gravity = "center_vertical", }) tmp.addView(sw) rest.addView(tmp) return rest end function showInput(id) local view = luajava.getIdView(id) if view then gg.alert(tostring(view:getText():toString())) else gg.alert("没有找到ID: " .. id) end end ed.button = function(name, func) local buttonLayout = { LinearLayout, layout_width = 'fill_parent', layout_height = "wrap_content", layout_margin = "2dp", elevation="2dp", { MaterialCardView, radius = 15, layout_width = 'fill_parent', layout_height = "wrap_content", strokeWidth = 0, clickable = true, focusable = true, checkable = true, onClick = function() if func then threadStart({ run = function() pcall(func) end }) end end, -- 关键修改:替换纯色背景为统一圆角Shape背景 background = getShepeBackground(0xFFFFFFFF, 15), { LinearLayout, layout_width = 'fill_parent', layout_height = "wrap_content", orientation = "horizontal", gravity = "center_vertical", padding = "10dp", { TextView, text = name, textColor = "#000000", -- 黑色文字 textSize = "14sp", layout_weight = 1, layout_marginLeft = "5dp", }, } } } return loadlayout(buttonLayout) end ed.Image = function(name, size) local ImageLayout = { MaterialCardView, -- setCardBackgroundColor = 0xFFEDE5D8, -- 注意这里应该是数字而不是字符串 layout_width = "match_parent", layout_height = size or "100dp", radius = 15, strokeWidth = 0, elevation="2dp", clickable = true, focusable = true, checkable = true, { ImageView, layout_width = "match_parent", layout_height = "match_parent", src = name, scaleType = "centerCrop" -- 关键属性,使图片居中裁剪填充 } } return loadlayout(ImageLayout) end nothing=function() end ed.seek = function(name,bian,smin,smax,nows,steps,lev,func) local sw func=func or nothing lev=lev or '倍' _ENV[bian] =nows or 1 local smin=tonumber(smin) local smax=tonumber(smax) steps=steps or 1 if not name then name = "未设置" end sw = loadlayout({ Slider, thumbHeight='23dp', trackHeight='15dp', trackStopIndicatorSize='0dp', tickVisible=false, __onFinish=function(v) if func then v.addOnSliderTouchListener({ onStopTrackingTouch=function(v) callAsyncTask(function() func(v.getValue()) end) end }) end v.setTrackActiveTintList(ColorStateList({{},},{0xff000000})) v.setTrackInactiveTintList(ColorStateList({{},},{0x55000000})) v.setThumbTintList(ColorStateList({{},},{0xff000000})) v.addOnChangeListener(function(SeekBar, var2, var3) _ENV[bian] = steps>=1 and string.format('%d',var2) or string.format('%.1f',var2) luajava.getIdView(names).setText(name..':'.._ENV[bian]..lev) end) end, layout_width = 'match_parent', id=luajava.newId(name.."seekbar"), layout_weight=1, valueFrom=smin, valueTo=smax, value=nows, stepSize=steps, }) local tmp = loadlayout({ LinearLayout, background = miaobian(0, 15, "0x33FFFFFF", "0x33FFFFFF"), -- 液态玻璃风格背景 layout_width = 'fill_parent', layout_height = "40dp", layout_marginLeft = '2dp', layout_marginRight = '2dp', layout_marginTop = '2dp', layout_marginBottom = '2dp', gravity = "center_vertical", padding = {"0dp", "0dp", "6dp", "0dp"}, { TextView, padding = {"5dp","10dp","0dp","10dp"}, gravity = "top", textColor = 0xFF000000, textSize = '13sp', text = name, layout_width = 'wrap_content', layout_marginLeft = "5dp", } }) local rest = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = "wrap_content", gravity = "center_vertical", }) tmp.addView(sw) rest.addView(tmp) return rest end ed.input = function(name,id) local tmp = { LinearLayout, layout_width = 'match_parent', layout_height = 'wrap_content', { TextView, text = name or "未设置文字", textSize = "16sp", textColor ="#444444", gravity = "center", layout_width = "match_parent", layout_weight = 2, }, { TextInputEditText, layout_weight = 1, hint = "请输入代码", hintTextColor = "#444444", layout_width = "match_parent", layout_height = "wrap", layout_margin = "2dp", focusable = true, focusableInTouchMode = true, cursorVisible = true, id = luajava.newId(id), } } return loadlayout(tmp) end -- 文字 ed.text = function(txt, color, size) local tmp = { TextView, text = txt or "未设置文字", textSize = size or "18sp", textColor = color or "#545454", layout_width = "wrap_content", } return loadlayout(tmp) end ed.kong = function(changdu) local tmp = { LinearLayout, layout_width = 'fill_parent', layout_height = changdu, } return loadlayout(tmp) end ed.buttonMenu = function(views) if #views == 0 then return end local mainLayout = loadlayout({ LinearLayout, layout_width = 'match_parent', layout_height = 'wrap_content', orientation = 'vertical' }) local buttonsPerRow = 3 local currentRow = nil local count = 0 local total = #views for i, v in ipairs(views) do if count % buttonsPerRow == 0 then currentRow = loadlayout({ LinearLayout, layout_width = 'match_parent', layout_height = 'wrap_content', orientation = 'horizontal', weightSum = buttonsPerRow -- 给每行锁死3份权重,根治拉伸 }) mainLayout.addView(currentRow) end local item = loadlayout({ LinearLayout, layout_width = "0dp", layout_height = "36dp", layout_weight = "1", -- 每个按钮固定占1份,永远等宽 layout_margin = "2dp", orientation = "horizontal", gravity = "center_vertical", paddingLeft = "4dp", paddingRight = "4dp", background = getStrokeBackground( 0xFFFFFFFF, 0xFFD7CCC8, 2, 12 ), onClick = function() if v[3] then threadStart({ run = function() pcall(v[3]) end, }) end end, onTouch = function(view, event) import "android.view.MotionEvent" if event.getAction() == MotionEvent.ACTION_DOWN then view.setScaleX(0.95) view.setScaleY(0.95) view.setAlpha(0.7) elseif event.getAction() == MotionEvent.ACTION_UP or event.getAction() == MotionEvent.ACTION_CANCEL then view.setScaleX(1) view.setScaleY(1) view.setAlpha(1) end return false end, { ImageView, layout_width = "26dp", layout_height = "26dp", layout_marginRight = "4dp", scaleType = "fitCenter", adjustViewBounds = true, src = v[2] }, { TextView, layout_width = "0dp", layout_weight = "1", layout_height = "wrap_content", text = v[1], textSize = "11sp", textColor = "0xFF000000", gravity = "right|center_vertical", maxLines = "1", ellipsize = "none", includeFontPadding = false, padding = "0dp" } }) currentRow.addView(item) count = count + 1 end -- 【核心修复】给最后一行补2个透明占位,锁死3列等宽,不报错、不破坏布局 local lastRow = mainLayout.getChildAt(mainLayout.getChildCount() - 1) if lastRow then local lastCount = lastRow.getChildCount() if lastCount < buttonsPerRow then import "android.graphics.drawable.ColorDrawable" for i = 1, buttonsPerRow - lastCount do local empty = loadlayout({ LinearLayout, layout_width = "0dp", layout_height = "36dp", layout_weight = "1", layout_margin = "2dp", background = ColorDrawable(0x00000000) -- 用API创建透明背景,彻底解决类型报错 }) lastRow.addView(empty) end end end return mainLayout end ed.checkbox = function(views) if #views == 0 then return end -- 1. 主布局:直接砍掉所有内边距,彻底消除上下空白 local mainLayout = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = 'wrap_content', orientation = 'vertical', padding = '0dp', -- 整体内边距清零,不浪费1px高度 paddingBottom = '0dp' -- 底部空白直接砍没 }) local scrollView = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = 'wrap_content', orientation = 'vertical', id = 'rows_container' }) mainLayout.addView(scrollView) local buttonsPerRow = 2 -- 保留你改好的一行2个 local currentRow = nil local buttonsInCurrentRow = 0 for i, v in ipairs(views) do if buttonsInCurrentRow % buttonsPerRow == 0 then currentRow = loadlayout({ LinearLayout, layout_width = 'fill_parent', layout_height = 'wrap_content', layout_weight = 1, orientation = 'horizontal', gravity = 'center_vertical', -- 2. 行内垂直居中,避免文字错位 layout_marginBottom = '1dp' -- 3. 行间距从4dp缩到1dp,几乎无缝 }) rows_container.addView(currentRow) end local sw = loadlayout({ CheckBox, layout_width = 'wrap_content', layout_height = '22dp', -- 保留你调好的22dp高度,不动! gravity = 'center_vertical', -- 文字垂直居中,不被切 buttonTintList=ColorStateList({{android.R.attr.state_checked},{-android.R.attr.state_checked}},{0xFf000000,0xff000000}), text = v[1], textColor = "#000000", onClick = function(view) local isChecked = view.isChecked() -- 和buttonMenu一样:用threadStart开线程执行,不卡UI+保留效果 threadStart({ run = function() if isChecked and v[2] then pcall(v[2]) elseif not isChecked and v[3] then pcall(v[3]) end end }) end }) local buju = loadlayout({ LinearLayout, layout_width = 'wrap_content', layout_height = '24dp', -- 和CheckBox高度完全同步,消除父容器空白 layout_weight = 1, gravity = 'center_vertical', layout_marginLeft = '4dp', layout_right = '4dp', sw }) currentRow.addView(buju) buttonsInCurrentRow = buttonsInCurrentRow + 1 end return mainLayout end layoutTransition=LayoutTransition() function visi (tid , ttid) local tview = luajava.getIdView (tid) local ttview = luajava.getIdView (ttid) if not tview then return 0 end if tonumber (tostring (tview : getVisibility ())) == 8.0 then tview.setVisibility (View.VISIBLE) else tview.setVisibility (View.GONE) end end -- 初始化 colorvs 变量 local colorvs = {} boxes={} boxpic={} function visi(tid, ttid) local tview = luajava.getIdView(tid) local arrowView = luajava.getIdView(tid.."_arrow") -- 获取箭头图标视图 if not tview then return 0 end if tonumber(tostring(tview:getVisibility())) == 8.0 then tview.setVisibility(View.VISIBLE) -- 展开时旋转箭头向下90度 local anim = ObjectAnimator.ofFloat(arrowView, "rotation", 0, 180) anim.setDuration(300) anim.start() else tview.setVisibility(View.GONE) -- 收缩时旋转箭头回到0度 local anim = ObjectAnimator.ofFloat(arrowView, "rotation", 180, 0) anim.setDuration(300) anim.start() end end function ed.box(views) local tid = "box"..string.randomUUID(true) colorvs[#colorvs+1] = {"box",tid} local arrowIcon = { ImageView, id = luajava.newId(tid.."_arrow"), layout_width="wrap_content", layout_height="wrap_content", src = "/storage/emulated/0/", ColorFilter = 0xFF000000 } local tid = tid.."6" -- 改:layout_margin = "2dp" 和上方统一 local firadio = { LinearLayout, layout_width='fill_parent', background = getShepeBackground(0xFFFFFFFF, 15), elevation="2dp", layout_height="wrap_content", layout_margin="2dp", -- 和switch/button边距一致 orientation="vertical", LayoutTransition = LayoutTransition() } if type(views[1]) == "string" or type(views[1]) == "number" then firadio[#firadio + 1] = { LinearLayout, layout_width='fill_parent', layout_height="40dp", -- 改成40dp,和switch头部高度一致 gravity="center_vertical", padding = {"0dp", "0dp", "6dp", "0dp"}, -- 内边距也对齐switch onClick = function() visi(tid,tid) end, { LinearLayout, layout_width='fill_parent', layout_height="40dp", layout_marginRight="2dp", -- 边距统一2dp layout_marginLeft="2dp", gravity="center_vertical", background = getShepeBackground(0xFFFFFFFF, 15), { TextView, gravity="center_vertical", text=views[1], textColor=0xFF000000, textSize="15sp", layout_weight=1, layout_marginLeft="15dp", layout_marginRight="20dp", layout_width='fill_parent', }, { LinearLayout, padding={"0dp","0dp","15dp","0dp"}, layout_width="30dp", layout_height="30dp", gravity="center", arrowIcon } } } else gg.alert("ed.M3box 的 table 内第一个元素必须是 string") os.exit() end local contentLayout = { LinearLayout, layout_marginLeft="10dp", layout_marginRight="10dp", layout_marginBottom="10dp", orientation="vertical", visibility="gone", id=luajava.newId(tid), layout_width='fill_parent', layout_height="wrap_content" } for i=2,#views do table.insert(contentLayout, views[i]) end local finalLayout = loadlayout(firadio) local contentView = loadlayout(contentLayout) finalLayout.addView(contentView) boxes[tid] = contentView return finalLayout end function getBG(colors, radiu, bk1, bk2) local GradientDrawable = luajava.bindClass("android.graphics.drawable.GradientDrawable") local drawable = GradientDrawable.new() drawable.setGradientType(GradientDrawable.LINEAR_GRADIENT) if type(colors) == "table" then drawable.setColors(luajava.toArray(colors, 'int')) else drawable.setColors(luajava.toArray({ colors, colors }, 'int')) end if type(radiu) == 'table' then drawable.setCornerRadii({ radiu[1], radiu[1], radiu[2], radiu[2], radiu[3], radiu[3], radiu[4], radiu[4] }) else drawable.setCornerRadii({ radiu, radiu, radiu, radiu, radiu, radiu, radiu, radiu }) end if bk1 ~= nil and bk2 ~= nil then drawable.setStroke(bk1, bk2) end return drawable end hanshu = function(v, event) --悬浮球移动事件 local Action = event.getAction() if Action == MotionEvent.ACTION_DOWN then window.updateViewLayout(windows, mainLayoutParams) isMove = false -- 点击时的XY坐标 RawX = event.getRawX() -- 获取X坐标 RawY = event.getRawY() -- 获取Y坐标 x = mainLayoutParams.x -- 申明变量xmX为原X坐标 y = mainLayoutParams.y -- 申明变量xmY为原Y坐标 elseif Action == MotionEvent.ACTION_MOVE then isMove = true -- 移动时的XY坐标 mainLayoutParams.x = tonumber(x) + (event.getRawX() - RawX) mainLayoutParams.y = tonumber(y) + (event.getRawY() - RawY) window.updateViewLayout(windows, mainLayoutParams) end end Userpanel=luajava.loadlayout({ LinearLayout, layout_width = "match", background = getShepeBackground(0xffffffff, 45), { CardView, background = getShepeBackground(0xffffffff, 45), layout_width = "180dp", layout_margin = "1dp", layout_height = "120dp", {RelativeLayout, layout_width = "match", layout_height = "match", -- 设置轮播图高度 { LinearLayout, orientation="vertical", layout_width = "match", layout_height = "match", -- 设置轮播图高度 background = cnmBackground1(), {RelativeLayout, layout_width = "match", layout_height = "match", { CircleImageView, src = "/storage/emulated/0/",--背景左侧 layout_margin = "10dp", layout_alignParentBottom = "true", layout_alignParentLeft = "true", elevation = '8dp', layout_height = "35dp", layout_width = "35dp", }, { ShimmerTextView, layout_width = "match", layout_height = "30dp", gravity = "center", elevation = '8dp', text = "时之初遇", layout_marginBottom = "20dp", layout_alignParentBottom = "true", reflectionColor = 0xffCDCDCD, textColor = 0xFF000000, -- 选用浅紫色 textSize = "12sp", __onFinish = function(v) -- 1. 新增:创建 Shimmer 实例(关键修复) local shimmer = Shimmer.newInstance() -- 2. 保留原文字发光配置 local paint = v.getPaint() local glowRadius = 15 -- 发光半径(可调整) local glowColor = v.getCurrentTextColor() -- 发光色与文字色一致 paint.setShadowLayer(glowRadius, 0, 0, glowColor) v.invalidate() -- 刷新视图生效发光 -- 3. 调用 start 启动闪烁动画(原代码保留,已补全实例) shimmer.start(v) -- 4. 保留原内存优化代码(不变) if v.getViewTreeObserver() ~= nil then v.getViewTreeObserver().addOnGlobalLayoutListener(luajava.createProxy("android.view.ViewTreeObserver$OnGlobalLayoutListener", { onGlobalLayout = function() if v.getParent() == nil then paint.setShadowLayer(0, 0, 0, 0) -- 清除发光 v.invalidate() v.getViewTreeObserver().removeOnGlobalLayoutListener(self) end end })) end end, }, { TextView, layout_width = "60dp", layout_height = "30dp", gravity = "center", elevation = '8dp', ellipsize="marquee", selected=true, singleLine=true, layout_marginLeft = "60dp", text = "@DCCBNB666", layout_alignParentBottom = "true", textColor = 0xFF000000, textSize = "10sp", }, } }, }, }, { LinearLayout, orientation="vertical", layout_width = "match", layout_height = "match", { LinearLayout, layout_weight = 1, layout_width = "match", layout_height = "match", { TextView, layout_width = "match", layout_height = "match", elevation = '8dp', gravity = "center", text = "到期时间:", layout_weight = 1, textColor = 0xFF000000, textSize = "10sp", }, { TextView, layout_width = "match", gravity = "center", layout_height = "match", elevation = '8dp', text =vip_text, ellipsize="marquee", selected=true, singleLine=true, layout_weight = 1, textColor = 0xff010101, textSize = "10sp", } }, { LinearLayout, layout_weight = 1, layout_width = "match", layout_height = "match", { TextView, layout_width = "match", layout_height = "match", elevation = '8dp', gravity = "center", text = "登录时间:", layout_weight = 1, textColor = 0xFF000000, textSize = "10sp", }, { TextView, layout_width = "match", gravity = "center", layout_height = "match", elevation = '8dp', text = "未知启动时间", layout_weight = 1, id = "timeText", textColor = 0xff010101, textSize = "9sp", } }, { LinearLayout, layout_weight = 1, layout_width = "match", layout_height = "match", { TextView, layout_width = "match", layout_height = "match", elevation = '8dp', gravity = "center", text = "启动时长:", layout_weight = 1, textColor = 0xFF000000, textSize = "10sp", }, { TextView, layout_width = "match", gravity = "center", layout_height = "match", elevation = '8dp', id = "timerText", text = "0s", layout_weight = 1, textColor = 0xff010101, textSize = "10sp", } }, { LinearLayout, layout_weight = 1, layout_width = "match", layout_height = "match", { TextView, layout_width = "match", layout_height = "match", elevation = '8dp', gravity = "center", id = 'window_exit', text = "退出登录", layout_weight = 1, textColor = 0xFF000000, textSize = "10sp", },}}}) ed.menu = function(icon, title, menu) PageNum = {} local menu_list = { LinearLayout, layout_height = "wrap", gravity = "center", layout_width = "match_parent", orientation = "vertical", id = "menu_list", } local sidebarMenu = { HorizontalScrollView, background = getShepeBackground(0xffffffff, 15), layout_height = "40dp", layout_width = "match_parent", elevation = "3dp", layout_margin = "5dp", menu_list } local menu_lit = { LinearLayout, layout_height = "wrap", gravity = "center", layout_width = "match_parent", orientation = "vertical", id = "menu_lit", } local menu_layout = {} local icon_list = {} SecondPage = {} NowPage = 1 MainMenus = { CardView, background = getShepeBackground(0x00ffffff, 35), layout_margin = "5dp", layout_width = "match_parent", layout_height = "wrap_content", { LinearLayout, layout_height = "wrap_content", id = "main", layout_width = "match_parent", orientation = "vertical", } } SecondBG = {} FirstBG = {} TitleName = {} for i, v in ipairs(menu) do TitleName[i] = {} FirstBG[i] = "0xff007BFF" SecondBG[i] = {} PageNum[i] = #v['二级分页'] local SecondPageV = { LinearLayout, -- visibility = i == 1 and 'visible' or 'gone', layout_height = "wrap", gravity = "center", layout_width = "match_parent", id = luajava.newId('SecondPageV' .. i), } for j = 1, #v['二级分页'] do TitleName[i][j] = v['二级分页'][j]['分页名字'] SecondBG[i][j] = miaobian(3, 15, "0xAAEDEDED", "0xffEDEDED") local item = { LinearLayout, layout_width = "wrap", layout_margin = "2dp", layout_height = "match_parent", id = luajava.newId('Second' .. i .. 'P' .. j), background = SecondBG[i][j], gravity = "center", onClick = function() change_area(j) end, { ImageView, layout_width = "30dp", layout_height = "30dp", layout_margin = "3dp", src = v['二级分页'][j]['分页logo'] or icon }, { LinearLayout, layout_width = "wrap", layout_height = "match_parent", layout_margin = "5dp", orientation = "vertical", { TextView, text = v['二级分页'][j]['分页名字'], textColor = "0xff010101", textSize = "12sp", layout_width = "wrap", layout_height = "wrap", }, { TextView, text = v['二级分页'][j]['分页描述'] or " ",--分页描述 textColor = "0xff515151", textSize = "8sp", layout_width = "wrap", layout_height = "wrap", }, } } table.insert(SecondPageV, item) local funclayout = { LinearLayout, layout_width = "match_parent", id = 'layout_func' .. i .. 'p' .. j, gravity = "center_horizontal", orientation = "vertical", } for _, k in ipairs(v['二级分页'][j]['分页菜单']) do table.insert(funclayout, k) end table.insert(MainMenus, { LinearLayout, id = luajava.newId('Menu' .. i .. 'P' .. j), layout_height = "wrap_content", layout_width = "match_parent", orientation = "vertical", { ScrollView, fillViewport = "true", layout_width = "match_parent", layout_height = "wrap_content", funclayout }, }) end table.insert(menu_list, SecondPageV) local items = loadlayout { LinearLayout, layout_width = "match_parent", layout_height = "wrap_content", layout_margin = "2dp", orientation = "vertical", gravity = "center", onClick = function() change_menu(i) end, -- 图片(控制大小 + 不裁剪) { ImageView, layout_width = "45dp", -- ⭐ 控制大小 layout_height = "45dp", -- ⭐ 1:1 正方形 adjustViewBounds = true, scaleType = "fitCenter", -- ⭐ 不裁剪,完整显示 src = v['分区logo'] or icon }, -- 文字 { TextView, text = v['分区名字'], id = luajava.newId('FirstBG' .. i), textSize = "11sp", layout_width = "wrap_content", layout_height = "wrap_content", textColor = FirstBG[i], gravity = "center", layout_marginTop = "3dp" }, } table.insert(menu_lit, items) -- 给右侧菜单加功能 end -- 首先定义根视图 local layout = { FrameLayout, id = "windows", onClick=function(v) end, onTouch = hanshu, { -- 占位视图(用于保持动画过程中的尺寸) LinearLayout, id = "placeholder", layout_width = 宽度, layout_height = 高度, visibility = "gone", }, { FrameLayout, layout_height = "match_parent", layout_width = "match_parent", onClick = function()end, onTouch = hanshu, __onFinish=function(v) local layoutTransition = LayoutTransition() layoutTransition.setDuration(600) layoutTransition.setInterpolator(layoutTransition.CHANGE_APPEARING, AccelerateInterpolator()) v.setLayoutTransition(layoutTransition) end, { CardView, background = getShepeBackground(0xfff5f5f5, 15), visibility = "gone", id = 'window_flor', { RelativeLayout, layout_height = 高度, layout_width = 宽度, { LinearLayout, layout_height = 高度, layout_width = 宽度, { -- 功能部分 LinearLayout, layout_height = "match_parent", layout_width = "100dp", orientation = "vertical", gravity = "center", { LinearLayout, layout_height = "match_parent", layout_width = "match_parent", { LinearLayout, layout_height = "match_parent", layout_width = "match_parent", orientation = "vertical", --background = getBG(0x33ffffff, {15,0,0,15}), gravity = "center", layout_weight = "1", { CardView; layout_width = "50dp"; layout_height = "50dp"; layout_marginTop = "5dp"; layout_margin = "5dp"; radius = "25dp"; -- 圆角半径一半即为圆形 cardElevation = "6dp"; cardBackgroundColor = "0xFFD7CCC8"; -- 背景白色或透明都情 layout_gravity = "center"; { ImageView; layout_width = "match_parent"; layout_height = "match_parent"; clickable = true; focusable = true; id = luajava.newId("yddd"); onClick = function() lessenwindow() end; onTouch = hanshu; src = 头像; scaleType = "fitCenter"; }; }; { ShimmerTextView, layout_width = "match", layout_height = "30dp", gravity = "center", text = 左上角ID, reflectionColor = 0xfffffff, textColor = 0xFF000000, -- 选用浅紫色 textSize = "16sp", __onFinish = function(v) -- 1. 新增:创建 Shimmer 实例(关键修复) local shimmer = Shimmer.newInstance() -- 2. 保留原文字发光配置 local paint = v.getPaint() local glowRadius = 15 -- 发光半径(可调整) local glowColor = v.getCurrentTextColor() -- 发光色与文字色一致 paint.setShadowLayer(glowRadius, 0, 0, glowColor) v.invalidate() -- 刷新视图生效发光 -- 3. 调用 start 启动闪烁动画(原代码保留,已补全实例) shimmer.start(v) -- 4. 保留原内存优化代码(不变) if v.getViewTreeObserver() ~= nil then v.getViewTreeObserver().addOnGlobalLayoutListener(luajava.createProxy("android.view.ViewTreeObserver$OnGlobalLayoutListener", { onGlobalLayout = function() if v.getParent() == nil then paint.setShadowLayer(0, 0, 0, 0) -- 清除发光 v.invalidate() v.getViewTreeObserver().removeOnGlobalLayoutListener(self) end end })) end end, }, { -- 侧边栏 菜单按钮 ScrollView, layout_height = "match_parent", layout_width = "match_parent", -- layout_marginBottom = "45dp", menu_lit }, }, }, }, { LinearLayout, layout_height = "match_parent", layout_width = "match_parent", orientation = "vertical", -- ⭐ 顶部留白栏 { LinearLayout, layout_width = "match_parent", layout_height = "45dp", gravity = "center_vertical", padding = "8dp", -- 左边文字 { TextView, layout_width = "0dp", layout_height = "wrap_content", layout_weight = "1", text = 版本名称, textSize = "16sp", textColor = "0xff333333" }, -- 缩小按钮 { ImageView, layout_width = "30dp", layout_height = "30dp", layout_marginRight = "10dp", src = "/storage/emulated/0/时之初遇/资源/缩小", onClick = function() lessenwindow() end } }, -- ⭐ 中间功能区 { LinearLayout, layout_width = "match_parent", layout_height = "0dp", layout_weight = "1", orientation = "vertical", MainMenus }, -- ⭐ 二级分页移动到底部 sidebarMenu }, }, {--公告栏 LinearLayout, orientation="vertical", id = luajava.newId('例子4'), background = getShepeBackground(0xAACCCCCC, 15), layout_width = "match_parent", layout_height = "match_parent", {CardView, background = getShepeBackground(0xffFAFAFA, 45), layout_width = "match_parent", layout_margin = "30dp", layout_height = "match_parent", {CardView, layout_height = "25dp", layout_width = "65dp", onClick = function(v) -- CATransition('例子4','yddd', 1000, BounceInterpolator(),function() CATransition('例子4','例子3', 600, OvershootInterpolator(), function()end, function()end,nil,nil,nil,true) end, layout_margin = "2dp", -- 左侧外边距 5dp background = getShepeBackground(0x00eeeeee, 25), {LinearLayout, layout_height = "30dp", layout_width = "match", {CardView; elevation = "3dp"; layout_height = "14dp", layout_width = "14dp", background = getShepeBackground(0xffFE645C, 360), layout_margin = "4dp", };{CardView; elevation = "3dp"; layout_height = "14dp", layout_width = "14dp", background = getShepeBackground(0xffFFBB38, 360), layout_margin = "4dp", };{ CardView; elevation = "3dp"; layout_height = "14dp", layout_width = "14dp", background = getShepeBackground(0xff2FC849, 360), layout_margin = "4dp", }; }, },--红绿灯 {LinearLayout, layout_height = "match", layout_width = "match", layout_marginTop = "23dp", ed.text("如果美化的时候出现空白人请切换方案\n判断播报如果判断自身出现封禁,请使用判断手持\n开启枪械切完配件后,等他响第二声才能再去美化其他枪械"), --这里写公告页 }, },--空白 },--公告栏 { RelativeLayout; layout_width = "match_parent"; layout_height = "match_parent"; id = "snowContainer"; elevation="6dp"; background = "#00000000"; }, }, }, { LinearLayout, layout_height = "45dp", layout_width = "45dp", elevation = "5dp", id = "controlWindow", onClick = function()end, onTouch = hanshu, { CircleImageView, src = 头像, onTouch = hanshu, onClick = function() lessenwindow() end, layout_height = "45dp", layout_width = "45dp", }}, }, ViewFakeTransition, }; local window_layout = loadlayout(layout) windows.setBackground(background_list[1]) -- 设置背景 NowPage = 1 mainLayoutParams = getLayoutParams() change_menu = function(j) NowPage = j for i = 1, #PageNum do luajava.getIdView('SecondPageV' .. i).setVisibility(View.GONE) luajava.getIdView('FirstBG' .. i).setTextColor(0xff333333) end luajava.getIdView('FirstBG' .. NowPage).setTextColor(FirstBG[NowPage]) luajava.getIdView('SecondPageV' .. j).setVisibility(View.VISIBLE) if not SecondPage[j] then change_area(1) else change_area(SecondPage[j]) end end function change_area(x) SecondPage[NowPage] = x for i = 1, #PageNum do for j = 1, PageNum[i] do luajava.getIdView('Menu' .. i .. 'P' .. j).setVisibility(View.GONE) luajava.getIdView('Second' .. i .. 'P' .. j).setBackground(nil) luajava.getIdView('Menu' .. i .. 'P' .. j).setVisibility(View.GONE) end end luajava.getIdView('Second' .. NowPage .. 'P' .. x).setBackground(SecondBG[NowPage][x]) luajava.getIdView('Menu' .. NowPage .. 'P' .. x).setVisibility(View.VISIBLE) end window_exit.onClick = function() HP.invoke(HotPoint, nil) stoimer() window.removeView(window_layout, mainLayoutParams) Looper.myLooper().quitSafely() end function lessenwindow() local isMenuVisible = window_flor.getVisibility() ~= View.VISIBLE if isMenuVisible then placeholder.setVisibility(View.VISIBLE) mainLayoutParams.flags = LayoutParams.FLAG_NOT_TOUCH_MODAL --window.updateViewLayout(windows, mainLayoutParams) controlWindow.setVisibility(View.GONE) window_flor.setVisibility(View.VISIBLE) Handler().postDelayed(function() placeholder.setVisibility(View.GONE) window.updateViewLayout(windows, mainLayoutParams) end, 650) else -- 立即显示菜单 mainLayoutParams.flags = LayoutParams.FLAG_NOT_FOCUSABLE --window.updateViewLayout(windows, mainLayoutParams) -- 先显示controlWindow,延迟隐藏menu placeholder.setVisibility(View.VISIBLE) controlWindow.setVisibility(View.VISIBLE) window_flor.setVisibility(View.GONE) Handler().postDelayed(function() placeholder.setVisibility(View.GONE) window.updateViewLayout(windows, mainLayoutParams) end, 650) end end Handler(Looper.getMainLooper()) Looper.prepare() window.addView(windows, mainLayoutParams) import "android.os.Handler" local handler = Handler() local startTime = os.time() local runnable -- 启动计时器 function startTimer() local runnable runnable = luajava.createProxy("java.lang.Runnable", { run = function() local elapsed = os.time() - startTime timerText.setText(tostring(elapsed).."s") handler.postDelayed(runnable, 1000) end }) handler.post(runnable) end -- 停止计时器(退出时调用) function stoimer() if runnable then handler.removeCallbacks(runnable) runnable = nil end end -- 启动时调用 startTimer() -- 在布局加载完成后执情 local nowTime = os.date("%Y年%m月%d日") -- 格式:2025.09.19 timeText.setText(nowTime) local wm = getLayoutParams() wm.flags = LayoutParams.FLAG_NOT_FOCUSABLE window.addView(luajava.loadlayout({ LinearLayout, __onFinish = function(v) starv = v end }), wm) change_menu(1) local snowConfig = { flakeCount = 10, minSize = 1, maxSize = 30, minSpeed = 1000, maxSpeed = 2000, minDelay = 300, maxDelay = 800, windEnabled = true, maxWind = 20, minRotation = -360, maxRotation = 360, rotationProbability = 0.6, --flakeImages = {"❄️", "❄", "❅", "❆", "❊"} } local function createSnowFlake(delay) if not isSnowActive then return end Handler().postDelayed(function() if not isSnowActive then return end local flakeChar = snowConfig.flakeImages[math.random(1, #snowConfig.flakeImages)] local flakeSize = math.random(snowConfig.minSize, snowConfig.maxSize) local flakeView = TextView(activity) flakeView.setText(flakeChar) flakeView.setTextSize(flakeSize) flakeView.setLayoutParams(LinearLayout.LayoutParams( ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT )) flakeView.setTextColor(0xFFFFFFFF) -- 添加阴影效果 local shadowRadius = math.random(2, 5) local shadowX = math.random(-3, 3) local shadowY = math.random(1, 3) local shadowColor = 0x80000000 flakeView.setShadowLayer(shadowRadius, shadowX, shadowY, shadowColor) snowContainer.addView(flakeView) local containerWidth = snowContainer.getWidth() local startX = math.random(0, containerWidth) local startY = math.random(-100, -20) flakeView.setX(startX) flakeView.setY(startY) flakeView.post(function() if not isSnowActive then snowContainer.removeView(flakeView) return end local containerHeight = snowContainer.getHeight() local duration = math.random(snowConfig.minSpeed, snowConfig.maxSpeed) local windOffset = snowConfig.windEnabled and math.random(-snowConfig.maxWind * 2, snowConfig.maxWind * 2) or 0 local animY = ObjectAnimator.ofFloat(flakeView, "y", startY, containerHeight + flakeSize) animY.setDuration(duration) animY.setInterpolator(LinearInterpolator()) local animX = ObjectAnimator.ofFloat(flakeView, "x", startX, startX + (containerWidth * windOffset / 100)) animX.setDuration(duration) local animSet = AnimatorSet() if math.random() < snowConfig.rotationProbability then local rotation = math.random(snowConfig.minRotation, snowConfig.maxRotation) local animRotate = ObjectAnimator.ofFloat(flakeView, "rotation", 0, rotation) animRotate.setDuration(duration) animSet.playTogether(animY, animX, animRotate) else animSet.playTogether(animY, animX) end animSet.addListener({ onAnimationEnd = function() if isSnowActive then snowContainer.removeView(flakeView) -- 无限循环生成新雪花 createSnowFlake(math.random(snowConfig.minDelay, snowConfig.maxDelay)) end end, onAnimationCancel = function() snowContainer.removeView(flakeView) end }) animSet.start() end) end, delay or math.random(snowConfig.minDelay, snowConfig.maxDelay)) end local function initSnowFlakes() isSnowActive = true for i = 1, snowConfig.flakeCount do createSnowFlake(math.random(0, 50)) end end local function clearSnowAnimation() isSnowActive = false snowContainer.removeAllViews() end snowContainer.post(function() initSnowFlakes() end) Looper.loop() end import 'android.graphics.Bitmap' import 'android.graphics.Canvas' import 'android.graphics.Rect' ViewFakeTransition = loadlayout({ FrameLayout, visibility = 'gone', elevation = '10dp', { ImageView, layout_height = 'match_parent', layout_width = 'match_parent' }, { ImageView, layout_height = 'match_parent', layout_width = 'match_parent' } }) local nothing = function() end function View2Bitmap(view, isblur) local width = view.getMeasuredWidth() local height = view.getMeasuredHeight() if width == 0 then width = 1 height = 1 end local bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); local canvas = Canvas(bitmap) canvas.translate(-view.getScrollX(), -view.getScrollY()) view.draw(canvas) if isblur then return getBlur(bitmap) else return bitmap end end function CAViewInfo(v) local info = luajava.astable(v.getLocationOnScreen()) local start = luajava.astable(starv.getLocationOnScreen()) return { info[1] - (mainLayoutParams.x - mainLayoutParams.width / 2) - start[1], info[2] - (mainLayoutParams.y - mainLayoutParams.height / 2) - start[2] } end import "android.animation.ObjectAnimator" import "android.view.animation.Animation" import "android.animation.ArgbEvaluator" import "android.animation.ValueAnimator" import "android.animation.FloatEvaluator" function CATransition(view1, view2, duration, polator, func, func2, keep,keepp) --起点[view对象或id字符串],终点[view对象或id字符串],时长[毫秒],插值器,开始函数,结束函数,是否保留起点可见[bool] func = func or nothing func2 = func2 or nothing if type(view1) == 'string' then view1 = luajava.getIdView(view1) end if type(view2) == 'string' then view2 = luajava.getIdView(view2) end if view1.getVisibility() == View.GONE then return end if view2.getVisibility() == View.GONE then return end if ViewFakeTransition.getVisibility() == View.VISIBLE then return end ViewFakeTransition.setVisibility(View.VISIBLE) local P1 = CAViewInfo(view1) local P2 = CAViewInfo(view2) local DrawingView1, DrawingView2 = ViewFakeTransition.getChildAt(0), ViewFakeTransition.getChildAt(1) DrawingView1.setImageBitmap(View2Bitmap(view1)) DrawingView1.setAlpha(1) DrawingView2.setImageBitmap(View2Bitmap(view2)) DrawingView2.setAlpha(0) local height1, width1, height2, width2, P11, P12, P21, P22 = view1.getMeasuredHeight(), view1.getMeasuredWidth(), view2.getMeasuredHeight(), view2.getMeasuredWidth(), P1[1], P1[2], P2[1], P2[2] if not keep then view1.setVisibility(View.INVISIBLE) end if not keepp then view2.setVisibility(View.INVISIBLE) end local VP = ViewFakeTransition.getLayoutParams() VP.height = height1 VP.width = width1 VP.setMargins(P11, P12, 0, 0) ViewFakeTransition.setLayoutParams(VP) local animator = ValueAnimator.ofObject(FloatEvaluator(), {0, 1}).setDuration(duration) animator.setInterpolator(polator) local listener = luajava.createProxy('android.animation.ValueAnimator$AnimatorUpdateListener', { onAnimationUpdate = function(animation) local animatedProgress = animation.getAnimatedValue() if animatedProgress > 1 then animatedProgress = 1 + (animatedProgress - 1) / 6 end VP.height = height1 + (height2 - height1) * animatedProgress VP.width = width1 + (width2 - width1) * animatedProgress VP.setMargins(P11 + (P21 - P11) * animatedProgress, P12 + (P22 - P12) * animatedProgress, 0, 0) ViewFakeTransition.setLayoutParams(VP) DrawingView1.setAlpha(1 - animatedProgress) DrawingView2.setAlpha(animatedProgress) end }) animator.addUpdateListener(listener) local listener = luajava.createProxy('android.animation.Animator$AnimatorListener', { onAnimationStart = func, onAnimationEnd = function() view2.setVisibility(View.VISIBLE) ViewFakeTransition.setVisibility(View.GONE) -- floatmain.removeView(ViewFakeTransition) window.updateViewLayout(floatWindow, mainLayoutParams) view2.setVisibility(View.VISIBLE) func2() end, onAnimationCancel = function(animator) end }) animator.addListener(listener) animator.start() end --越南数据 function 白权() ue4 = staticstart({"libUE4.so:bss", "Cb"}) hqdz = shan(ue4, {0x552370,0x30,0x4B8,0x2E40,0x3E8, 0x0}) end function 脸部(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 1 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 隐藏脸部(修改值) 白权() for xh = 0x0, 0x999, 0x38 do setvalue(hqdz + 0x0 + xh, D, 修改值) end end function 头发(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 2 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 眼镜(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 12 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 帽子(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 3 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 面罩(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 4 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 衣服(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 5 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 裤子(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 6 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 鞋子(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 7 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 背包(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 8 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 头盔(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 9 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 护甲(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 10 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 手(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 23 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 眼罩(修改值) 白权() for xh = 0x0, 0x999, 0x3C do if getvalue(hqdz + 0x8 + xh, D) == 12 then setvalue(hqdz + 0x0 + xh, D, 修改值) end end end function 内衣(修改值) 白权() for xh = 0x0, 0x999, 0x3C do local 类型值 = getvalue(hqdz + 0x8 + xh, D) if 类型值 == 24 or 类型值 == 12 then setvalue(hqdz + 0x0 + xh, D, 修改值) setvalue(hqdz + 0x8 + xh, D, 12) end end end function 内裤(修改值) 白权() for xh = 0x0, 0x999, 0x3C do local 类型值 = getvalue(hqdz + 0x8 + xh, D) if 类型值 == 25 or 类型值 == 4 then setvalue(hqdz + 0x0 + xh, D, 修改值) setvalue(hqdz + 0x8 + xh, D, 4) end end end local 当前方案 = "方案一" local arr_off1 = 0xd898 local arr_off2 = 0xd868 local last_val1 = 0 local last_val2 = 0 local 角色基地址 = nil local 基础偏移 = 0x18 -- 统一初始化 local function 初始化() 角色基地址 = nil -- 每次都重新搜,解决偶尔找不到 local range = gg.getRangesList("libUE4.so:bss", "Cb") if not range or #range == 0 then toast("未找到 libUE4.so:bss") return end local UE4 = range[1].start -- 扩大范围,提高找到概率 for i = 1, 2000 do local addr1 = get64zz(UE4 + 0xE2E00) local addr2 = get64zz(addr1 + 0x648) local addr3 = get64zz(addr2 + i * 0x4) local addr4 = get64zz(addr3 + 0x38) local 临时地址 = get64zz(addr4 + 0x38) local 判断地址 = get64zz(临时地址 + 0x20) + 0x18 if readD(判断地址) == 1000 then 角色基地址 = 临时地址 return true -- 找到就退出 end end return false end -- 方案一 local function 套装过一秒1(修改值) if not 初始化() then toast("方案一:未找到角色") return end local 皮肤地址 = get64zz(角色基地址 + arr_off1) + 基础偏移 last_val1 = getvalue(皮肤地址, D) setvalue(皮肤地址, D, 修改值) 衣服(last_val1) arr_off1 = arr_off1 + 0x18 if arr_off1 > 0xd898 + 60*0x18 then arr_off1 = 0xd898 end gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end -- 方案二 local function 套装过一秒2(修改值) if not 初始化() then toast("方案二:未找到角色") return end local 皮肤地址 = get64zz(角色基地址 + arr_off2) + 基础偏移 last_val2 = getvalue(皮肤地址, D) setvalue(皮肤地址, D, 修改值) 衣服(last_val2) arr_off2 = arr_off2 + 0x18 if arr_off2 > 0xd868 + 60*0x18 then arr_off2 = 0xd868 end gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end -- 统一入口 function 套装过一秒(修改值) if 当前方案 == "方案一" then 套装过一秒1(修改值) else 套装过一秒2(修改值) end end function 调用方案一() 当前方案 = "方案一" toast.success("已切换:方案一") end function 调用方案二() 当前方案 = "方案二" toast.success("已切换:方案二") end --------枪械 local RUI = function(a) return gg.getValues({{address=a,flags=gg.TYPE_QWORD}})[1].value end local readD = function(a) return gg.getValues({{address=a,flags=4}})[1].value end local 写入 = function(a,f,v) gg.setValues({{address=a,flags=f,value=v}}) end local function getFinalAddr() local base = gg.getRangesList("libUE4.so:bss","Cb")[1].start local o = {0x552370,0x30,0x4B8,0x25B8,0x5C8,0x7A0,0x11c} local p = base p = RUI(p+o[1]) p = RUI(p+o[2]) p = RUI(p+o[3]) p = RUI(p+o[4]) p = RUI(p+o[5]) p = RUI(p+o[6]) return p end local function 配件检测() gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") local p = getFinalAddr() local pyz = {0x4,0x2C,0x54,0x7C,0xA4} local old = {} for i=1,#pyz do old[i] = readD(p + pyz[i] + 0x18) old[i+#pyz] = readD(p + pyz[i] + 0x4) old[i+#pyz*2] = readD(p + pyz[i] + 0xC) end local start = os.time() local switched = false while os.time() - start < 3 do local changed = false for i=1,#pyz do local a = readD(p + pyz[i] + 0x18) local b = readD(p + pyz[i] + 0x4) local c = readD(p + pyz[i] + 0xC) if a ~= old[i] or b ~= old[i+#pyz] or c ~= old[i+#pyz*2] then changed = true break end end if changed then switched = true break end end if not switched then toast.error("未切换配件 取消美化") return false end toast.success("配件切换成功 美化成功") return true end function 枪械(val) if not 配件检测() then return end local p = getFinalAddr() 写入(p+0x11C,4,val) gg.sleep(2500) 写入(p+0x11C,4,0) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") end function 枪口(val) local p=getFinalAddr() 写入(p+0x04,4,val) end function 握把(val) local p=getFinalAddr() 写入(p+0x2C,4,val) end function 弹夹(val) local p=getFinalAddr() 写入(p+0x54,4,val) end function 枪托(val) local p=getFinalAddr() 写入(p+0x7C,4,val) end function 播报(val) local p=getFinalAddr() 写入(p+0x194,4,val) end function 红点(skin) local p=getFinalAddr() if readD(p+0xA4)==203001 then 写入(p+0xA4,4,skin) end end function 全息(skin) local p=getFinalAddr() if readD(p+0xA4)==203002 then 写入(p+0xA4,4,skin) end end function 二倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203003 then 写入(p+0xA4,4,skin) end end function 三倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203014 then 写入(p+0xA4,4,skin) end end function 四倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203004 then 写入(p+0xA4,4,skin) end end function 六倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203015 then 写入(p+0xA4,4,skin) end end function 八倍(skin) local p=getFinalAddr() if readD(p+0xA4)==203005 then 写入(p+0xA4,4,skin) end end 高度 =950 宽度 =1350 头像='/storage/emulated/0/时之初遇/资源/头像' 左上角ID = '时之初遇'--项目名称 版本名称 = '❄ 1.0 版 本 ❄️' menum = { { ['分区名字']='美化主页', ['分区logo']='/storage/emulated/0/时之初遇/资源/主页', ['二级分页']={ { ['分页名字']='公告', ['分页logo']='99999', ['分页菜单']={ { TextView, id = luajava.newId('例子3'), text = '公告', onClick = function(v) CATransition('例子3', '例子4', 500, OvershootInterpolator(),nil,nil,true) end, }, Userpanel,--用户信息面板 ed.kong("3dp"), ed.button("选择进程", function() gg.setProcessX() gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("选择进程") end), ed.button("清除冻结", function() gg.clearList() gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("清除成功") end), ed.box({"判断播报(未更新)", ed.checkbox({--三个一行 { "判断播报(手持)", function() end }, { "判断播报(自身)", function() end }, }), }), ed.box({"美化方案", ed.checkbox({--三个一行 { "方案一(默认)", function() 调用方案一() end }, { "方案二", function() 调用方案二() end }, }), }), }}, { ['分页名字']='功能', ['分页logo']='99999', ['分页菜单']={--直接写table的例子,看起来会比较乱 ed.seek('动态广角','cess',90,130,90,1,'动态广角',--名称,id,最小值,最大值,当前值,步长,单位 function(v) local t = {"libUE4.so:bss", "Cb"} local tt = {0x552370,0x30,0x4B8,0x1D40,0x39C} local ttt = S_Pointer(t, tt, true) gg.addListItems({{address = ttt, flags = 16, value = v, freeze = true}}) toast.success("动态广角:" .. v) end), ed.seek('游戏帧率','cess',60,165,60,1,'游戏帧率',--名称,id,最小值,最大值,当前值,步长,单位 function(z) local t = {"libUE4.so:bss", "Cb"} local tt = {0x1FC8, 0x18} local ttt = S_Pointer(t, tt, true) gg.addListItems({{address = ttt, flags = 16, value = z, freeze = true}}) local t = {"libUE4.so:bss", "Cb"} local tt = {0x1FC8, 0x1C} local ttt = S_Pointer(t, tt, true) gg.addListItems({{address = ttt, flags = 16, value = z, freeze = true}}) toast.success("游戏帧率:" .. z) end), ed.switch("微加速", function() local r = gg.prompt({"微加速: [推荐使用1.2 最高5]"}, {"1.2"}, {"text"}) if not r then gg.toast("操作取消") return end local Q = tonumber(r[1]) -- 数值校验 if not Q or Q < 0 or Q > 5 then gg.toast("输入无效!请输1-5的数值") return end local t = {"libUE4.so:bss", "Cb"} local tt = {0x552370,0x30,0x4B8,0x1168} local ttt = S_Pointer(t, tt, true) gg.addListItems({{address = ttt, flags = 16, value = Q, freeze = true}}) toast.success("微加速:" .. Q) end), ed.box({"高危功能(请使用内核模式)", ed.checkbox({--三个一行 { "范围", function() end }, { "游戏除雾", function() if gg.getRangesList("libUE4.so")[1] then local t = {} t[1] = gg.getRangesList("libUE4.so")[1]["start"] + 0x8ca13e0; -- 数值地址:0x78E36576B8 gg.addListItems({ [1] = { address = t[1], flags = 4, value = -721215457, freeze = true, }, }) end end, function() if gg.getRangesList("libUE4.so")[1] then local t = {} t[1] = gg.getRangesList("libUE4.so")[1]["start"] + 0x8ca13e0; -- 数值地址:0x78E36576B8 gg.addListItems({ [1] = { address = t[1], flags = 4, value = -1119851903, freeze = true, }, }) end end },{ "据点", function() end }, }), }), }}, { ['分页名字']='设置', ['分页logo']='99999', ['分页菜单']={--直接写table的例子,看起来会比较乱 ed.switch("内核模式", function() 内核读写("开") end, function() 内核读写("关") end), ed.switch("隐藏GG图标", function() gg.hide(true) toast.success("隐藏GG") end, function() gg.hide(false) toast.error("显示GG") end), }, },--二分页 }},--主分页 {--主分页 ['分区名字']='服饰', ['分区logo']='/storage/emulated/0/时之初遇/资源/衣服', ['二级分页']={ {--二分页 ['分页名字']='套装', ['分页logo']='9999', ['分页菜单']={ ed.text("记得点初始化"), ed.buttonMenu({ {"重置自身", "/storage/emulated/0/时之初遇/资源/隐藏", function() 帽子(0) 头发(0) --隐藏脸部(257) --脸部(405200) --眼镜(0) --面罩(0) 衣服(0) 裤子(0) 鞋子(0) 背包(0) 头盔(0) 护甲(0) 内衣(405200) 内裤(405200) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"炽羽菲妮萨", "/storage/emulated/0/时之初遇/资源/炽羽菲妮萨", function() 头发(402378) 内裤(402381) 套装过一秒(1407856) end}, {"秘渊灵主", "/storage/emulated/0/时之初遇/资源/秘渊灵主", function() 头发(402147) 脸部(402154) 套装过一秒(1406971) end}, {"风灵迦尔", "/storage/emulated/0/时之初遇/资源/风灵迦尔", function() 套装过一秒(1407366) 头发(1407372) 内裤(1407369) 脸部(1407373) end}, {"蚀魂冥王", "/storage/emulated/0/时之初遇/资源/蚀魂冥王", function() 套装过一秒(1406891) 头发(1410436) end}, {"血鸦", "/storage/emulated/0/时之初遇/资源/血鸦", function() 内裤(1403257) 套装过一秒(1407895) end}, {"极地冥王", "/storage/emulated/0/时之初遇/资源/极地冥王", function() 套装过一秒(1407618) end}, {"曙光芙洛拉", "/storage/emulated/0/时之初遇/资源/曙光芙洛拉", function() 内裤(1403655) 脸部(402165) 头发(1410561) 套装过一秒(1407103) end}, {"曙光女帝", "/storage/emulated/0/时之初遇/资源/曙光女帝", function() 脸部(402296) 头发(402297) 套装过一秒(1407558) end}, {"逍遥谪仙", "/storage/emulated/0/时之初遇/资源/逍遥谪仙", function() 脸部(402260) 头发(402261) 套装过一秒(1407470) end}, {"烈焰古神", "/storage/emulated/0/时之初遇/资源/烈焰古神", function() 头发(1410668) 套装过一秒(1407277) end}, {"神羽恋人", "/storage/emulated/0/时之初遇/资源/神羽恋人", function() 头发(402210) 内裤(1410647) 脸部(402209) 套装过一秒(1407276) end}, {"暗烬天使", "/storage/emulated/0/时之初遇/资源/暗烬天使", function() 头发(402214) 脸部(402213) 套装过一秒(1407275) end}, {"金尊法老", "/storage/emulated/0/时之初遇/资源/金尊法老", function() 头发(1410128) 套装过一秒(1406469)----y end}, {"明日香", "/storage/emulated/0/时之初遇/资源/明日香", function() 套装过一秒(1406387) 头发(1403103) end}, {"零战斗", "/storage/emulated/0/时之初遇/资源/零战斗", function() 套装过一秒(1406386) 头发(1403102) end}, {"真理战斗", "/storage/emulated/0/时之初遇/资源/真理战斗", function() 套装过一秒(1406388) 头发(1403104) end}, {"万圣木乃伊", "/storage/emulated/0/时之初遇/资源/万圣木乃伊", function() 套装过一秒(1400687) end}, {"冥界旅行者", "/storage/emulated/0/时之初遇/资源/冥界旅行者", function() 套装过一秒(1405623) end}, {"废墟猎手", "/storage/emulated/0/时之初遇/资源/废墟猎手", function() 套装过一秒(1405163) end}, {"擎天柱", "/storage/emulated/0/时之初遇/资源/擎天柱", function() 头发(1410915) 套装过一秒(1407614) end}, {"大黄蜂", "/storage/emulated/0/时之初遇/资源/大黄蜂", function() 头发(1410916) 套装过一秒(1407615) end}, {"威震天", "/storage/emulated/0/时之初遇/资源/威震天", function() 头发(1410917) 套装过一秒(1407612) end}, {"利威尔", "/storage/emulated/0/时之初遇/资源/利威尔", function() 头发(402295) 脸部(402294) 套装过一秒(1407602) end}, {"进击的巨人", "/storage/emulated/0/时之初遇/资源/进击的巨人", function() 头发(402301) 套装过一秒(1407598) end}, {"超大型巨人", "/storage/emulated/0/时之初遇/资源/超大型巨人", function() 套装过一秒(1407601) end}, {"祖国人", "/storage/emulated/0/时之初遇/资源/祖国人", function() 头发(402116) 脸部(402114) 套装过一秒(1406439) end}, {"千面诡皇", "/storage/emulated/0/时之初遇/资源/千面诡皇", function() 头发(1410245) 套装过一秒(1406641) end}, }), }, },--二分页 {--二分页 ['分页名字']='背包', ['分页logo']='999', ['分页菜单']={ ed.buttonMenu({ {"隐藏背包", "/storage/emulated/0/时之初遇/资源/隐藏", function() 背包(0) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"战术星舱", "/storage/emulated/0/时之初遇/资源/战术星舱", function() 背包(1501003663) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"帝皇肖像", "/storage/emulated/0/时之初遇/资源/帝皇肖像", function() 背包(1501003668) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"璃光剪影", "/storage/emulated/0/时之初遇/资源/璃光剪影", function() 背包(1501003688) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"灵符雕龙", "/storage/emulated/0/时之初遇/资源/灵符雕龙", function() 背包(1501003677) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"银河之心", "/storage/emulated/0/时之初遇/资源/银河之心", function() 背包(1501003649) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"仲夜迷蝶", "/storage/emulated/0/时之初遇/资源/仲夜迷蝶", function() 背包(1501003672) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"寄生核心", "/storage/emulated/0/时之初遇/资源/寄生核心", function() 背包(1501003652) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"簪花葫芦", "/storage/emulated/0/时之初遇/资源/簪花葫芦", function() 背包(1501003629) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"蝴蝶花灵", "/storage/emulated/0/时之初遇/资源/蝴蝶花灵", function() 背包(1501003047) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"致命凝视", "/storage/emulated/0/时之初遇/资源/致命凝视", function() 背包(1501003487) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"金蛇瑰宝", "/storage/emulated/0/时之初遇/资源/金蛇瑰宝", function() 背包(1501003639) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"古城密探", "/storage/emulated/0/时之初遇/资源/古城密探", function() 背包(1501003053) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"朋克犀牛", "/storage/emulated/0/时之初遇/资源/朋克犀牛", function() 背包(1501003211) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"恐龙布朗熊", "/storage/emulated/0/时之初遇/资源/恐龙布朗熊", function() 背包(1501003261) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"莎莉", "/storage/emulated/0/时之初遇/资源/莎莉", function() 背包(1501003554) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"愚人小丑", "/storage/emulated/0/时之初遇/资源/愚人小丑", function() 背包(1501003051) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, {"像素恐龙", "/storage/emulated/0/时之初遇/资源/像素恐龙", function() 背包(1501003310) gg.playMusic("/storage/emulated/0/时之初遇/资源/音频") toast.success("美化成功") end}, }), }, },--二分页 {--二分页 ['分页名字']='护甲', ['分页logo']='999', ['分页菜单']={ ed.buttonMenu({ {"冰霜手套", "/storage/emulated/0/时之初遇/资源/", function() 护甲(452001) end}, {"流沙手套", "/storage/emulated/0/时之初遇/资源/", function() 护甲(452003) end}, {"水墨手套", "/storage/emulated/0/时之初遇/资源/", function() 护甲(452002) end}, }), }, },--二分页 { ['分页名字']='头盔', ['分页logo']='999', ['分页菜单']={ ed.buttonMenu({ {"隐藏头盔", "/storage/emulated/0/时之初遇/资源/隐藏", function() 头盔(0) end}, {"头盔", "/storage/emulated/0/时之初遇/资源/", function() end}, }), }, },--二分页 }},--主分页 { ['分区名字']='枪械', ['分区logo']='/storage/emulated/0/时之初遇/资源/枪械', ['二级分页']={ {--二分页 ['分页名字']='步枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"M416", ed.checkbox({--三个一行 { "冰霜核心", function() 红点(1010040470) 全息(1010040469) 二倍(1010040468) 三倍(1010040467) 四倍(1010040466) 六倍(1010040481) 枪口(1010040475) 握把(1010040477) 弹夹(1010040461) 枪托(1010040463) 播报(1101004046)--播报 枪械(1101004046)--枪械 end }, { "愚人小丑", function() 红点(1010040569) 全息(1010040568) 二倍(1010040567) 三倍(1010040566) 四倍(1010040565) 六倍(1010040564) 枪口(1010040577) 握把(1010040585) 弹夹(1010040621) 枪托(1010040623) 播报(1101004062)--播报 枪械(1101004062)--枪械 end }, { "武魂宗师", function() 播报(1101004200)--播报 枪械(1101004200)--枪械 end }, { "虎啸丹青", function() 红点(1010042299) 全息(1010042298) 二倍(1010042297) 三倍(1010042296) 四倍(1010042295) 六倍(1010042294) 枪口(1010042307) 握把(1010042314) 弹夹(1010042304) 枪托(1010042363) 播报(1101004236)--播报 枪械(1101004236)--枪械 end }, { "赤霄神剑", function() 红点(1010042399) 全息(1010042398) 二倍(1010042397) 三倍(1010042396) 四倍(1010042395) 六倍(1010042394) 枪口(1010042407) 握把(1010042414) 弹夹(1010042404) 枪托(1010042463) 播报(1101004246)--播报 枪械(1101004246)--枪械 end }, }), }),--box尾 ed.box({"AK47", ed.checkbox({--三个一行 { "律动光影", function() 红点(1010012697) 全息(1010012696) 二倍(1010012695) 三倍(1010012694) 四倍(1010012693) 六倍(1010012692) 枪口(1010012699) 弹夹(1010012703) 播报(1101001276)--播报 枪械(1101001276) end }, { "星海提督", function() 播报(1101001212)--播报 枪械(1101001212) end }, { "沙影神国", function() 播报(1101001265)--播报 枪械(1101001265)--枪械 end }, { "冰霜核心", function() 播报(1101001089)--播报 枪械(1101001089)--枪械 end }, }), }),--box尾 ed.box({"SCAR-L", ed.checkbox({--三个一行 { "凤曜琼华", function() 红点(1010032206) 全息(1010032205) 二倍(1010032204) 三倍(1010032204) 四倍(1010032203) 六倍(1010032202) 枪口(1010032242) 握把(1010032249) 弹夹(1010032210) 播报(1101003227)--播报 枪械(1101003227)--枪械 end }, { "霓虹天后", function() 播报(1101003195)--播报 枪械(1101003195)--枪械 end }, { "御灵魂契", function() 播报(1101003219)--播报 枪械(1101003219)--枪械 end }, { "梦幻奇缘", function() 播报(1101003208)--播报 枪械(1101003208)--枪械 end }, }), }),--box尾 ed.box({"AUG", ed.checkbox({--三个一行 { "罪恶玫瑰", function() 红点(1010060788) 全息(1010060787) 二倍(1010060786) 三倍(1010060785) 四倍(1010060784) 六倍(1010060783) 枪口(1010060795) 握把(1010060805) 弹夹(1010060794) 播报(1101006085)--播报 枪械(1101006085)--枪械 end }, { "破军狂鸣", function() 红点(1010060696) 全息(1010060695) 二倍(1010060694) 三倍(1010060693) 四倍(1010060692) 六倍(1010060691) 枪口(1010060701) 握把(1010060709) 弹夹(1010060699) 播报(1101006074)--播报 枪械(1101006074)--枪械 end }, { "弃誓冰灵", function() 红点(1010060562) 全息(1010060561) 二倍(1010060554) 三倍(1010060553) 四倍(1010060552) 六倍(1010060551) 枪口(1010060573) 握把(1010060582) 弹夹(1010060572) 播报(1101006062)--播报 枪械(1101006062)--枪械 end }, }), }),--box尾 ed.box({"GROZA", ed.checkbox({--三个一行 { "红莲哥斯拉", function() 播报(1101005098)--播报 枪械(1101005098)--枪械 end }, { "暗夜裁决", function() 播报(1101005091)--播报 枪械(1101005091)--枪械 end }, }), }),--box尾 ed.box({"M762", ed.checkbox({--三个一行 { "铂金骸骨", function() 红点(1010081526) 全息(1010081525) 二倍(1010081524) 三倍(1010081523) 四倍(1010081522) 六倍(1010081521) 枪口(1010081532) 握把(1010081542) 弹夹(1010081529) 播报(1101008154)--播报 枪械(1101008154)--枪械 end }, { "灵阁魔剪", function() 播报(1101008157)--播报 枪械(1101008157)--枪械 end }, }), }),--box尾 ed.box({"ACE", ed.checkbox({--三个一行 { "传奇海怪号", function() 播报(1101102024)--播报 枪械(1101102024)--枪械 end }, { "清夜蝶吻", function() 播报(1101102041)--播报 枪械(1101102041)--枪械 end }, }), }),--box尾 }, },--二分页 { ['分页名字']='射手步枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"MK14", ed.checkbox({--三个一行 { "S11", function() 枪械(1103007010) end }, { "星云力量", function() 播报(1103007020) 枪械(1103007020) end }, { "憨憨萌龙", function() 播报(1103007038) 枪械(1103007038) end }, { "龙吟国度", function() 红点(1030070218) 全息(1030070217) 二倍(1030070216) 三倍(1030070215) 四倍(1030070214) 六倍(1030070213) 八倍(1030070212) 枪口(1030070234) 弹夹(1030070226) 枪托(1030070236) 播报(1103007028) 枪械(1103007028) end }, }), }),--box尾 }, },--二分页 { ['分页名字']='机枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"MG3", ed.checkbox({--三个一行 { "C7S21", function() 枪械(1105010020) 弹夹(1050100201) end }, { "苍穹之龙", function() 播报(1105010008)--播报 枪械(1105010008)--枪械 end }, { "风鸣神戟", function() 红点(1050100144) 全息(1050100143) 二倍(1050100142) 三倍(1050100141) 四倍(1050100139) 六倍(1050100138) 弹夹(1050100137) 播报(1105010019)--播报 枪械(1105010019)--枪械 end }, }), }),--box尾 ed.box({"DP28", ed.checkbox({--2个一行 { "血狱寄生", function() 枪械(1105002091) 播报(1105002091)--播报 弹夹(1050020911) end }, { "玩世狐妖", function() 弹夹(1050020961) 枪械(1105002096)--枪械 end }, }), }),--box尾 ed.box({"M249", ed.checkbox({--2个一行 { "桀骜帝皇", function() 枪械(1105001069) 播报(1105001069)--播报 弹夹(1050010691) end }, { "极辉女帝", function() 弹夹(1050010481) 播报(1105001048)--播报 枪械(1105001048)--枪械 end }, }), }),--box尾 }, },--二分页 { ['分页名字']='冲锋枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"UMP45", ed.checkbox({--三个一行 { "噬魂凝视", function() 红点(1020024187) 全息(1020024186) 二倍(1020024185) 三倍(1020024184) 四倍(1020024183) 六倍(1020024182) 播报(1102002424)--播报 枪械(1102002424)--枪械 end }, { "水晶冰刺", function() 红点(1020021307) 全息(1020021306) 二倍(1020021305) 三倍(1020021304) 四倍(1020021303) 六倍(1020021302) 播报(1102002136)--播报 枪械(1102002136)--枪械 end}, }), }), ed.box({"UZI", ed.checkbox({--三个一行 { "烈焰枷锁", function() 红点(1020011243) 播报(1102001130)--播报 枪械(1102001130)--枪械 end }, { "冰晶神锤", function() 红点(1020011133) 播报(1102001120)--播报 枪械(1102001120)--枪械 end}, }), }), }, },--二分页 { ['分页名字']='狙击枪', ['分页logo']='9999', ['分页菜单']={ ed.box({"98K", ed.checkbox({--三个一行 { "冰魄幻羽", function() 红点(1030011947) 全息(1030011946) 二倍(1030011945) 三倍(1030011944) 四倍(1030011943) 六倍(1030011942) 八倍(1030011941) 播报(1103001202)--播报 枪械(1103001202)--枪械 end }, { "紫戮电极", function() 红点(1030011737) 全息(1030011736) 二倍(1030011735) 三倍(1030011734) 四倍(1030011733) 六倍(1030011732) 八倍(1030011731) 播报(1103001179)--播报 枪械(1103001179)--枪械 end}, }), }),--box尾 ed.box({"M24", ed.checkbox({--三个一行 { "夜影晨曦", function() 红点(1030021078) 全息(1030021077) 二倍(1030021076) 三倍(1030021075) 四倍(1030021074) 六倍(1030021073) 八倍(1030021072) 枪口(1030021080) 弹夹(1030021086) 枪托(1030021083) 播报(1103002113) 枪械(1103002113) end}, }), }),--box尾 ed.box({"AWM", ed.checkbox({--三个一行 { "玲珑白蛇", function() 红点(1030030818) 全息(1030030817) 二倍(1030030816) 三倍(1030030815) 四倍(1030030814) 六倍(1030030813) 八倍(1030030812) 枪口(1030030826) 弹夹(1030030824) 枪托(1030030828) 播报(1103003087) 枪械(1103003087) end }, { "赤潮龙息", function() 红点(1030030738) 全息(1030030737) 二倍(1030030736) 三倍(1030030735) 四倍(1030030734) 六倍(1030030733) 八倍(1030030732) 枪口(1030030745) 弹夹(1030030743) 枪托(1030030747) 播报(1103003079) 枪械(1103003079) end },{ "紫夜苍穹", function() 四倍(1030030164) 六倍(1030030163) 八倍(1030030162) 枪口(1030030166) 弹夹(1030030172) 枪托(1030030168) 播报(1103003022) 枪械(1103003022) end}, }), }),--box尾 ed.box({"AMR", ed.checkbox({--三个一行 { "灵泉剑影", function() 红点(1030120258) 全息(1030120257) 二倍(1030120256) 三倍(1030120255) 四倍(1030120254) 六倍(1030120253) 八倍(1030120252) 弹夹(1030120311) 播报(1103012031) 枪械(1103012031) end }, { "烈焰圣枪", function() 红点(1030120138) 全息(1030120137) 二倍(1030120136) 三倍(1030120135) 四倍(1030120134) 六倍(1030120133) 八倍(1030120132) 弹夹(1030120138) 播报(1103012019) 枪械(1103012019) end },{ "嗜血魔魇", function() 红点(1030120038) 全息(1030120037) 二倍(1030120036) 三倍(1030120035) 四倍(1030120034) 六倍(1030120033) 八倍(1030120032) 弹夹(1030120101) 播报(1103012010) 枪械(1103012010) end}, }), }),--box尾 }, },--二分页 }},--主分页 } ed.menu(icon, title, menum) --结束 end function c() end function Exit() print("脚本已安全退出") os.exit() end cs = "这里可以改成你的QQ" while true do if gg.isVisible(true) then XGCK = 1 gg.setVisible(false) end gg.clearResults() if XGCK == 1 then Main() end end