The Driver Syndicate/Vehicles/Configuration File: Difference between revisions

From Equilibrium Engine Wiki
Jump to navigation Jump to search
mNo edit summary
 
(14 intermediate revisions by 2 users not shown)
Line 6: Line 6:


===name===
===name===
Name of the vehicle, generally in <code>'XX Name</code>, where XX is the year.
Name of the vehicle, could be any name but I guess it's now preffered to name as <code>'XX Name</code>, where XX is the year.


name "'74 Rollo";
=== isCar ===
Indicates that the vehicle is a car and it does have engine. Default value is 1. Must be set to 0 if you making trailer.


===cleanmodel===
=== isCop ===
Indicates that this is a cop car.
 
=== allowParked ===
Allows this vehicle to be spawned at parking slots. Default value is 1.
 
=== allowMusic ===
Allows this vehicle to play in-car music. Default value is 1.
 
===cleanModel===
Location of the .egf model that the vehicle uses.
Location of the .egf model that the vehicle uses.


cleanmodel "models/vehicles/rollo.egf";
===damagedModel===
 
===damagedmodel===
Location of the .egf model the vehicle becomes when damaged.
Location of the .egf model the vehicle becomes when damaged.
If none is present, the vehicle won't show damage.
If none is present, the vehicle won't show damage.


===wheelmodel===
===wheelModel===
Location of the .egf model for the wheel models<br>
Location of the .egf model for the wheel models<br>
If none is present, uses "models/vehicles/wheel.egf";
If none is present, uses '''"models/vehicles/wheel.egf"''';


===wheelBodyGroup===
===wheelBodyGroup===
Line 28: Line 36:
<code>wheelBodyGroup "wheel";</code> for no hubcaps.<br>
<code>wheelBodyGroup "wheel";</code> for no hubcaps.<br>
<code>wheelBodyGroup "wheelUnhubbed" "wheelHubbed" "hubcap";</code> for hubcaps that can fall off.
<code>wheelBodyGroup "wheelUnhubbed" "wheelHubbed" "hubcap";</code> for hubcaps that can fall off.
=== reverseWarning ===
Enables reverse signal sound playing backwards gear is on. Default value is 0.
=== sirenSwitchable ===
When set to 0, makes cop AI to not switch sound of siren. Default is 1.
=== popupHeadlights ===
When enabled, it will try to check model for '''popupHeadlights''' and enable animation for it. Default is 0.


===sounds===
===sounds===
Line 36: Line 53:
|-
|-
|engine
|engine
|Engine sound when the vehicle's accelerating
|Engine sound when the vehicle's accelerating (under load)
|-
|-
|engine_low
|engine_low
Line 42: Line 59:
|-
|-
|engine_idle
|engine_idle
|Engine sound for stopped vehicles
|Engine sound at idle RPM
|-
|-
|reverse_signal
|reverse_signal
|For warning sounds made by reversing trucks
|For warning sounds made by reversing trucks. Uses default sound if not set
|-
|-
|brake_release
|brake_release
|Sound for trucks releasing brakes
|Sound for trucks releasing brakes. Not used if empty
|-
|-
|siren
|siren
|Siren sound for emergency vehicles
|Siren sound for emergency vehicles. Not used if empty
|-
|-
|horn
|horn
|Horn sound
|Horn sound
|}
|}
Each field takes a name of [[Sound Scripts|sound script]] entry.


===Camera===
===Camera===
<code>camera_height</code> How high the third person camera is from the center of the vehicle.<br>
<code>camera_height</code> How high the third person camera is from the center of the vehicle.<br>
<code>camera_distance</code> How far back the third person camera is from the center of the vehicle.<br>
<code>camera_distance</code> How far back the third person camera is from the center of the vehicle.
 
<code>camera_angleX</code> Pitch angle of the third person camera.
 
<br>
<code>camera_height_in</code> How high the bumper camera is from the center of the vehicle.<br>
<code>camera_height_in</code> How high the bumper camera is from the center of the vehicle.<br>
<code>camera_distance_in</code> How far forwards the bumper camera is from the center of the vehicle.<br>
<code>camera_distance_in</code> How far forwards the bumper camera is from the center of the vehicle.<br>
Line 110: Line 132:
|-
|-
|driver
|driver
|Position for the driver, '''first''', '''second''' and '''third''' numbers tell the X, Y and Z coordinates.
|Position for the driver, '''first''', '''second''' and '''third''' numbers tell the X, Y and Z coordinates. When not present it will not place driver model.
|-
|-
|passenger1
|passenger1 ... passenger4
|Position for the first passenger, '''first''', '''second''' and '''third''' numbers tell the X, Y and Z coordinates.<br>Up to 4 passengers can appear in one vehicle.
|Position for the first passenger, '''first''', '''second''' and '''third''' numbers tell the X, Y and Z coordinates.<br>Up to 4 passengers can appear in one vehicle.
|-
|-
Line 121: Line 143:


===hingePoints===
===hingePoints===
Hinge points of a vehicle used for towing.
Hinge points of a vehicle used for towing trailers (and other cars)
{| class="wikitable"
{| class="wikitable"
|front
|front
Line 130: Line 152:
|}
|}


=== useBodyColor ===
=== <s>useBodyColor</s> ===
Use 0 if a vehicle doesn't use a colormap to define its colored zones.
<s>When set to 0 it will tell the game to not have any color.</s> Deprecated and has no effect


=== colors ===
=== colors ===
Line 141: Line 163:
"Green" 0.47 0.6 0.24 1.0;
"Green" 0.47 0.6 0.24 1.0;
</syntaxhighlight>
</syntaxhighlight>


For dual colors:<syntaxhighlight lang="cpp">
For dual colors:<syntaxhighlight lang="cpp">
Line 149: Line 170:
     2 0.35 0.18 0.15 0.5;  
     2 0.35 0.18 0.15 0.5;  
};
};
</syntaxhighlight>
</syntaxhighlight>See [[The Driver Syndicate/Vehicles/Color map|color maps]] on how to make single or dual-color vehicles.


=== bodysize ===
=== bodySize ===
The vehicle's size. Used for 2D shadows, detecting water collision, and AI detection.<sup>maybe</sup><br>
The vehicle's size. Used for 2D shadows, detecting water collision, and AI detection.<sup>maybe</sup><br>
These numbers are based on the center of the vehicle, so they'll be half of its real dimensions.<br>
These numbers are based on the center of the vehicle, so they'll be half of its real dimensions.<br>
There are three digits which represent its '''Width''', '''Height''' and '''Length'''<br>
There are three digits which represent its '''Width''', '''Height''' and '''Length'''


=== center ===
=== center ===
The vehicle's offset from the center.<br>
The vehicle's offset from the center.


=== gravitycenter ===
=== gravityCenter ===
The vehicle's center of gravity.<br>
The vehicle's center of gravity.


=== mass ===
=== mass ===
The vehicle's mass. Not in KG or pounds.<br>
The vehicle's mass. Not in KG or pounds.


=== inertiaScale ===
=== inertiaScale ===
The vehicle's resistance to rotation, whether it be from steering or collisions.
The vehicle's resistance to rotation, whether it be from steering or collisions. Default is 1.5


=== antiroll ===
=== antiRoll ===
The vehicle's resistance to rolling, similar to a sway bar.
The vehicle's resistance to rolling, similar to a sway bar.


Line 190: Line 211:
Final gear ratio, affects all gears.
Final gear ratio, affects all gears.


=== transmissionrate ===
=== transmissionRate ===
Affect's engine's power. <sup>somehow</sup>
Affect's engine's power. <sup>somehow</sup>


=== torquemultipler ===
=== torqueMultipler ===
The engine's power.
The engine's power.


=== maxspeed ===
=== maxspeed ===
The speed where a vehicle's power diminishes.
The speed where a vehicle's power diminishes.<br>
In kilometers per hour.


=== burnoutMaxSpeed ===
=== burnoutMaxSpeed ===
The velocity where a vehicle's burnout is no longer effective.
The velocity where a vehicle's burnout is no longer effective.
In kilometers per hour.


=== suspensionLift ===
=== suspensionLift ===
Lowers and raises the vehicle's resting position on its suspension.
Lowers and raises the vehicle's resting position on its suspension. Basically shifts Y value of '''SuspensionBottom''' for all wheels.


=== steerspeed ===
=== steerSpeed ===
How fast a vehicle reaches full steering lock.<br>
How fast a vehicle reaches full steering lock.<br>
1 is default.
1 is default.
Line 242: Line 266:
|-
|-
|Steer
|Steer
|Float for how much the wheel turn.
|Steering multiplier (percentage) value. Can be negative. 1.0 makes wheel turn by 40 degrees when Fast Steer is on.
|-
|-
|Drive
|Drive
Line 250: Line 274:
|Whether or not the wheel's affected by the handbrake<br>
|Whether or not the wheel's affected by the handbrake<br>
Handbrake strength is also affected by BrakeTorque
Handbrake strength is also affected by BrakeTorque
|-
|WheelBodyGroup
|Alternate name of body group that is taken from wheelModel. Perfect for trucks with different front and back wheels.
|-
|BumpStopOfs
|Cosmetic bump stop offset (for curb hit sound). Default is 0.6
|}
|}
== See also ==
[[The Driver Syndicate/Vehicles/Creating Vehicle Models|Creating Vehicle Models]]

Latest revision as of 16:10, 2 February 2023

Vehicle configuration scripts contain the names and handling properties of vehicles for the Driver Syndicate

Vehicle scripts are loaded from scripts/vehicles/

Fields

name

Name of the vehicle, could be any name but I guess it's now preffered to name as 'XX Name, where XX is the year.

isCar

Indicates that the vehicle is a car and it does have engine. Default value is 1. Must be set to 0 if you making trailer.

isCop

Indicates that this is a cop car.

allowParked

Allows this vehicle to be spawned at parking slots. Default value is 1.

allowMusic

Allows this vehicle to play in-car music. Default value is 1.

cleanModel

Location of the .egf model that the vehicle uses.

damagedModel

Location of the .egf model the vehicle becomes when damaged. If none is present, the vehicle won't show damage.

wheelModel

Location of the .egf model for the wheel models
If none is present, uses "models/vehicles/wheel.egf";

wheelBodyGroup

Names of the bodygroups to be used.
Bodygroups come from the wheelmodel.
wheelBodyGroup "wheel"; for no hubcaps.
wheelBodyGroup "wheelUnhubbed" "wheelHubbed" "hubcap"; for hubcaps that can fall off.

reverseWarning

Enables reverse signal sound playing backwards gear is on. Default value is 0.

sirenSwitchable

When set to 0, makes cop AI to not switch sound of siren. Default is 1.

popupHeadlights

When enabled, it will try to check model for popupHeadlights and enable animation for it. Default is 0.

sounds

An array for the sounds a vehicle will use. Available fields are:

engine Engine sound when the vehicle's accelerating (under load)
engine_low Engine sound when the vehicle's not accelerating
engine_idle Engine sound at idle RPM
reverse_signal For warning sounds made by reversing trucks. Uses default sound if not set
brake_release Sound for trucks releasing brakes. Not used if empty
siren Siren sound for emergency vehicles. Not used if empty
horn Horn sound

Each field takes a name of sound script entry.

Camera

camera_height How high the third person camera is from the center of the vehicle.
camera_distance How far back the third person camera is from the center of the vehicle.

camera_angleX Pitch angle of the third person camera.


camera_height_in How high the bumper camera is from the center of the vehicle.
camera_distance_in How far forwards the bumper camera is from the center of the vehicle.
camera_side_in How far forwards the bumper camera is from the center of the vehicle when looking sideways.

visuals

An array to create the locations and properties of lights, occupants and engine/exhaust.

visuals
{
	headlights 	    1 0.66 0.08 2.10 0.1;
	brakelights 	0 0.78 0.18 -2.25 0.09;

	frontdimlights	0.9 0.07 1.90 0.1;
	backdimlights	0.8 0.05 -2.30 0.09;

	backlights 	    0.76 0.03 -2.31 0.09;

	engine          0.0 0.1 2.1;
	exhaust         0.4 -0.22 -2.2 2 1;

	driver          -0.35 0.15 -0.02;
	passenger1      0.35 0.15 -0.02;
	siren_lights    5 0.4 0.66 -0.32 0.11;
};
headlights Vehicle headlights, first number tells split, 0 for single, 1 for horizontal, 2 for vertical.
Second, third and fourth numbers tell the X, Y and Z coordinates of the light, fifth number tells the split distance.
brakelights Vehicle brakelights, uses 5 numbers like headlights.
frontdimlights Front turn signals, three numbers tell the X, Y and Z coordinates.
backdimlights Back turn signals, three numbers tell the X, Y and Z coordinates.
backlights Reverse lights, three numbers tell the X, Y and Z coordinates.
engine Where the engine smoke originates from a damaged vehicle.
exhaust Where the exhaust smoke originates from, first, second and third numbers tell the X, Y and Z coordinates,
fourth number is for the smoke's direction, 0 for left, 1 for up, 2 for back, fifth number is for mirrored exhausts.
driver Position for the driver, first, second and third numbers tell the X, Y and Z coordinates. When not present it will not place driver model.
passenger1 ... passenger4 Position for the first passenger, first, second and third numbers tell the X, Y and Z coordinates.
Up to 4 passengers can appear in one vehicle.
siren_lights Emergency lights for the vehicle, first number is type, 1 for single blue, 2 for single red, 3 for mirrored blue, 4 for mirrored red, 5 for red and blue
Second, third and fourth numbers tell the X, Y and Z coordinates of the lights, fifth number denotes the width.

You can add up to 4 siren_lights entries.

hingePoints

Hinge points of a vehicle used for towing trailers (and other cars)

front Three numbers for the X, Y and Z coordinates at the front bumper of the vehicle for others to tow it, mostly used for trailers.
back Three numbers for the X, Y and Z coordinates at the back bumper for a vehicle to tow other vehicles.

useBodyColor

When set to 0 it will tell the game to not have any color. Deprecated and has no effect

colors

An array for the colors a vehicle can appear in.
The four digits for colors are Red, Green, Blue and Reflection Strength
Colors can be either a float from 0 to 1, or an integer from 0 to 255.

For single colors:

"Green" 0.47 0.6 0.24 1.0;

For dual colors:

"White and Red" 
{ 
    1 0.96 0.96 0.96 1.0; 
    2 0.35 0.18 0.15 0.5; 
};

See color maps on how to make single or dual-color vehicles.

bodySize

The vehicle's size. Used for 2D shadows, detecting water collision, and AI detection.maybe
These numbers are based on the center of the vehicle, so they'll be half of its real dimensions.
There are three digits which represent its Width, Height and Length

center

The vehicle's offset from the center.

gravityCenter

The vehicle's center of gravity.

mass

The vehicle's mass. Not in KG or pounds.

inertiaScale

The vehicle's resistance to rotation, whether it be from steering or collisions. Default is 1.5

antiRoll

The vehicle's resistance to rolling, similar to a sway bar.

noseDownScale

Makes the vehicle pitch forwards when it jumps.

downForce

Makes the vehicle gain downwards momentum when driving.

engineType

Engine type, 0 = petrol, 1 = diesel, this will affect the acceleration curves.

gears

Gear ratios for the vehicle, lower = faster. First gear is reverse.

shiftAccelFactor

Percentage of acceleration a vehicle has during gear shifts, from 0 to 1.

differential

Final gear ratio, affects all gears.

transmissionRate

Affect's engine's power. somehow

torqueMultipler

The engine's power.

maxspeed

The speed where a vehicle's power diminishes.
In kilometers per hour.

burnoutMaxSpeed

The velocity where a vehicle's burnout is no longer effective.

In kilometers per hour.

suspensionLift

Lowers and raises the vehicle's resting position on its suspension. Basically shifts Y value of SuspensionBottom for all wheels.

steerSpeed

How fast a vehicle reaches full steering lock.
1 is default.

handbrakeScale

How much the handbrake makes the wheels slide.
1 is default.

wheels

An array for containing wheels, their coordinates, size, and other properties. Each wheel is its own array with the following:

SuspensionTop The top of the suspension's coordinates, 3 numbers for X, Y and Z.
SuspensionBottom The bottom of the suspension's coordinates, 3 numbers for X, Y and Z.
SuspensionSpringConstant Suspension spring strength.
SuspensionDampingConstant Suspension damping.
Radius Wheel's radius.
Width Wheel's width, affects its contact point.
CamberAngle Camber angle of the wheel, positive values point the outside down.
BrakeTorque Brake strength of the wheel.
Steer Steering multiplier (percentage) value. Can be negative. 1.0 makes wheel turn by 40 degrees when Fast Steer is on.
Drive Whether or not the wheel's a drive wheel
Handbrake Whether or not the wheel's affected by the handbrake

Handbrake strength is also affected by BrakeTorque

WheelBodyGroup Alternate name of body group that is taken from wheelModel. Perfect for trucks with different front and back wheels.
BumpStopOfs Cosmetic bump stop offset (for curb hit sound). Default is 0.6

See also

Creating Vehicle Models