活动商店购买改进
All checks were successful
ci/woodpecker/push/check_format Pipeline was successful

This commit is contained in:
zhbaor 2025-01-26 21:31:19 +08:00
parent a61f8c202f
commit fee5eaccd5

View file

@ -36,7 +36,6 @@ class Shop(SceneGraphSolver):
solver_max_duration = timedelta(minutes=5)
def run(self):
self.notify_shop = False
self.product = None
return super().run()
@ -96,17 +95,16 @@ class Shop(SceneGraphSolver):
return True
self.tap(pos, update=False)
self.sleep(0.5, update=False)
self.notify_shop = True
self.ctap("sign_in/shop/buy", id=self.product)
elif scene == Scene.MATERIEL:
if self.notify_shop:
self.notify_shop = False
if self.product:
self.sleep()
notify(f"活动商店物品购买:{self.product}")
self.product = None
self.tap((960, 200))
elif scene == Scene.ROGUE_AGENT:
if self.notify_shop:
self.notify_shop = False
if self.product:
self.product = None
notify("活动商店时装购买")
self.tap((960, 200))
else: