Every model in a 3D room can have a collision shape, saved in its creation code where Room 3D's kit uses it in the game: walls and crates stop the player, it walks up steps and ramps, a sword's hit finds the enemy. Select a model: the inspector's Collision section shows its shape. A model placed from the sidebar starts with the collision its source gives it, and scenery with none (see Placing models).
- Shape: None, Box, Sphere, Capsule (upright: characters) or Mesh (the model's own triangles: ramps, stairs, rocks, a whole level piece; simplified to 4,000 triangles at most). Picking one fits it to the model. Room > 3D View > Collision > Next Shape (⌃⌥K, or ⌥K in the view) steps through them.
- Size and Offset (metres, x, y and z up, before the thing's size): a box's width, depth and height; a sphere's diameter (x); a capsule's diameter (x) and height end to end (z). The offset is where its middle is from the thing's origin.
- Solid: on, it's level geometry (a wall, a floor, a crate) that movers can't pass through; off, it's an actor (the player, an enemy, a pickup), found by collision checks but not in the way.
- Group: a word (enemy, pickup…) GameMaker's collision checks can look for.
- Fit (⌃⌥F, or ⇧K in the view): fits the shape to the model again: round the trunk of a tree, a lamp post or a signpost, else round the whole model. Fit to Base (⌃⌥⇧K, or ⌥⇧K): an upright capsule (a box for a square post) round the trunk or post at the model's foot, as tall as the model, so the player walks under the branches. Fit to Whole Model (⌃⌥⌘K): round the whole model.
- Room > 3D View > Show Collision Shapes (⌃⇧K, or K in the view): every shape drawn over the room, solid ones orange, movers blue, the selected one brighter.
A model placed in a room gets its shape as Room 3D gives one: a character (a model with a skeleton) an upright capsule, not solid; a tall model on a narrow base a capsule or box round its trunk, solid; anything else a box, solid (a flat floor a slab 10 cm thick under its top).
The shapes are worked out with Room 3D's own sums on the saved model, and written as Room 3D writes them: col_shape, col_size, col_offset (GameMaker units), col_solid, col_group, after thing_name. A Mesh shape saves the model's collision triangles once, in datafiles/room3d/<model>/collision.bin (named in its model.json, listed in the project's included files). Each change is one undo step.
Related topics
Keys are shown as on the Mac: ⌘ Command, ⌥ Option, ⌃ Control, ⇧ Shift. Studio for Windows shows its own keys beside each menu item.