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

Eliminate binary trees #3

Closed
wokalski opened this issue Aug 24, 2015 · 5 comments
Closed

Eliminate binary trees #3

wokalski opened this issue Aug 24, 2015 · 5 comments

Comments

@wokalski
Copy link
Collaborator

@maartenschumacher Time Profiler clearly shows that binary trees are the problem in the game. Multiple conversions between trees and arrays are simply slow. I tried to solve this issue but I don't know enough about game logics to do it. Namely this and this line were too misterious for me to fix it.

@maartenschumacher
Copy link
Owner

@wczekalski You're right. It was cool to make those functions with the binary tree but this is the wrong use case. Maybe Set would be appropriate here, since we want to eliminate duplicates and have union and subtract. Or do you think Set is also gonna be slow?

@maartenschumacher
Copy link
Owner

I will also refactor those lines to make them more readable.

@wokalski
Copy link
Collaborator Author

set is the fastest one from collection types.

@wokalski
Copy link
Collaborator Author

Cool, looking forward to it.

@wokalski
Copy link
Collaborator Author

wokalski commented Sep 6, 2015

fixed in #4

@wokalski wokalski closed this as completed Sep 6, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants