don-tnowe / godot-extra-controls

MIT License
88 stars 3 forks source link

Documention or Example Project #9

Closed dalton5000 closed 2 weeks ago

dalton5000 commented 3 weeks ago

First of all thank you for your work and providing this addon. Also please excuse if this is the wrong place to ask.

I was not able to get the drag and drop nodes to work, would it be possible to add some documentation or an example project? It would be very appreciated.

don-tnowe commented 3 weeks ago

Hello. I'd like to know what was tried and what went wrong! I will take the feedback to update the tool itself and its built-in documentation (accessible via F1 key) to help.

For now, there are example*.tscn scenes in the project.

don-tnowe commented 3 weeks ago

I noticed some classes are missing in the custom type declaration. For an addon, this means auto-generated documentation will be missing.

I have updated it and pushed to the main branch.

dalton5000 commented 3 weeks ago

Thank you for the quick reply. I didn't realize there are examples in the repo, I just checked the imported plugin from the asset library. I will try to learn from the examples, if I still don't get it to work I will describe the problem here.

don-tnowe commented 3 weeks ago

Yeah, they're excluded from the download 😄 I'd still appreciate to know what you did try before checking examples.

dalton5000 commented 3 weeks ago

I created a new scene, Node2D as base. I created a Interpolated Box and Flow Container, sized them up, and put a Draggable with a TextureRect as child in both of them. When I try to move them, they move away from the cursor, get larger over distance and dont snap in correctly. I tried some options and values but didn't get it to work, likely doing it wrong.

don-tnowe commented 3 weeks ago

Ahh. I see. These are separate, incompatible features:

I will update documentation accordingly! Let me know if something else caused problems.

dalton5000 commented 3 weeks ago

Oh i see! Thanks a lot. Will keep you updated if I run into more.

dalton5000 commented 3 weeks ago

Something I can't figure out: How to limit the maximum amount of objects in a FlowContainer. I tried a condition of get_child_count()<5 but that doesn't do anything.

don-tnowe commented 3 weeks ago

Yeah, that'd be into.get_child_count() < 3 - into is the node that's being inserted to! You might've known if documentation tooltips in the Inspector worked consistently 😄

But I think I'll make the limit a separate property - limiting item count is a common feature, and the count would likely be changed often through a Script.