mirror of
https://github.com/LmeSzinc/StarRailCopilot.git
synced 2024-11-22 08:37:42 +00:00
Merge branch 'master' into dev
This commit is contained in:
commit
5bb58c7f50
8
.gitignore
vendored
8
.gitignore
vendored
@ -19,6 +19,14 @@ config/reloadflag
|
||||
config/reloadalas
|
||||
test.py
|
||||
test/
|
||||
resources/
|
||||
locales/
|
||||
*.pak
|
||||
*.dll
|
||||
*.dat
|
||||
v8_context_snapshot.bin
|
||||
snapshot_blob.bin
|
||||
vk_swiftshader_icd.json
|
||||
|
||||
# Created by .ignore support plugin (hsz.mobi)
|
||||
|
||||
|
BIN
assets/en/rogue/ui/CURIO_OBTAINED.2.png
Normal file
BIN
assets/en/rogue/ui/CURIO_OBTAINED.2.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 9.4 KiB |
@ -216,6 +216,7 @@ class Route(RouteBase):
|
||||
| -------- | ------------------------- | --------- | -------- |
|
||||
| spawn | Waypoint((463.3, 123.5)), | 96.7 | 91 |
|
||||
| item | Waypoint((476.9, 129.9)), | 116.8 | 114 |
|
||||
| node1 | Waypoint((524.8, 122.6)), | 94.2 | 271 |
|
||||
| enemy1 | Waypoint((544.4, 128.5)), | 129.9 | 128 |
|
||||
| node2 | Waypoint((554.6, 141.6)), | 166.6 | 158 |
|
||||
| enemy2 | Waypoint((556.4, 206.8)), | 190.1 | 184 |
|
||||
@ -228,6 +229,7 @@ class Route(RouteBase):
|
||||
Waypoint((556.4, 206.8)), end_rotation=184,
|
||||
left_door=Waypoint((563.1, 211.9)), right_door=Waypoint((544.4, 211.7)))
|
||||
item = Waypoint((476.9, 129.9))
|
||||
node1 = Waypoint((524.8, 122.6))
|
||||
enemy1 = Waypoint((544.4, 128.5))
|
||||
node2 = Waypoint((554.6, 141.6))
|
||||
enemy2 = Waypoint((556.4, 206.8))
|
||||
@ -235,7 +237,11 @@ class Route(RouteBase):
|
||||
|
||||
self.rotation_set(120)
|
||||
self.clear_item(item)
|
||||
self.clear_enemy(enemy1)
|
||||
# Avoid the ice sculpture at corner
|
||||
self.clear_enemy(
|
||||
node1.set_threshold(5),
|
||||
enemy1,
|
||||
)
|
||||
self.rotation_set(180)
|
||||
self.clear_enemy(
|
||||
node2.set_threshold(5),
|
||||
|
@ -168,6 +168,7 @@ class Route(RouteBase):
|
||||
enemy2 = Waypoint((273.9, 584.9))
|
||||
# ===== End of generated waypoints =====
|
||||
|
||||
self.rotation_set(270)
|
||||
# 1
|
||||
self.clear_item(
|
||||
item1.straight_run(),
|
||||
@ -179,6 +180,41 @@ class Route(RouteBase):
|
||||
self.clear_item(item2)
|
||||
self.clear_enemy(enemy2)
|
||||
|
||||
def Luofu_Cloudford_F1_X433Y617(self):
|
||||
"""
|
||||
| Waypoint | Position | Direction | Rotation |
|
||||
| -------- | ------------------------- | --------- | -------- |
|
||||
| spawn | Waypoint((433.5, 616.8)), | 358.2 | 4 |
|
||||
| node1 | Waypoint((431.5, 593.4)), | 2.7 | 357 |
|
||||
| item1 | Waypoint((371.8, 592.8)), | 263.8 | 267 |
|
||||
| enemy1 | Waypoint((341.2, 586.8)), | 274.2 | 274 |
|
||||
| item2 | Waypoint((310.4, 582.2)), | 289.0 | 288 |
|
||||
| enemy2 | Waypoint((273.9, 584.9)), | 274.1 | 271 |
|
||||
| exit_ | Waypoint((273.9, 584.9)), | 274.1 | 271 |
|
||||
"""
|
||||
self.map_init(plane=Luofu_Cloudford, floor="F1", position=(433.5, 616.8))
|
||||
self.register_domain_exit(Waypoint((273.9, 584.9)), end_rotation=271)
|
||||
node1 = Waypoint((431.5, 593.4))
|
||||
item1 = Waypoint((371.8, 592.8))
|
||||
enemy1 = Waypoint((341.2, 586.8))
|
||||
item2 = Waypoint((310.4, 582.2))
|
||||
enemy2 = Waypoint((273.9, 584.9))
|
||||
# ===== End of generated waypoints =====
|
||||
|
||||
# Similar to Luofu_Cloudford_F1_X431Y593, but has different spawn point
|
||||
self.rotation_set(270)
|
||||
# 1
|
||||
self.clear_item(
|
||||
node1.set_threshold(3),
|
||||
item1.straight_run(),
|
||||
)
|
||||
self.clear_enemy(
|
||||
enemy1.straight_run(),
|
||||
)
|
||||
# 2
|
||||
self.clear_item(item2)
|
||||
self.clear_enemy(enemy2)
|
||||
|
||||
def Luofu_Cloudford_F1_X435Y669(self):
|
||||
"""
|
||||
| Waypoint | Position | Direction | Rotation |
|
||||
|
@ -1,6 +1,5 @@
|
||||
from tasks.map.control.waypoint import Waypoint
|
||||
from tasks.map.keywords.plane import Luofu_AlchemyCommission
|
||||
from tasks.map.route.base import locked_position
|
||||
from tasks.rogue.route.base import RouteBase
|
||||
|
||||
|
||||
@ -24,3 +23,30 @@ class Route(RouteBase):
|
||||
self.domain_reward(reward)
|
||||
self.domain_single_exit(exit_)
|
||||
# ===== End of generated waypoints =====
|
||||
|
||||
def Luofu_AlchemyCommission_F2_X664Y545(self):
|
||||
"""
|
||||
| Waypoint | Position | Direction | Rotation |
|
||||
| -------- | ------------------------- | --------- | -------- |
|
||||
| spawn | Waypoint((623.1, 590.0)), | 282.2 | 274 |
|
||||
| enemy | Waypoint((571.6, 589.5)), | 282.0 | 274 |
|
||||
| reward | Waypoint((563.5, 581.4)), | 281.9 | 274 |
|
||||
| exit_ | Waypoint((555.5, 597.3)), | 267.8 | 264 |
|
||||
"""
|
||||
self.map_init(plane=Luofu_AlchemyCommission, floor="F2", position=(664.2, 546.8))
|
||||
enemy = Waypoint((571.6, 589.5))
|
||||
reward = Waypoint((563.5, 581.4))
|
||||
exit_ = Waypoint((555.5, 597.3))
|
||||
|
||||
self.clear_elite(enemy)
|
||||
self.domain_reward(reward)
|
||||
self.domain_single_exit(exit_)
|
||||
# ===== End of generated waypoints =====
|
||||
|
||||
"""
|
||||
Notes
|
||||
Luofu_AlchemyCommission_F2_X664Y545 is the same as Luofu_AlchemyCommission_F2_X625Y590
|
||||
but for wrong spawn point detected
|
||||
|
||||
Spawn point is too far from the correct result but should be fine in Boss room
|
||||
"""
|
||||
|
@ -1,10 +1,12 @@
|
||||
from tasks.map.control.waypoint import Waypoint
|
||||
from tasks.map.keywords.plane import Jarilo_BackwaterPass
|
||||
from tasks.map.route.base import locked_position
|
||||
from tasks.rogue.route.base import RouteBase
|
||||
|
||||
|
||||
class Route(RouteBase):
|
||||
|
||||
@locked_position
|
||||
def Jarilo_BackwaterPass_F1_X581Y403(self):
|
||||
"""
|
||||
| Waypoint | Position | Direction | Rotation |
|
||||
|
@ -868,6 +868,17 @@
|
||||
],
|
||||
"domain": "Combat"
|
||||
},
|
||||
{
|
||||
"name": "Combat_Luofu_Cloudford_F1_X433Y617",
|
||||
"route": "route.rogue.Combat.Luofu_Cloudford_F1:Luofu_Cloudford_F1_X433Y617",
|
||||
"plane": "Luofu_Cloudford",
|
||||
"floor": "F1",
|
||||
"position": [
|
||||
433.5,
|
||||
616.8
|
||||
],
|
||||
"domain": "Combat"
|
||||
},
|
||||
{
|
||||
"name": "Combat_Luofu_Cloudford_F1_X435Y669",
|
||||
"route": "route.rogue.Combat.Luofu_Cloudford_F1:Luofu_Cloudford_F1_X435Y669",
|
||||
@ -1330,6 +1341,17 @@
|
||||
],
|
||||
"domain": "Elite"
|
||||
},
|
||||
{
|
||||
"name": "Elite_Luofu_AlchemyCommission_F2_X664Y545",
|
||||
"route": "route.rogue.Elite.Luofu_AlchemyCommission_F2:Luofu_AlchemyCommission_F2_X664Y545",
|
||||
"plane": "Luofu_AlchemyCommission",
|
||||
"floor": "F2",
|
||||
"position": [
|
||||
664.2,
|
||||
546.8
|
||||
],
|
||||
"domain": "Elite"
|
||||
},
|
||||
{
|
||||
"name": "Elite_Luofu_ArtisanshipCommission_F1_X385Y494",
|
||||
"route": "route.rogue.Elite.Luofu_ArtisanshipCommission_F1:Luofu_ArtisanshipCommission_F1_X385Y494",
|
||||
|
@ -59,7 +59,7 @@ class Daemon(RouteBase, DaemonBase, AimDetectorMixin):
|
||||
else:
|
||||
logger.warning(f'Maatouch contact on {builder.contact}, may cause interruptions')
|
||||
|
||||
STORY_OPTION.set_search_offset((-5, -5, 32, 5))
|
||||
STORY_OPTION.set_search_offset((-5, -10, 32, 5))
|
||||
INTERACT_COLLECT.set_search_offset((-5, -5, 32, 5))
|
||||
INTERACT_INVESTIGATE.set_search_offset((-5, -5, 32, 5))
|
||||
INTERACT_TREASURE.set_search_offset((-5, -5, 32, 5))
|
||||
|
@ -86,13 +86,22 @@ CURIO_OBTAINED = ButtonWrapper(
|
||||
color=(125, 126, 134),
|
||||
button=(643, 86, 708, 117),
|
||||
),
|
||||
en=Button(
|
||||
file='./assets/en/rogue/ui/CURIO_OBTAINED.png',
|
||||
area=(511, 88, 600, 116),
|
||||
search=(491, 68, 620, 136),
|
||||
color=(93, 95, 102),
|
||||
button=(511, 88, 600, 116),
|
||||
),
|
||||
en=[
|
||||
Button(
|
||||
file='./assets/en/rogue/ui/CURIO_OBTAINED.png',
|
||||
area=(511, 88, 600, 116),
|
||||
search=(491, 68, 620, 136),
|
||||
color=(93, 95, 102),
|
||||
button=(511, 88, 600, 116),
|
||||
),
|
||||
Button(
|
||||
file='./assets/en/rogue/ui/CURIO_OBTAINED.2.png',
|
||||
area=(526, 46, 605, 71),
|
||||
search=(506, 26, 625, 91),
|
||||
color=(103, 91, 66),
|
||||
button=(526, 46, 605, 71),
|
||||
),
|
||||
],
|
||||
)
|
||||
FLAG_UNRECORD = ButtonWrapper(
|
||||
name='FLAG_UNRECORD',
|
||||
|
@ -173,12 +173,20 @@ class RouteLoader(RogueUI, MinimapWrapper, RouteLoader_, CharacterSwitch):
|
||||
'Occurrence_Luofu_ArtisanshipCommission_F1_X169Y491',
|
||||
] and similarity > 0.1:
|
||||
return True
|
||||
# Luofu_Cloudford_F1_X283Y865 and its equivalents
|
||||
# INFO 21:27:00.816 │ Best 3 nearby predictions: [
|
||||
# ('Combat_Herta_SupplyZone_F2_X45Y369', 0.184, (41.0, 369.1)),
|
||||
# ('Combat_Luofu_Cloudford_F1_X281Y873', 0.149, (281.8, 869.6)),
|
||||
# ('Combat_Luofu_Cloudford_F1_X283Y865', 0.149, (281.8, 869.6))]
|
||||
if route.name in ['Combat_Luofu_Cloudford_F1_X283Y865', 'Occurrence_Luofu_Cloudford_F1_X283Y865'] \
|
||||
and similarity > 0.05:
|
||||
# INFO | Best 3 predictions: [('Combat_Herta_SupplyZone_F2_X45Y369', 0.149, (43.4, 369.3)),
|
||||
# ('Combat_Luofu_Cloudford_F1_X241Y947', 0.138, (198.6, 956.8)),
|
||||
# ('Combat_Luofu_Cloudford_F1Rogue_X59Y405', 0.134, (81.0, 397.4))]
|
||||
if route.name in [
|
||||
'Combat_Luofu_Cloudford_F1_X283Y865',
|
||||
'Occurrence_Luofu_Cloudford_F1_X283Y865',
|
||||
'Combat_Luofu_Cloudford_F1_X281Y873',
|
||||
'Occurrence_Luofu_Cloudford_F1_X281Y873',
|
||||
] and similarity > 0.05:
|
||||
return True
|
||||
return False
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user