Archived
3
0
Fork 1

docs: update vehiclesplus-v3/customization/vehiclemodel

This commit is contained in:
Stijn Bannink 2023-01-25 19:43:45 +00:00 committed by Stijn Bannink
parent c62e6c9fdc
commit 5d7e8af925

View file

@ -2,7 +2,7 @@
title: Creating a VehicleModel
description: This page describes how to create a custom VehicleModel
published: true
date: 2023-01-25T19:37:41.129Z
date: 2023-01-25T19:43:44.275Z
tags:
editor: markdown
dateCreated: 2023-01-25T19:35:38.907Z
@ -42,7 +42,7 @@ Now start changing the configuration based on your preferences. The following co
//If true, players can sit in the non-drive seats without the ride permission
sitWithoutRidePermission: true
}
//Contains all the RGB colors available for this model in the shop
//Contains all the RGB colors available for this model in the shop
availableColors:
[
{
@ -71,7 +71,7 @@ Now start changing the configuration based on your preferences. The following co
blue: 192
}
]
//A list of all the parts for this model
//A list of all the parts for this model
parts:
[
//The skin part is the main chasis of the vehicle
@ -99,7 +99,7 @@ Now start changing the configuration based on your preferences. The following co
}
}
}
//Now 4 seat parts follow
//Now 4 seat parts follow
{
type: seat
//Check out the description at the skin part
@ -130,7 +130,7 @@ Now start changing the configuration based on your preferences. The following co
zoffset: -0.45
steer: false
}
//Now 4 wheels follow
//Now 4 wheels follow
{
type: wheel
//Check out the description at the skin part
@ -146,10 +146,10 @@ Now start changing the configuration based on your preferences. The following co
green: 128
blue: 128
}
//If true, the wheel will move left/right when the driver steers left/right
//If true, the wheel will move left/right when the driver steers left/right
steering: true
//The offset (degrees) the wheel will rotate when steering
//180 degrees means 90 degrees left and 90 degrees right
//The offset (degrees) the wheel will rotate when steering
//180 degrees means 90 degrees left and 90 degrees right
rotationOffset: 180
}
{
@ -198,9 +198,9 @@ Now start changing the configuration based on your preferences. The following co
rotationOffset: 180
}
]
//The max speed of this model
//The default max speed is 100 km/h. A player pays 1000 per 5 added to that.
//The maximum max speed which can be upgraded to is 200 km/h.
//The max speed of this model
//The default max speed is 100 km/h. A player pays 1000 per 5 added to that.
//The maximum max speed which can be upgraded to is 200 km/h.
maxSpeed:
{
//The base setting is the default after this vehicle is bought
@ -212,8 +212,8 @@ Now start changing the configuration based on your preferences. The following co
//The price the player pays per step
stepCost: 1000
}
//The fuel tank of this model
//Check out the maxSpeed setting for more info
//The fuel tank of this model
//Check out the maxSpeed setting for more info
fuelTank:
{
base: 50
@ -221,8 +221,8 @@ Now start changing the configuration based on your preferences. The following co
step: 5
stepCost: 1000
}
//The turning radius of this model
//Check out the maxSpeed setting for more info
//The turning radius of this model
//Check out the maxSpeed setting for more info
turningRadius:
{
base: 7
@ -230,8 +230,8 @@ Now start changing the configuration based on your preferences. The following co
step: 1
stepCost: 1000
}
//The acceleration of this model
//Check out the maxSpeed setting for more info
//The acceleration of this model
//Check out the maxSpeed setting for more info
acceleration:
{
base: 50
@ -239,7 +239,7 @@ Now start changing the configuration based on your preferences. The following co
step: 5
stepCost: 1000
}
//Sizing of the hitbox of this model
//Sizing of the hitbox of this model
hitbox:
{
//Length is front to back
@ -249,7 +249,7 @@ Now start changing the configuration based on your preferences. The following co
//Height is bottom to top
height: 1
}
//The fuel to be used to refuel this vehicle
//The fuel to be used to refuel this vehicle
fuel:
{
//The type of fuel which has to be used
@ -259,7 +259,7 @@ Now start changing the configuration based on your preferences. The following co
//-> 60 / 100 * 6 / 1000 * 20 = 0.072 liter is used per second you drive the same speed
usage: 6
}
//The exhaust of this model
//The exhaust of this model
exhaust:
{
//If true, the exhaust particle will be shown
@ -272,7 +272,7 @@ Now start changing the configuration based on your preferences. The following co
xoffset: -5
yoffset: 0
}
//The horn for this model
//The horn for this model
horn:
{
//If true, the horn will be sounded when space is pressed
@ -281,8 +281,8 @@ Now start changing the configuration based on your preferences. The following co
//Check out https://www.digminecraft.com/lists/sound_list_pc.php for a full list
sound: block.note_block.bass
}
//The sounds used for this model
//Check out https://www.digminecraft.com/lists/sound_list_pc.php for a full list
//The sounds used for this model
//Check out https://www.digminecraft.com/lists/sound_list_pc.php for a full list
sounds:
{
//This sound is played when the vehicle stands still
@ -296,25 +296,25 @@ Now start changing the configuration based on your preferences. The following co
//This sound is played when the vehicle is started (player enters a driver seat)
start:
{
//Check out the description for the idle sound
//Check out the description for the idle sound
sound: car.start
duration: 2
}
//This sound is played when the vehicle accelerates
//This sound is played when the vehicle accelerates
accelerate:
{
//Check out the description for the idle sound
sound: car.accelerate
duration: 2
}
//This sound is played when the vehicle is driven
//This sound is played when the vehicle is driven
driving:
{
//Check out the description for the idle sound
sound: car.driving
duration: 2
}
//This sound is played when the vehicle is slowing down
//This sound is played when the vehicle is slowing down
slowingDown:
{
//Check out the description for the idle sound
@ -322,15 +322,15 @@ Now start changing the configuration based on your preferences. The following co
duration: 2
}
}
//If true, steering will feel more realistic (no instant movement)
//If true, steering will feel more realistic (no instant movement)
realisticSteering: false
//The size of the trunk (blocks)
//The size of the trunk (blocks)
trunkSize: 27
//If true, the vehicle will drift when space is pressed
//If true, the vehicle will drift when space is pressed
drift: true
//If true, players can exit while the vehicle is moving
//If true, players can exit while the vehicle is moving
exitWhileMoving: true
//The health this vehicle has
//The health this vehicle has
health: 100
}
```
@ -344,19 +344,19 @@ item:
//For a full list, see https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Material.html
material: LEATHER_BOOTS
//The damage to apply to the item
damage: 1
damage: 1
//If true, the item will be unbreakable
unbreakable: true
unbreakable: true
//The custom model data to apply to the item
custommodeldata: 1
//The player for the skull (only applicable if the material is PLAYER_HEAD)
skull: SBDeveloper
//The RGB colors to apply to the item (only applicable for leather armor)
color:
{
red: 255
green: 255
blue: 255
}
color:
{
red: 255
green: 255
blue: 255
}
}
```