Convertible Roofs - user-grinch/ModelExtras GitHub Wiki

Available from ModelExtras v2.1+

🏎️ Convertible Roof Animation

RoofFx introduces support for animated convertible roofs, allowing multiple roof panels to rotate smoothly during open/close transitions. Perfect for showcasing realistic convertible mechanics in your vehicle models.

🎮 Key Controls & Gameplay

  • 🚗 T (RoofToggleKey): Manually toggle open/close roof animation.
  • 🌧️ Automatic Rain Detection: Vehicle roofs will automatically close when it starts raining (RAINY weather) to protect the interior.

🔧 Dummy Naming Convention

To define convertible roof components, name your dummies using the following format:

x_convertible_roof, x_convertible_roof2, x_convertible_roof3, ...

Also optional boot dummies (trucks that hide the roofs) can be added

x_convertible_boot, x_convertible_boot2, x_convertible_boot3, ...

🛠️ Use a JSONC file (JSON with Comments) to configure the Convertible Roofs.

📂 File Location & Structure

📌 Path: ModelExtras/data/<FILENAME>.jsonc or modloader/AnyFolder/<FILENAME>.jsonc

Both model ID and model name are valid FILENAME (e.g. 602.jsonc or alpha.jsonc).
💡Tip: It is recommended to use model names instead of model IDs to avoid conflicts with other mods — especially when using added vehicles.

⚠️​ Attention:

Every JSONC configuration requires a metadata specification before any other settings. See here: METADATA

➡️​ Configuration Example
Customize each roof element with rotation and speed parameters using the following JSON structure:

"roofs": {
  "x_convertible_boot": {
    "rotation": 60,
    "speed": 2.0
  },
  "x_convertible_roof": {
    "rotation": 60,
    "speed": 2.0
  },
  "x_convertible_roof2": {
    "rotation": -60,
    "speed": 2.0
  },
  "x_convertible_roof3": {
    "rotation": 175,
    "speed": 2.0
  }
}

🎨 Parameters Explained

  • rotation: Angle (in degrees) the dummy will rotate (in X axis) during the roof animation
  • speed: Rate of rotation (higher values = faster animation)

⚙️ INI Configuration (ModelExtras.ini)

[FEATURES]
; Enable animated vehicle rooftops
ConvertibleRoof = True

[KEYS]
; Default key is T (0x54)
RoofToggleKey = 0x54

🚘 Example Vehicle

See a working example: 🔗 Convertible Roof Demo Vehicle

⚠️ **GitHub.com Fallback** ⚠️