func_vehicle

A func_vehicle is a vehicle from Counter-Strike that a player steers with their move keys. A
func_vehiclecontrols brush marks where the driver stands, and a player inside that space
takes the wheel with their use key.
After three bounces in a row against a wall, the vehicle stops instead of bouncing back again.
Attributes
The entity also has these common keys:
- Position: Pitch Yaw Roll
- Appearance: Render FX, Render Mode, FX Amount and FX Color
- Compiler keys of brush entities: all of them
targetnameGives the vehicle a name that other entities can use to find it. See Common keys.
targetNames the path_track the vehicle starts on. When the map starts, it is placed there, Height above track higher, facing the next path_track.
soundsPicks the engine sound the vehicle plays while it moves, which goes up in pitch with the speed.
- Vehicle 1 (1)
- Vehicle 2 (2)
- Vehicle 3 (3)
- Vehicle 4 (4)
- Vehicle 6 (5)
- Vehicle 7 (6)
Vehicle 3 (3)lengthSets the length of the vehicle in units, front to back, which sets where it checks for walls and what it runs over.
256widthSets the width of the vehicle in units, which sets where it checks for walls and what it runs over.
128heightSets how many units above the first path_track the origin of the vehicle is placed. The vehicle also looks this far plus 48 units down for the ground it tilts with.
4startspeedSets the speed the vehicle has when the map starts, in units per second, and 0 means it stands still.
0speedSets the top speed forward, in units per second, and 0 means 165. Backwards, it reaches 0.35 times this, unless you set Custom reverse speed.
0accelerationSets how quickly the vehicle gains speed when the driver speeds up, from 1 for the slowest up to 10 for the fastest, and a value below 1 works like 1.
5dmgSets the speed, in units per second, at which something that blocks the vehicle is thrown away from it, plus 300 upward. It isn't damage, but something caught in front of, behind or beside the vehicle takes 150 crush damage.
0volumeSets how loud the engine and brake sounds are, from 1 for quiet up to 10 for full volume, and 0 means 10.
10Sets the top speed backwards, in units per second.
If you leave this key empty or set 0, it is 0.35 times Speed.
Sets how much speed the vehicle loses every 0.1 seconds while nobody presses forward or back, and 0 means 20.
0Sets whether the engine goes quiet while the vehicle stands still.
- No (0) - The engine sound keeps playing
- When stopped and no driver (1) - The engine sound stops while the vehicle stands still with nobody at the wheel, and starts again when the vehicle moves
No (0)Sets a sound that plays when the engine starts, for every Sound.
If you leave this key empty, it is plats/vehicle_brake1.wav, but only for the sounds "Vehicle 1" to "Vehicle 4".
Sets a sound that plays when a player takes the wheel.
If you leave this key empty, it is plats/vehicle_ignition.wav.
Lets the vehicle set off triggers, which a vehicle doesn't touch by itself. With a name here, a small point entity of this name rides at the origin of the vehicle and touches triggers: a trigger_multiple or a trigger_once with Everything else, and a trigger_inout or a trigger_jump with Everything else or this name in its entity filter. It is one more entity for each vehicle, removed with its vehicle.
_minlightSets the lowest light level the map compiler gives the faces of the vehicle, from 0 up to 1, so it never turns fully dark.
0Flags
1No PitchThe vehicle starts level, so its start direction ignores the height difference to the next path_track
2No User ControlPlayers can't drive the vehicle
8PassablePlayers, monsters and shots pass through the vehicle
Notes
- The sound keys and Touch proxy name are read when the map starts, so a
trigger_changevaluethat changes them later has no effect
See also
func_vehiclecontrols- the place where a player drives the vehiclefunc_tracktrain- a train that players drive along a track
Changes since 1.38
func_vehicleis new in SBO 2.0.0

