dshepsis / OkamiMap

Resource for the locations of items and other objects in the video game Okami
https://dshepsis.github.io/OkamiMap/
1 stars 1 forks source link

Distance Calculation / Polyline #15

Open dshepsis opened 3 years ago

dshepsis commented 3 years ago

It should be possible to calculate the distance between things on the map. Of course, this will be an approximation depending on how it's implemented. If you take a straight line between two treasures, it won't account for the 3D terrain between those points. But an approximation could still be useful for estimating things like travel time for a full route through an area. In fact, travel time should probably be calculated by the app using speed values determined from Cheat Engine. You could even allow users to plot a polyline between multiple places on the map so that multiple routes through an area can be compared for efficiency.

zysim commented 3 years ago

We do got these here speed values don't we now

dshepsis commented 3 years ago

We do got these here speed values don't we now

We do have some raw speed values, but movement can be kind of complicated. You start with a tackle, then green dash, then gold dash, and there's some acceleration between each. Changing direction and moving up/down hills can also have some effect, I think. Getting a rough estimate of travel time could be nice eventually, though, even if there's some error.

zysim commented 3 years ago

Yeah was looking at the values in CE while running about. Maybe we could start with set values for green and gold dash? Like say 5.6 while green and 6.9 while gold? And the time from green to gold is pretty set too. And yeah I know when moving up or downhill your speed does change though. Actually we could take the start and end point z-coordinates, do simple trigonometry there, then give your rough estimates that way, if you're okay with that.