Skip to content

Rollback Bed (for Vehicles)

Caner Karaca edited this page Aug 16, 2026 · 1 revision

Available from ModelExtras v2.1+

🛻 Rollback Bed (Flatbed Tow Truck System)

The Rollback Bed feature transforms flatbed recovery trucks into fully functional car haulers (e.g. SLAMVAN, FLATBED, PACKER, DFT-30). It realistically animates both the tilting flatbed platform and the extending hydraulic piston assembly.


🧩 Supported Node Names

Node Name Type Description
x_rb_bed Frame / Mesh The main flatbed ramp platform. Tilts downward to meet the ground.
x_rb_hydraulics Frame / Mesh The base hydraulic cylinder housing (shell). Rotates on its chassis hinge as the bed tilts.
x_rb_hydraulic_1
x_rb_hydraulic_2
x_rb_hydraulic_X
Frame / Mesh The internal telescoping piston rod(s). Slides outward along its local Z-axis when deployed.

🏗️ 3D Model Hierarchy Example

chassis
 ├── x_rb_bed               <-- Flatbed Platform (Tilts on rear pivot)
 ├── x_rb_hydraulics        <-- Lower Hydraulic Cylinder Base (Hinged to chassis)
 │    ├── x_rb_hydraulic_1  <-- First Stage Piston Rod (Slides along local Z-axis)
 │    └── x_rb_hydraulic_2  <-- Second Stage Piston Rod (Optional telescopic stage)

📌 Important Modeling Guidelines:

  1. Piston Axis Orientation: The piston rods (x_rb_hydraulic_X) translate along their local Z-axis (pos.z). Align the local Z-axis of the piston frame in the direction of extension.
  2. Pivot Placement: Set the pivot of x_rb_bed at the rear chassis hinge point around which the bed tilts.
  3. Collision (.col): Attach the flatbed collision mesh directly inside the x_rb_bed frame so vehicles can physically drive onto the ramp when tilted.

🛠️ JSONC Configuration (ModelExtras/data/<model_id_or_name>.jsonc)

Create or edit your vehicle's JSONC file (e.g., ModelExtras/data/455.jsonc for Flatbed):

{
    "rollback_bed": {
        "bed": {
            "target_rot": 12.0,       // Tilt angle in degrees for the bed (x_rb_bed)
            "rot_speed": 1.0          // Rotation speed multiplier for the bed
        },
        "hydraulics": {
            "target_rot": 18.0,       // Tilt angle in degrees for hydraulic housing (x_rb_hydraulics)
            "rot_speed": 1.0,         // Rotation speed multiplier for hydraulic housing
            "target_move": 2.5,       // Maximum extension distance in meters (x_rb_hydraulic_X)
            "move_speed": 1.0         // Linear extension speed multiplier for pistons
        }
    }
}

🎨 Parameters Explained

🔹 "bed" Section

  • target_rot (float): The target downward tilt angle (in degrees) when fully deployed.
  • rot_speed (float, default: 1.0): Speed of the bed tilting animation.

🔹 "hydraulics" Section

  • target_rot (float): The target rotation angle for the lower hydraulic housing cylinder.
  • rot_speed (float, default: 1.0): Speed of the hydraulic housing rotation.
  • target_move (float, default: 2.0): Maximum travel distance (in game meters) the piston rods slide outward along the Z-axis.
  • move_speed (float, default: 1.0): Linear expansion and retraction speed of the pistons.

💡 Default Behavior (Without JSONC): If no .jsonc file is created for the vehicle, the feature still functions automatically with default values (target_move: 2.0, move_speed: 1.0). All frames matching x_rb_hydraulic_* will extend by 2 meters along their local Z-axis.


🎮 In-Game Controls & Keybindings

  • Default Toggle Key: K (Press once to deploy the bed, press again to retract).
  • Sound Effect: Automatically plays realistic hydraulic switch audio (AudioMgr::PlaySwitchSound).
  • Custom Keybind: Change the toggle key in ModelExtras.ini under the [KEYS] section:
[KEYS]
; Virtual-Key code for toggling Rollback Bed (Default 0x4B / 75 = 'K' key)
RollbackBedToggleKey = 0x4B

Clone this wiki locally