Open Goutte opened 10 months ago
I want to work on this . Can you guide me ?
AnimatedCollisionShape2D
self-explanatory and expressive
Of note:
- The Node should probably not end in
2D
, since it is not a Node2D.- Yet it should not collide with 3D either, in the best of cases.
I think, it is better if we focus on 2D. Let other addon take over the 3D stuff. This way, the addon can be specialized, making it the best in its space.
I have these arguments
And this is your statement:
Preferably in C++.
May I ask the reason behind migrating GDScript to C++?
Thanks for the input, @HanzCEO !
I agree we should focus on 2D
.
I guess we can perhaps get away with using 2D
as suffix for our simple Node
. It bothers me a little, but you're right ; expressiveness is more important.
I mentioned it for AnimatedShape2D
, which could be its own thing (a Resource
, extending Shape2D
, overriding things), not unlike AnimatedTexture
. (I don't plan on making that, i just don't want to collide with it)
I don't plan either on writing this plugin in C++ in the near future, if only because of HTML5 support of GdExtensions.
Besides, we don't do a lot of arithmetic yet in this plugin.
That's because interpolation is not yet supported for convex and concave shapes. When we'll want to support interpolation for these shapes, we'll have to do a lot more computation.
I'm not especially happy about how we interpolate right now, code-wise. It works for simple shapes, but the code is super verbose, does not work cross-shapes and neither for convex and concave shapes.
That's why C++ was not far away from my mind.
I use this addon for hitboxes (convex shapes, replaced), solidboxes (rects, interpolated), hurtboxes (rects, interpolated), and metaboxes (rect, replaced, no default) of multiple characters and projectiles and I've noticed no performance issues.
A object worthy of the name
AnimatedShape2D
should extend Shape2D. Preferably in C++. Doing its own thing, by the way, probably.Let's not collide with that.
This addon provides a simple
Node
that couples anAnimatedSprite2D
and aCollisionShape2D
, using a database.Ideas
Of note:
2D
, since it is not a Node2D.I'll let this sit for a while. (until v2)
Then we'll vote on the fedi. Probably using Majority Judgment.