脚本验证

屠杀辅助选择加减乘除结果

时间:2019/3/25 10:55:05  作者:屠杀辅助  来源:http://www.tushafuzhu.com/  查看:9965  评论:0
内容摘要:​/",")"},      } localfunctionmaskstr(str)  fork,vinipairs(tab)do   str=str:gsub(v[1],v[2])  end  returnstr end ifstr:match("选择正确的答案")then  localsf=nil  localgs...
屠杀辅助选择加减乘除结果
/<
lastmsg=""
function 过验证()
  local str=获取NPC对话内容()
  if not str or str==lastmsg then return end -- 防止重复过
  lastmsg = str
  local tab={
              {"加","+"},{"减","-"},{"乘","*"},{"除","/"},
              {"+","+"},{"—","-"},{"×","*"},{"÷","/"},
              {"%[","("},{"%]",")"},{"【","("},{"】",")"},
              {"{","("},{"}",")"},{"<","("},{">",")"},
            }
  local function maskstr(str)
    for k,v in ipairs(tab) do
      str=str:gsub(v[1],v[2])
    end
    return str
  end
  if str:match("选择正确的答案") then
    local sf=nil
    local gs = str:match("([0-9+%+%-%—÷×%*加减乘除%[%]%(%)【】{}]+)=")
    if gs then
      print("计算公式:"..maskstr(gs))
      sf = load("return "..maskstr(gs))
    end
    if sf then
    local num = sf()
      local nearest=65535
      print("计算结果:"..num)
      local cmd = nil
      for k,c in str:gmatch("<(%d+)/(@[^>]+)>") do
        if math.abs(k-num) < nearest then
          nearest = math.abs(k-num)
          cmd = c
        end
      end
      if cmd then 
        print(cmd)
        选择(cmd)
        等待(1500)
      end
    end
  end
end
过验证() -- 回收验证保留此行,删除下面一行
设置用户检测("过验证",2000) -- 脱机验证保留此行,删除上面一行
/>
标签:屠杀 辅助 选择 结果 
相关评论
评论者:      验证码:  点击获取验证码
屠杀辅助专业研究互联辅助加速工具直接秒过市面上各种最新登陆器

屠杀辅助官网若有侵权内容请联系站长删除

 致力打造绿色安全玩家交流网