Skip to content

Commit

Permalink
FIX:Mod
Browse files Browse the repository at this point in the history
  • Loading branch information
GalacticDevOps authored Oct 11, 2024
1 parent 4a6f1ec commit 70b6d1c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 23 deletions.
26 changes: 3 additions & 23 deletions frida/matchV2/do_matchV2.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
def answer_write(answer):
for i in range(len(answer)):
number_command.swipe_screen(answer[i])
time.sleep(0.08)
time.sleep(0.16)

def select_answer(answer):

Expand Down Expand Up @@ -53,42 +53,21 @@ def select_answer(answer):


def gui_answer(answer, q_num):
# CONFIG #
tick_time = 0.05 # 每题间隔时间
start_time = 12.5 # 开始做题前摇时间
# 创建一个GUI
root = tk.Tk()
root.title("继续执行")

def on_button_click():
answer_write(answer) # 继续执行代码

def on_button2_click():
number_command.next_round() # 继续执行代码
root.destroy()
# 创建一个按钮

# 创建一个按钮
button = tk.Button(root, text="点击继续", command=on_button_click)
button2 = tk.Button(root, text="下一把", command=on_button2_click)
button.pack(pady=20)
button2.pack(pady=20)

# 设置定时器,若干秒后自动点击按钮
time = int(start_time * 1000)
root.after(time, on_button_click)
time2 = int((start_time + tick_time * 1.15 * q_num + 5) * 1000)
root.after(time2, on_button2_click)
# 运行 GUI 界面
root.mainloop()

# time.sleep(4)
# answer_write(answer)
# time.sleep(7)
# command = "input tap 1445 1272"
# number_command.run_adb_command(command)
# time.sleep(0.1)
# command = "input tap 2144 1694"
# number_command.run_adb_command(command)

# 通过链接到虚拟机frida-server
device = frida.get_usb_device()
Expand Down Expand Up @@ -136,6 +115,7 @@ def on_message(message, data):
answer_dict = json.loads(result)
select_answer(answer_dict)

# TODO 数据重新返回

# result进行base64加密
result_makebase64 = base64.b64encode(result.encode('utf-8')).decode('utf-8')
Expand Down
1 change: 1 addition & 0 deletions frida/matchV2/number_command.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ def str_to_xy(str):

if __name__ == "__main__":
# 执行滑动操作
swipe_screen(">")
swipe_screen("<")
swipe_screen("=")

0 comments on commit 70b6d1c

Please sign in to comment.