mirror of
https://github.com/TheFunny/ArisuAutoSweeper
synced 2025-12-17 00:15:13 +00:00
feat(stage): add offset to stage item box
This commit is contained in:
parent
51ecdf4908
commit
e82c4f875c
@ -152,6 +152,7 @@ class StageList:
|
|||||||
main: ModuleBase,
|
main: ModuleBase,
|
||||||
insight: bool = True,
|
insight: bool = True,
|
||||||
sweepable: bool = True,
|
sweepable: bool = True,
|
||||||
|
offset: tuple[int, int] = (-20, -15),
|
||||||
skip_first_screenshot: bool = True,
|
skip_first_screenshot: bool = True,
|
||||||
interval: int = 5
|
interval: int = 5
|
||||||
) -> bool:
|
) -> bool:
|
||||||
@ -175,7 +176,7 @@ class StageList:
|
|||||||
logger.warning(f'No index {index} in {self.index_ocr.name}')
|
logger.warning(f'No index {index} in {self.index_ocr.name}')
|
||||||
return False
|
return False
|
||||||
|
|
||||||
stage_item_box = area_pad((0, 0, *area_size(self.stage_item)))
|
stage_item_box = area_pad((*offset, *area_size(self.stage_item)))
|
||||||
search_box = area_offset(stage_item_box, index_box.box[:2])
|
search_box = area_offset(stage_item_box, index_box.box[:2])
|
||||||
search_image = main.image_crop(search_box)
|
search_image = main.image_crop(search_box)
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user