five-on-it / apps/level-editor/src/scripts/blocks/vehicle-spawner
apps/level-editor/src/scripts/blocks/vehicle-spawner
Marks a node of the editor scene as a vehicle spawner: a parking bay where a car stands, on the node's origin (the middle of the bay, on its floor), facing the node's +z, never scaled, turned with yaw only. Its car is of a class, or of a mix it goes through in turn (class names separated by commas: compact, sedan), owned by nobody or an NPC, locked unless locked is 0, its lock answering to a key's tag (key:vehicle:<node name> when empty); once the car is gone another stands there respawn seconds later (never with 0). The library's block:vehicle-spawner carries it: place instances of that mesh for npm run level:export to read.