def make_cloves_using_refill_button(gui): amount = 0 try: amount = int(gui.Input) except ValueError: Gui(["Wrong input"]).run() return activate_gw2() w_time = 0.05 if is_key_pressed("esc"): return move_and_click("left", "CloverMakerImg/coin.png", clicks=2, wait_time=w_time) if is_key_pressed("esc"): return move_and_click("left", "CloverMakerImg/ecto.png", clicks=2, wait_time=w_time) if is_key_pressed("esc"): return move_and_click("left", "CloverMakerImg/shard.png", clicks=2, wait_time=w_time) if is_key_pressed("esc"): return move_and_click("left", "CloverMakerImg/stone.png", clicks=2, wait_time=w_time) if is_key_pressed("esc"): return move_and_click("left", "CloverMakerImg/forge.png", wait_time=w_time) if is_key_pressed("esc"): return sleep(2) for _ in range(amount - 1): if is_key_pressed("esc"): return move_and_click("left", "CloverMakerImg/accept.png", clicks=1, wait_time=w_time) if is_key_pressed("esc"): return move_and_click("left", "CloverMakerImg/refill.png", clicks=1, wait_time=w_time) if is_key_pressed("esc"): return move_and_click("left", "CloverMakerImg/forge.png", clicks=1, wait_time=w_time) if is_key_pressed("esc"): return sleep(2)
def run_joiner(gui): activate_gw2() while True: if keyboard.is_pressed("esc"): break if gui.Commander.isChecked() or (not gui.Commander.isChecked() and not gui.Commander.isChecked()): move_and_click_with_type("commander") elif gui.Party.isChecked(): move_and_click_with_type("party")
def create_party(gui): party = None if gui.Fractal.isChecked(): party = BossConfiguration("CMs + T4") party.add_configuration(dps=2, bs=1, hfb=1, alacrane=1) elif gui.Strike.isChecked(): party = BossConfiguration("All Strike") party.add_configuration(dps=6, bs=1, hfb=2, alacrane=1) try: party.subtract_roles(dps=int(gui.dps), condidps=int(gui.condidps), bs=int(gui.bs), tank=int(gui.tank), druid=int(gui.druid), hfb=int(gui.hfb), alacrane=int(gui.alacrane)) except: gui2 = Gui(["Something went wrong"]) gui2.run() return party_string = party.create_list(gui.kp) activate_gw2() kb.send("Y") sleep(1) if is_key_pressed("esc"): return move_and_click("left", "GroupCreatorImg/lfg.png") if is_key_pressed("esc"): return if gui.Fractal.isChecked(): move_and_click("left", "GroupCreatorImg/fractals.png") if is_key_pressed("esc"): return move_and_click("left", "GroupCreatorImg/t4.png") if is_key_pressed("esc"): return move_and_click("left", "GroupCreatorImg/adv_group.png") if is_key_pressed("esc"): return sleep(0.15) kb.write(party_string) if is_key_pressed("esc"): return elif gui.Strike.isChecked(): move_and_click("left", "GroupCreatorImg/strike_main.png") if is_key_pressed("esc"): return move_and_click("left", "GroupCreatorImg/strike_inner.png") if is_key_pressed("esc"): return move_and_click("left", "GroupCreatorImg/adv_group.png") if is_key_pressed("esc"): return sleep(0.15) kb.write(party_string) if is_key_pressed("esc"): return
def make_cloves(gui): amount = 0 try: amount = int(gui.Input) except ValueError: Gui(["Wrong input"]).run() return activate_gw2() for _ in range(amount): w_time = 0.05 if is_key_pressed("esc"): break move_and_click("left", "CloverMakerImg/coin.png", clicks=2, wait_time=w_time) if is_key_pressed("esc"): break move_and_click("left", "CloverMakerImg/ecto.png", clicks=2, wait_time=w_time) if is_key_pressed("esc"): break move_and_click("left", "CloverMakerImg/shard.png", clicks=2, wait_time=w_time) if is_key_pressed("esc"): break move_and_click("left", "CloverMakerImg/stone.png", clicks=2, wait_time=w_time) if is_key_pressed("esc"): break move_and_click("left", "CloverMakerImg/forge.png", wait_time=w_time) if is_key_pressed("esc"): break sleep(1.3)
def send_kp(gui): try: ping_times_lower = int(gui.PingLower) ping_times_upper = int(gui.PingUpper) correct_chat_codes = get_correct_chat_code(gui) except ValueError: gui2 = Gui([ "Something went wrong with converting ping times field to integer, " "please check it if it is an integer." ]) gui2.run() return if correct_chat_codes is None: return activate_gw2() for cc in correct_chat_codes: ping_times = np.random.randint(ping_times_lower, ping_times_upper + 1) for _ in range(ping_times): send_procedure(cc) sleep(rand_time(0.18, 0.26))