Skip to content

The frame: VehicleLayout ​

In a pack: the layout section of vehicles/<name>.json, the fields as below (Java: new VehicleLayout.Builder(), fill it in, build()). Vehicle frame (forward, right, up) except where it says model frame.

FieldMeaning
bodythe parked collision boxes (stand on the roof, get blocked by the car): a few Boxes in the car's shape
rainShellwhat the rain stops on (RainPart: a box, optionally cut by a slanted plane; no cut: 0, 0, 1)
cabCushion cabFloorthe front cushions' top, the cab floor
seatsfirst the driver's, then the front passenger's: Seat(forward, right, cushion, yaw, look, inCab, right)
wheelX wheelY wheelZthe steering wheel's hub (model frame)
columnY columnZthe column's direction (model frame, the unit vector's Y and Z, into the dash)
rimthe steering wheel's radius
steeringRatiosteering wheel turn per road wheel turn
hingeX hingeZthe door hinge (model frame; the sides mirror)
pull outer entrythe inside pull, the outside handle, where one stands to get in
shiftPivot shiftKnobthe gear lever's pivot and the knob's middle (model frame, upright in neutral)
exitF exitRwhere one gets out
hood hoodUpwhere the hood can be clicked, shut and open
door doorSwungwhere the left door can be clicked, shut and open (the right mirrors)
filler fillNeckwhere the filler door can be clicked; the fill neck

A pickup's bed, tailgate and transfer lever (bed, tailgate, transferPivot, ...) are simply left out.

Optional (without them, worked out from the boxes and points above):

FieldMeaning
exhaust exhaustOutthe exhaust outlets (several allowed: { {forward, right, up}, ... }) and the way the gas leaves. Without: one at the rear right, blowing back
engineVisiblethe engine mesh (<name>_engine) is seen without opening anything (a mid engine's glass cover, an open bay): drawn whenever near. Without: only with the hood open
wiperY wiperZthe wipers' axis (model y, z; about the windshield's normal). Without: the T15's windshield. For a strongly curved windshield, where turning about one axis lifts the blade off: wiperPoses, {"wiper_l": [[share, dx, dy, dz, qx, qy, qz, qw], ...], "wiper_l_blade": [...], ...}, the share rising from 0 to 1, each row the bone's move and turn at that share (a quaternion, model frame, about the bone's pivot), interpolated between
pointsthe prompts', sounds' and the two picking parts' places (VehicleLayout.Points); seldom needed

The tank's size is in the physics: b.tank = 73; (litres, 60 without).

These must agree with the Empties in Blender: the steering bone goes at Blender (wheelX, −wheelZ, wheelY).