Tow — Feature Overview
A FiveM tow truck resource with keybind and command support. Walk up to the rear of a tow truck, attach nearby vehicles, and detach them on demand. Supports standard tow trucks and flatbeds with realistic attach behaviour. ACE-based permissions.
Video Preview
Overview
Tow & detach: Attach a nearby vehicle to the closest tow truck, or detach the currently towed vehicle — all from on foot near the rear of the truck.
Keybind: Press B (rebindable) when standing behind a tow truck to tow or detach. HUD text shows the available action.
Commands:
/towand/detachas chat commands for quick use or scripting; same ACE permission as the keybind.Multiple truck types: Supports TowTruck, TowTruck2, and Flatbed. Each uses the correct native attach method (hook-based for tow trucks, entity attach for flatbeds).
Permissions: ACE-based. Grant
command.towortowto allow towing.Optimized: Single tick loop with early exits; no polling or heavy processing when the player is not near a tow truck.
Permissions (ACE)
Grant via your server's server.cfg or a permissions resource (e.g. ace permissions, esx, QBCore).
A single permission node controls all tow functionality — the /tow command, /detach command, and the B keybind. Players without the permission cannot interact with tow trucks at all.
Permission Node
Description
command.tow
Allows /tow, /detach, and the B keybind
tow
Alternative node; either grants access
Example (server.cfg):
add_ace group.tow command.tow allow
add_principal identifier.license:xxx group.tow
# Or use the short node
add_ace group.tow tow allowCommands
All commands are server-side and permission-checked.
Command
Permission
Usage
Description
tow
command.tow or tow
/tow
Tow or detach a vehicle (same logic as the keybind)
detach
command.tow or tow
/detach
Detach the currently towed vehicle from the nearest tow truck
Keybind
Key
Action
Condition
B (default, rebindable)
Tow or detach vehicle
Player must have tow permission and be on foot
Tow when standing near the rear of a tow truck with no vehicle attached and a towable vehicle nearby.
Detach when standing near the rear of a tow truck that already has a vehicle attached.
No effect when the player is in a vehicle.
HUD prompts appear when an action is available:
~y~[B]~s~ Tow Vehicle~y~[B]~s~ Detach Vehicle
Supported Tow Trucks
Vehicle
Behaviour
TowTruck
Hook-based towing via AttachVehicleToTowTruck. Hook position calculated from target vehicle's model dimensions.
TowTruck2
Same hook-based behaviour as TowTruck.
Flatbed
Entity-attach towing via AttachEntityToEntity at a fixed bed offset. Towed vehicle is frozen during transport.
Tow Mechanics
Proximity detection
The resource searches for tow trucks within 10 m of the player.
The player must be within 3 m of the tow truck's rear to perform any action.
Towable vehicles are searched within 8 m of the player.
Tow eligibility
A vehicle can be towed only if:
It is within the target radius (8 m).
All seats are empty (driver and all passengers).
It is not already attached to the tow truck.
It is not itself a tow truck.
Attach
TowTruck / TowTruck2: Uses
AttachVehicleToTowTruckwith hook Y and Z calculated fromGetModelDimensionsof the target vehicle.Flatbed: Positions the vehicle at a fixed offset on the bed (
0.0, -2.5, 0.9), freezes it, and attaches withAttachEntityToEntity.
Detach
The towed vehicle is placed 10 m behind the tow truck.
The vehicle's heading is set to match the tow truck's heading.
PlaceObjectOnGroundProperlyis called to ensure correct ground placement.Flatbed vehicles are unfrozen on detach.
Notifications and Feedback
HUD text: On-screen prompt (
~y~[B]~s~ Tow Vehicleor~y~[B]~s~ Detach Vehicle) when the player can act.Notifications:
~y~[TOW]~s~feed notifications for tow/detach actions via the keybind.Chat:
^3[TOW]^7chat messages for/towand/detachcommand results.Permission denied:
^1[TOW]^7 You do not have permission to tow/detachin chat.
Summary
Tow & detach: Attach and detach vehicles with a keybind or chat commands.
Realistic behaviour: Hook-based towing for standard trucks; entity attach for flatbeds with freeze during transport.
HUD prompts: On-screen text when an action is available near a tow truck.
ACE permissions: Single permission node controls all tow functionality.
Lightweight: Minimal tick usage with early exits; no overhead when the player is away from tow trucks.
A simple, focused tow resource for servers that need reliable vehicle towing without framework dependencies.