jesuisse / godot-radial-menu-control

Provides a radial menu control
Other
38 stars 9 forks source link

Fixed "_get_color" and "_get_constant" function calls #2

Closed JustMindfulYT closed 10 months ago

JustMindfulYT commented 10 months ago

What happend?

The "_get_color" and "_get_constant" function calls could not get the Theme Property, as a Theme Property cannot have spaces in the name, i removed the spaces and tested it using a custom theme ( just for testing ) that has the Propertys the functions ask for but now i am getting an error from "drawing_library.gd" when hovering over an item.

The Error

E 0:00:03.529   canvas_item_add_polygon: Invalid polygon data, triangulation failed.
  <C++ Error>   Condition "indices.empty()" is true.
  <C++ Source>  servers/visual/visual_server_canvas.cpp:768 @ canvas_item_add_polygon()
  <Stack Trace> drawing_library.gd:123 @ draw_ring_segment()
                RadialMenu.gd:285 @ _draw()

I dont have a solution to fix that error for now, but i am searching for one.

The Theme :

image_2023-12-06_165914976 image

The Theme in the Inspector :

image

JustMindfulYT commented 10 months ago

@jesuisse @nwroyer are you looking to continue this really nice plugin? if not, i would continue it, because i just love the plugin. I hope that you will reply.

jesuisse commented 10 months ago

Hi Mindful

Thanks for your patch. I'm in the process of updating the code so it works with Godot 4, but it's a very low priority project right now. So yes, I'm still working on this. However, you are more than welcome to help develop it further. Concerning your pull request/bug report, I'm assuming something goes wrong with the values that are used to calculate the ring segment coordinates in line 284 (which are then used to calculate an invalid polygon), but I can't reproduce the error. Can you provide a minimal test case so I can look at it? BTW, there's a space remaining in your space-removing patch, line 563 :-) Could you fix it and redo the pull request with the fixed patch?

nwroyer commented 10 months ago

@jesuisse @nwroyer are you looking to continue this really nice plugin? if not, i would continue it, because i just love the plugin. I hope that you will reply.

While I'm not the original author of this, I, too, found this addon incredibly helpful! In a Godot 4 project currently, I've rolled my own radial menu after falling in love with the concepts from @jesuisse's work here. Not a fork, but heavily inspired in terms of the interface for the end user. I'll clean it up and release it, with attribution, this month.

JustMindfulYT commented 10 months ago

Hi Mindful

Thanks for your patch. I'm in the process of updating the code so it works with Godot 4, but it's a very low priority project right now. So yes, I'm still working on this. However, you are more than welcome to help develop it further. Concerning your pull request/bug report, I'm assuming something goes wrong with the values that are used to calculate the ring segment coordinates in line 284 (which are then used to calculate an invalid polygon), but I can't reproduce the error. Can you provide a minimal test case so I can look at it? BTW, there's a space remaining in your space-removing patch, line 563 :-) Could you fix it and redo the pull request with the fixed patch?

Okay, i can make a test case but that could take a while (maybe until next monday), as i dont have a lot of time right now. I removed the space now. By the way i am using godot 3.5.3 and GLES3. I hope that helped.