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

it is really slow to quit a scene with large amount instance nodes #18673

Closed
chenjie199234 opened this issue May 7, 2018 · 8 comments
Closed
Assignees
Milestone

Comments

@chenjie199234
Copy link

version:3.0.2

i use script to instance 30000 instance and add them to the scene.it just cost 2-3 seconds

but if i quit() the scene or queue_free() the scene it is really slow!!

the test example was uploaded

Test.zip

@Geequlim
Copy link
Contributor

Geequlim commented May 7, 2018

As the profiler show the performance is lost in the destructor of Object.

godot/core/object.cpp

Lines 1886 to 1890 in e153057

while (connections.size()) {
Connection c = connections.front()->get();
c.source->disconnect(c.signal, c.target, c.method);
}

image

@Eoin-ONeill-Yokai
Copy link
Contributor

I'm not entirely sure why the performance should be bad with disconnect since maps should be pretty efficient in terms of performance. It's worth checking this out to see if there's some way to improve performance of our disconnection.

@Geequlim
Copy link
Contributor

@chenjie199234 Why closing this issue? It is not solved yet.

@chenjie199234
Copy link
Author

chenjie199234 commented May 20, 2018

@Geequlim just closed all my issue,just disappointed,i will go back to use urho3d

@mhilbrunner
Copy link
Member

@chenjie199234 Reopening for now, feel free to ignore and have fun & success with Urho, but we still need to fix this. Thanks for reporting!

@mhilbrunner mhilbrunner reopened this May 21, 2018
@reduz reduz self-assigned this Sep 7, 2018
@reduz
Copy link
Member

reduz commented Sep 7, 2018

if you need 30k instances, using servers directly or multimesh seems like a better bet, but will give it a check anyway

@pgruenbacher
Copy link

This seems like a non-issue to me. We should just be documenting how to achieve 1000+ instances using particles, multimesh, server.

@reduz
Copy link
Member

reduz commented Nov 18, 2018

This was actually a design problem which was just fixed.

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

No branches or pull requests

7 participants