Skip to content

Moving parts

For creatorsAdd-on 2.2.3+

A moving part is a piece of an item or a vehicle that moves on its own: a pistol’s slide, a trigger, a phone’s lid, a car’s door. Make Moving Part sets one up from a preset. Make Item Clip then keys a clip on the parts, such as a gun firing or reloading. In play, a held gun plays its own fire and reload clips, a carried item plays its use clip, and a car’s door swings as you get in.

The tools are in Properties ▸ Object ▸ Simulacrum: in the Make menu at the top, and in the Item panel, which shows for a hand item, its pieces and its grips. For a vehicle, the Item panel shows when you select a piece of its body that could move, such as a door or a hood, and Vehicle ▸ Parts has the same tools.

  1. Make the item an item first with Make Hand Item (see Hand items), or a car a vehicle with Make Vehicle (see Make a vehicle).
  2. Parent each part to it. A part can sit at any depth under the item or the vehicle.
  3. Pose each part at rest: the slide forward, the lid shut, the door closed. The pose a part is in when you press the button becomes its rest.
  4. Set each part’s origin where it turns: a trigger’s on its pin, a lid’s on its hinge. Doors, hoods and trunks are done for you (see Hinges).
  5. Select the parts. Open Make ▸ Make Moving Part, or the Make Moving Part button in the Item panel, and choose a kind.

The Item panel then names the parts under Moving parts. Select one part and the panel shows what it is, with its Moves by, Axis, From and To.

Menu entry Moves How far What it is
Slide Along its Y 3 cm A pistol’s slide, back along the barrel
Bolt Along its Y 7 cm A rifle’s bolt, back
Trigger Turns about its X 20° Pulled
Hammer Turns about its X −50° Cocked back
Magazine Along its Z −15 cm Out, down the grip
Door Turns about its Z 65° Swung open on its front edge
Hood Turns about its X 60° Up on its rear edge
Trunk Turns about its X −70° Up on its front edge
Lid Turns about its X −110° A flip phone or a box, open
Lever Turns about its X 35° Pulled
Button Along its Z −3 mm Pressed
Spin Turns about its Y 360° A reel or a wheel, turned round once
Part Turns about its X 45° Any other part, turned

The axes are the part’s own. The signs expect a gun made pointing −Y with up +Z, and a car whose front is the way Make Vehicle’s Front says (−Y unless you changed it). If a part moves the wrong way, change its tags (below) and make its clip again.

With Pivot at its hinge on (the default), a door, a hood or a trunk has its origin moved to its hinge. The mesh stays where it is.

  • A door turns on its front edge, on its outer skin.
  • A hood turns on its rear edge, at its top.
  • A trunk turns on its front edge, at its top.

On a vehicle, the add-on also works out which of the part’s axes to turn about and which way, so a door swings out from the cabin and a hood or trunk swings up. It names each door by where it sits on the car:

Where the door sits vehicle.door
Front, the car’s left driver
Front, the car’s right passenger
Rear left rear.L
Rear right rear.R

Each part’s values are ordinary custom properties. Edit them to fit, then make the clip again.

Tag Values What it does
osmx.param.drive rotate · translate Whether the part turns or slides
osmx.param.axis x · y · z The part’s own axis it moves along or about
osmx.param.min · osmx.param.max Degrees or metres How far it can move
part.open Degrees or metres Where it moves to when it opens or fires. Clips are keyed from this
part.kind A kind from the menu Which clips move it
vehicle.door driver · passenger · rear.L · rear.R Which door of the car it is

Once an item has a moving part, the Item panel shows the Make Item Clip menu. It is in the Make menu too.

  1. Select the item or one of its parts.
  2. Open Make Item Clip and choose a clip.

The clip plays at once. A button for each clip you made (Fire, Reload and so on) appears under it and plays it again. Stop, beside them, puts every part back at rest.

Clip Parts it moves Length
Fire The trigger is pulled by frame 3 and back by frame 9. The hammer goes back and falls. The slide or bolt goes back by frame 5 and home by frame 9 10 frames
Reload The magazine is out by frame 12, held, and home by frame 40. Then the slide or bolt is racked, frames 44 to 52 54 frames
Open Doors, hoods, trunks, lids and levers go from rest to open over 19 frames 20 frames
Close The same parts, from open back to rest 20 frames
Use A spin part turns once round. Every other part goes out by frame 8, holds, and is back by frame 20 21 frames

All clips run at 30 frames a second. Each is an ordinary action named <item>.<clip>, such as Pistol.fire, with a slot for each part it moves. Edit it like any action.

  • A held gun plays its own Fire clip with every shot. Signed in to MegaCity, R reloads, and the gun plays its own Reload clip along with the body’s. See Weapons.
  • A carried item plays its Use clip when the player presses fire, at most once every 0.6 s. See Hand items.
  • A car’s doors. Getting in at the wheel swings the driver’s door open; taking the passenger seat swings the passenger’s. Getting out swings the driver’s door. A door opens over 0.45 s, stays open 0.55 s and shuts over 0.45 s. In a shared scene, everyone sees it swing. If no door is tagged driver, the first tagged door stands in for it.

To try it, play ▶ the items lab. Stand clear of the car and the table and press F: the pistol’s slide kicks back and returns. Walk to the blue car and press E: the driver’s door swings open and shuts behind you.

A door in a building (not on a vehicle) opens when a player or a person uses it. Animate it in Blender and it plays that animation in your scene (add-on 2.2.3):

  1. Model the door as its own object and put its origin on its hinge (Make ▸ Make Moving Part ▸ Door does this for you).
  2. Keyframe it opening: shut on the first frame, open on the last. Key the door itself, not an Empty it hangs from.
  3. Choose Make ▸ Make Door. Its Clip is your animation; keep Blocks the Way When Shut on for a door people walk through.
  4. Build or Play. Pressing E by the door plays your animation to open it and plays it back to shut it. A shut door blocks the way across its own width and height.

A door starts shut whatever frame the timeline is on. A handle parented to the door swings with it.

  • A door plays only its own keyframes. Motion from constraints, drivers or the NLA isn’t carried, and a door that swings because an Empty it hangs from is animated doesn’t open. Key the door itself.
  • Rear doors, hoods and trunks do not open in play yet. They are tagged, and their clips play in Blender, but the viewer swings only the front doors.
  • Nothing plays Open and Close clips in play yet. They export with the item.
  • Make Hand Item or Make Vehicle first. A part must sit under an item or a vehicle, or Make Moving Part stops with is not a child of an item (Make Hand Item) or a vehicle (Make Vehicle).
  • Pose it at rest first. A part made half open rests half open.
  • The origin is the pivot. Only doors, hoods and trunks get their origin moved for you.
  • The presets expect a gun pointing −Y. Made another way, a slide moves forward. Fix its osmx.param.axis, osmx.param.min, osmx.param.max and part.open, then make the clip again.
  • A clip with nothing to move is an error. Fire moves only triggers, hammers, slides and bolts. Reload moves only magazines, slides and bolts. Open and Close move only doors, hoods, trunks, lids and levers.
  • Making a clip again replaces it. Your hand edits to Pistol.fire are lost when you make Fire again. Making or playing a clip also sets the scene’s frame range to the clip’s.

The tutorial Items: moving parts builds a pistol, a car door and a flip phone step by step.