mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-03-17 13:25:26 +08:00
Refactor: Rename retire configs
- Fix combat drop screenshot missed because clicking too fast - Close campaign preparation at start
This commit is contained in:
@@ -47,13 +47,26 @@ class DropImage:
|
||||
"""
|
||||
Args:
|
||||
image: Pillow image.
|
||||
|
||||
Returns:
|
||||
bool: If added.
|
||||
"""
|
||||
if self:
|
||||
self.images.append(image)
|
||||
|
||||
def handle_add(self, main, before=None):
|
||||
"""
|
||||
Handle wait before and after adding screenshot.
|
||||
|
||||
Args:
|
||||
main (ModuleBase):
|
||||
before (int, float, tuple): Sleep before adding.
|
||||
"""
|
||||
if before is None:
|
||||
before = main.config.WAIT_BEFORE_SAVING_SCREEN_SHOT
|
||||
|
||||
if self:
|
||||
main.device.sleep(before)
|
||||
main.device.screenshot()
|
||||
self.add(main.device.image)
|
||||
|
||||
def __bool__(self):
|
||||
return self.save or self.upload
|
||||
|
||||
|
||||
Reference in New Issue
Block a user