MeltWS / ProShinePathfinder

A Lua script for PROShine that move your bot anywhere the world with a single line of code.
MIT License
2 stars 12 forks source link

Blocked Path | results in: Error in Path -- Reset and Recalc loop #20

Open M1L4 opened 7 years ago

M1L4 commented 7 years ago

[Problem] Pathfinder can't handle blocked path's.

[Description] I wrote a script pre-questing and wanted to go from Pewter Town to Lavender Town, pathfinder directed me to Vermilion City and attempted to cross Route 12. When entering Route 12 the algorithm realizes that Snorlax is blocking its way and loops following exception:

Pathfinder --> Error in Path: from Route 12 to Lavender Town -- Reset and Recalc

[Goal]

M1L4 commented 7 years ago

Another occasion, when subway is not unlocked:

Error in Path: from Pokecenter Viridian to Viridian City Subway -- Reset and Recalc

M1L4 commented 7 years ago

Same when having "surf"-pokemon, but relaxo blocking the way: The algorithm doesn't find a path, while you could just surf mount...

use cases:

  • trading pokemon with surf ability prior to "have to fight relaxo"-game state
  • using blissey's mutlifarm script utilizing a "passing through blocked paths" glitch

[deduction] summarizing all comments above:

  • it appears paths are in some way hard-coded, instead of being dynamically calculated

This problem is actually due to the proShine's pathfinder c# implementation - see more at #21

M1L4 commented 7 years ago

Route 22 Problem: Passing Route 22 is not possible. This happened to me on multiple occasions, when trying to get from Kanto to:

When attempted following looping (exemplarary) exception will be printed:

... [17:01:39] Path: Maps Remains: 4 Moving To: --> Pokemon League Reception Gate [17:01:39] Pathfinder --> Error in Path: from Route 22 to Pokemon League Reception Gate -- Reset and Recalc [17:01:40] Path: Route 22->Pokemon League Reception Gate->Victory Road Kanto 1F->Victory Road Kanto 2F_A->Victory Road Kanto 3F_D ...

Routing is fine, when Route 22 is selected as destiny or start node (More tests required though).