Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ol.Sprite.move() make misstakes when the direction is due east/ west/south #12

Closed
PongChen opened this issue Mar 18, 2021 · 3 comments
Closed
Labels

Comments

@PongChen
Copy link

https://viglino.github.io/ol-games/examples/map.sprite.path.html

replace the path with
// 向上
var path2 = new ol.geom.LineString([
[265500, 6270000],[265500, 6280000],[265500, 6285000],[265500, 6290000],[265500, 6295000],[265500, 6300000],

]);
// 向下
var path = new ol.geom.LineString([
[265500, 6300000],[265500, 6295000],[265500, 6290000],[265500, 6285000],[265500, 6280000],[265500, 6270000],

]);
as you can see theirs difference

@Viglino
Copy link
Owner

Viglino commented Mar 18, 2021

I fix the issue in the last commit when path has vertical or horizontal segments.

@PongChen
Copy link
Author

I fix the issue in the last commit when path has vertical or horizontal segments.

Awesome!
little does one think you solve it so soon ,have a good day thanks

@Viglino
Copy link
Owner

Viglino commented Mar 19, 2021

Most difficult is to find the bugs...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants