-
Notifications
You must be signed in to change notification settings - Fork 0
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
Optimize guide line algorithm #7
Comments
Another way to do it is to draw all the lines at once instead of calling |
I have changed the way the indicator path is being calculated, it now is calculated when you first change the click, and that is now stored into a list. However the guide line is still being up dated when you "end turn", which was not expected (i was thinking that the path will just stay at the original location while the ship moved along it) |
Looks like you committed to |
The performance is much better, but it's still bad. On my desktop, CPU usage went from 144% to 40%, but this is just for two lines! I think we need to come up with a few more changes to fix the problem. |
I moved the todo list from #8 to here, since #8 is "good enough" to merge for now. TODO (in no particular order):
|
The guide line algorithm is too slow; there's a noticeable FPS loss after creating a movement order to somewhere far from the ship. We should probably either cache the line (by dynamically creating and adding a node) or make the algo faster.
The text was updated successfully, but these errors were encountered: