diff options
| author | Thomas Grothe <grothe.tr@gmail.com> | 2026-06-22 22:13:11 -0400 |
|---|---|---|
| committer | Thomas Grothe <grothe.tr@gmail.com> | 2026-06-22 22:13:11 -0400 |
| commit | 9f299543778b3885d3b5b97f54e145aabb18056e (patch) | |
| tree | 02884451fc6708621856a059147c741a34afe6ce /AutoCollisionShape.cs | |
| parent | 27aec4dcc347070422bb77adf71c802008278756 (diff) | |
Diffstat (limited to 'AutoCollisionShape.cs')
| -rw-r--r-- | AutoCollisionShape.cs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/AutoCollisionShape.cs b/AutoCollisionShape.cs new file mode 100644 index 0000000..62031b8 --- /dev/null +++ b/AutoCollisionShape.cs @@ -0,0 +1,15 @@ +using Godot; +using System; + +public partial class AutoCollisionShape : MeshInstance3D +{ + public override void _Ready() + { + base._Ready(); + var collisionShape = new CollisionShape3D(); + collisionShape.Shape = new BoxShape3D(); + collisionShape.Scale = Scale; + collisionShape.Transform = Transform; + AddChild(collisionShape); + } +} |
