User Tools

Site Tools

Urban Games

modding:vehiclebasics

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
modding:vehiclebasics [2020/07/08 15:06]
kjell [Compartment List]
modding:vehiclebasics [2022/05/09 19:41] (current)
yoshi [seats]
Line 19: Line 19:
  
 The ''idleEmission'' property is used when the vehicle stands still. ''powerEmission'' defines the emission when the thrust of the engine is at maximum and ''speedEmission'' is the emission when the vehicle is at full speed. For situations between, the values are interpolated. Setting a property to ''-1'', the actual value is automatically computed by using the other provided metadata like speed, availability and power. The ''idleEmission'' property is used when the vehicle stands still. ''powerEmission'' defines the emission when the thrust of the engine is at maximum and ''speedEmission'' is the emission when the vehicle is at full speed. For situations between, the values are interpolated. Setting a property to ''-1'', the actual value is automatically computed by using the other provided metadata like speed, availability and power.
 +
 +The allowed ranges for the three properties are:
 +  * idleEmission: [0.0, 100.0]
 +  * speedEmission: [0.0, 2.0]
 +  * powerEmission: [0.0, 0.0002]
 ===== Player Controlled Vehicles ===== ===== Player Controlled Vehicles =====
 Vehicles that can be bought and controlled by the player all have a general metadata block called ''transport Vehicle'': Vehicles that can be bought and controlled by the player all have a general metadata block called ''transport Vehicle'':
Line 33: Line 38:
      
   -- RAIL only   -- RAIL only
-  multipleUnitOnly = false,  -- +  multipleUnitOnly = false,  -- display only as part of multiple units 
-  reversible = false         -- optional, if vehicle is reversible - for RAIL vehicles only+  reversible = false,        -- optional, if vehicle is reversible - for RAIL vehicles only 
 +  departureDelay = 2500      -- optional, adjusts the timing for the departure of the vehicle, see below
 }, },
 </code> </code>
Line 49: Line 55:
   * ''compartmentsList'' is used to define the load of the vehicle. See below for further information.   * ''compartmentsList'' is used to define the load of the vehicle. See below for further information.
  
-Two properties are currently only relevant for rail vehicles:+Three properties are currently only relevant for rail vehicles:
   * ''multipleUnitOnly'' is a value that hides the model itself from the buy menu when set to ''true''. It is still usable in [[:modding:vehicletypes#multiple_units|multiple units]] though.    * ''multipleUnitOnly'' is a value that hides the model itself from the buy menu when set to ''true''. It is still usable in [[:modding:vehicletypes#multiple_units|multiple units]] though. 
   * ''reversible'' specifies if this vehicle is capable of being used in push/pull trains. See the [[modding:vehicleadvancedtopics#reversible_trains|reversible trains details]] for more information.   * ''reversible'' specifies if this vehicle is capable of being used in push/pull trains. See the [[modding:vehicleadvancedtopics#reversible_trains|reversible trains details]] for more information.
 +  * ''departureDelay'' is a custom value in milliseconds that describes the time span between the closing of doors until the vehicle departs. If unset, the longest door close animation duration is used.
 ===== AI Controlled Vehicles ===== ===== AI Controlled Vehicles =====
 Some residents are considered as car owners. If they decide to not use public transportation to travel to their destination, they might use a car. To set a road vehicle model to be used by the AI as a car, it requires an empty metadata block: Some residents are considered as car owners. If they decide to not use public transportation to travel to their destination, they might use a car. To set a road vehicle model to be used by the AI as a car, it requires an empty metadata block:
Line 130: Line 136:
  
 ==== seats ==== ==== seats ====
-The ''seats'' block is a list that contains all seat ids of seats from the [[modding:vehiclebasics#seats|seatProvider]] belonging to the configuration. Then passengers loaded in this compartment of the vehicle are only displayed on the respective seats.+The ''seats'' block is a list that contains all seat ids of seats from the [[modding:vehiclebasics#seats1|seatProvider]] belonging to the configuration. Then passengers loaded in this compartment of the vehicle are only displayed on the respective seats.
  
 This property is ignored for all cargo types other than ''"PASSENGERS"''. This property is ignored for all cargo types other than ''"PASSENGERS"''.
modding/vehiclebasics.1594213603.txt.gz · Last modified: 2020/07/08 15:06 by kjell