mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-03-30 23:34:10 +08:00
Fix: Re-fit OpSi globe swipes
This commit is contained in:
@@ -329,6 +329,8 @@ class ManualConfig:
|
|||||||
'distance': 35,
|
'distance': 35,
|
||||||
'wlen': 500,
|
'wlen': 500,
|
||||||
}
|
}
|
||||||
|
# On minitouch, Screen swipe (200, 200) = Map swipe (382, 442)
|
||||||
|
OS_GLOBE_SWIPE_MULTIPLY = (1.91, 2.21)
|
||||||
|
|
||||||
"""
|
"""
|
||||||
module.retire
|
module.retire
|
||||||
|
|||||||
@@ -162,6 +162,8 @@ class GlobeCamera(GlobeOperation, ZoneManager):
|
|||||||
area = (400, 200, GLOBE_MAP_SHAPE[0] - 400, GLOBE_MAP_SHAPE[1] - 250)
|
area = (400, 200, GLOBE_MAP_SHAPE[0] - 400, GLOBE_MAP_SHAPE[1] - 250)
|
||||||
loca = point_limit(zone.location, area=area)
|
loca = point_limit(zone.location, area=area)
|
||||||
vector = np.array(loca) - self.globe_camera
|
vector = np.array(loca) - self.globe_camera
|
||||||
|
# TODO: Yeah, 0.8 multiplier is shit, better implement needed
|
||||||
|
vector = vector * 0.8 / self.config.OS_GLOBE_SWIPE_MULTIPLY
|
||||||
swipe = tuple(np.min([np.abs(vector), swipe_limit], axis=0) * np.sign(vector))
|
swipe = tuple(np.min([np.abs(vector), swipe_limit], axis=0) * np.sign(vector))
|
||||||
self.globe_swipe(swipe)
|
self.globe_swipe(swipe)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user