Skip to content
This repository was archived by the owner on May 15, 2026. It is now read-only.
This repository was archived by the owner on May 15, 2026. It is now read-only.

Area3D brush creates ConcavePolygonShape3D which has issues for Areas #26

Description

@makepanic

Hi,
thanks for building this great addon.

I've noticed that when having brush with a Area3D entity, it'll generate a ConcavePolygonShape3D as the collision shape.
This is causing issues as mentioned in the docs:

Warning: Using this shape for an Area3D (via a CollisionShape3D node, created e.g. by using the Create Trimesh Collision Sibling option in the Mesh menu that appears when selecting a MeshInstance3D node) may give unexpected results: the area will only detect collisions with the triangle faces in the ConcavePolygonShape3D (and not with any "inside" of the shape, for example); moreover it will only detect all such collisions if backface_collision is true.

via https://docs.godotengine.org/en/latest/classes/class_concavepolygonshape3d.html

In my case that means I can only detect bodies which are on the edge of the brush but not inside of it. E.g. if I have a trigger brush that's a large rectangle.

I manually build the addon using ColliderShape::Convex instead of ColliderShape::Concave as collision shapes for CollisionObject3D and it fixes my issue.

I'm not sure if there are any issues which this will create. Can trenchbroom brushes create concave geometry?

If it's ok I can create a PR which changes the collider shape in https://github.com/codecat/godot-tbloader/blob/master/src/builder.cpp#L346-L350 to:

	} else if (node->is_class("CollisionObject3D")) {
		// If it's not a dynamic body, we can just use a convex trimesh collider
		need_collider = ColliderType::Mesh;
		need_collider_shape = ColliderShape::Convex;
	}

(tbh I'm not sure where exactly the code flows from the area3d brush conversion)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions