Documentation for modders - VEHICLES

Preface

# Structure of SCRIPT.INI file # for vehicles # version 1.11 # 2022.04.07 # # ---------------------------------------------------------------------- # http://docopt.org/ # <> - positional argument # [] - optional # () - required # | - or # # # Changelog: # # Version 1.0 (2019.09.12) # - initial version # # Version 1.01 (2019.10.30) # - added limitations for skins and model packs # # Version 1.10 (2020.03.09) # - added tokens for ships # - added tokens for cableways # - added tokens about forklifts # - updated list of countries # # Version 1.11 (2022.04.07) # - added skills for police/prison # - added information about mixer/dumper animations # # Version 1.20 (2024.03.04) # - added airplane section # - added new tokens

Files

Main.mnfMaterial.mtl
Script.ini

# All files for vehicle should be located in the same folder # Files: # - model of vehicle # - material of object # - definition of vehicle # Files: preview.dds preview_side.dds and bbox.bin are automaticly # generated when they aren’t in folder. # IMPORTANT NOTE: In case you change the models you should delete preview.dds and preview_side.dds and bbox.bin to regenerate them # DDS textures should be linked in the , check the vehicle skin tutorial for description # DDS format for vehicles is DXT1 - 1bit alpha where you wish to display # glass reflections on the texture use there black color in alpha channel # If you would like to make more skins for your vehicle just include more # material files in the directory but they need to have specific name # (1st skin - default) # material_1.mtl (2nd skin) # material_2.mtl (3rd skin) # etc… # note: if you include only and material_3.mtl only # will be accepted.. game expecting file material_1.mtl as # second skin # # Limitations: # # Maximum 16 skins in one Workshop Item # Example: # If you make one vehicle model, you can add to it 16 skins # If you make 4 vehicles, you can add 4 skins for each, but alway max. 16 skins in one Item # or 13 skins for 1st vehicle, 1 for 2nd, 1 for 3rd and 1 for 4th. # # You can assign max. 32 skins for one vehicle model # Example: # In Workshop Item (vehicle model) you made 4 skins # You can also add another 28 skins as skin packs. # If you add more than 28 skins, only first 32 will be used for this vehicle's model # # Maximum 16 models for one Workshop Item

Common

# ------------------------------------------------------------------------ # common parameters # ------------------------------------------------------------------------ # Type of vehicle # Available types: # VEHICLETYPE_ROAD # VEHICLETYPE_RAIL_LOCOMOTIVE # VEHICLETYPE_RAIL_VAGON # VEHICLETYPE_CABIN # VEHICLETYPE_AIRPLANE # VEHICLETYPE_SHIP # example: $TYPE VEHICLETYPE_ROAD $TYPE (vehicle_type) # Subtypes: # for VEHICLETYPE_CABIN # # $CABIN_HEAVY << Heavy cabin suitable only for paths with heavy poles # $CABIN_LIGHT << Light cabin suitable for paths with heavy and light poles # Name of vehicle # example: $NAME_STR "Fiat 500" # $NAME_STR ("name") # With this flag you will specify if vehicle will be available for dollars or for rubbles.. cost is generated automatically from engine power and weight of the vehicle # in RUB or USD # example: $COST_RUB 1 $COST_RUB 1 # or $COST_USD 1 # Speed of vehicle (in km/h) # example: $MOVEMENT_SPEED 111 # if you don't set vehicle speed or set it to 0 (zero) # vehicle must be transported by another vehicle $MOVEMENT_SPEED (speed) # Power of vehicle (in KW) # example: $MOVEMENT_POWER_KW 118 $MOVEMENT_POWER_KW (power) # Weight of empty vehicle (in t) # example: $MOVEMENT_EMPTY_WEIGHT 9.5 $MOVEMENT_EMPTY_WEIGHT (weight) # how much slope affect speed # example: $MOVEMENT_HILL_SPEED 0.5 $MOVEMENT_HILL_SPEED (factor) # how much slope affect acceleration # example: $MOVEMENT_HILL_ACCELERATION 0.5 $MOVEMENT_HILL_ACCELERATION (factor) # Range of vehicle's availability # for endless availabilty use end_date = 3000 # example: $AVAILABLE 1968 1983 $AVAILABLE (start_date end_date) # Type of cargo # # List of cargo: # RESOURCE_TRANSPORT_PASSANGER # RESOURCE_TRANSPORT_CEMENT # RESOURCE_TRANSPORT_COVERED # RESOURCE_TRANSPORT_GRAVEL # RESOURCE_TRANSPORT_OIL # RESOURCE_TRANSPORT_OPEN # RESOURCE_TRANSPORT_COOLER # RESOURCE_TRANSPORT_CONCRETE # RESOURCE_TRANSPORT_LIVESTOCK # RESOURCE_TRANSPORT_SEWAGE # RESOURCE_TRANAPORT_WASTE # RESOURCE_TRANSPORT_WATER # RESOURCE_TRANSPORT_GENERAL << special type of cargo allowing to hold resources for # open and covered in one type of cargo # # If $RESOURCE_TRANSPORT_TYPE is not present, vehicle can not transport any materials # for example: firetrucks, cranes, pavers, tractors # # example: $RESOURCE_TRANSPORT_TYPE RESOURCE_TRANSPORT_PASSANGER $RESOURCE_TRANSPORT_TYPE (type_of_cargo) # Now you can set exact type of allowed resource # you can use many tokens for one vehicle, if you want to # transport more than one material # example: # $RESOURCE_ALLOW_ONLY wood # $RESOURCE_ALLOW_ONLY boards $RESOURCE_ALLOW_ONLY (type) # Capacity of vehicle # For passengers vehicles - how many passengers can be transported # For cargo vehicles - capacity in tons # example: $RESOURCE_CAPACITY 55 $RESOURCE_CAPACITY (amount) # Country of origin # List of countries - APPENDIX A # You can use own name, but it will not be translated # If you use dictionary, name of country will be translated eventually :) # example: $COUNTRY 39008 # or $COUNTRY_STR "San Escobar") # $COUNTRY (number) # or $COUNTRY_STR (“name_of_country”)

Lights

# ------------------------------------------------------------------------ # lights parameters # ------------------------------------------------------------------------ # Position of front light (white) # example: $LIGHT_FORWARD 0.9631 0.9686 4.381 # # you can add multiple lights $LIGHT_FORWARD (x_position y_position z_position) # Position of back light (red) # example: $LIGHT_BACKWARD -0.8248 0.8973 -6.1228 # # you can add multiple lights # Note: in case trailer (joint) of vehicle is defined backward light will # be displayed on the trailer and its position should be relative # in the trailer model $LIGHT_BACKWARD (x_position y_position z_position) # Position of emergency light (blue) # for firetrucks, ambulance # example: $SIREN_POINT -0.7354 2.7080 2.3923 # # you can add multiple lights $SIREN_POINT (x_position y_position z_position)

Particles And Animations

# ---------------------------------------------------------------------- # Particles # ---------------------------------------------------------------------- # Position of emitter and type of particles # Particle types: # vehicle_medium # train_electric # train_small # train_medium # # you can add multiply emitters # # Example: $PARTICLE_MOVEMENT vehicle_medium 1.1 0.6951 0.68 # # Particle definition taken from file ................................ $PARTICLE_MOVEMENT (emiter_type x_position y_position z_position) # !! IMPORTANT NOTE if you specify at least one particle # train_electric that will specify that vehicle will be electric and not # diesel :-) use this train_electric particle for trolleybuses too # If your vehicle has joined models # for example truck with trailer # or articulated bus # sometimes you need move particle emitter to joined (trailer) part # You can do it using: # example: $PARTICLE_MOVEMENT_JOINT vehicle_medium -0.7662 0.7098 -3.3 $PARTICLE_MOVEMENT_JOINT (emiter_type x_position y_position z_position) # -------------------------------------- # # Animation # # —------------------------------------- # If you want to add dumpers animation # while unloading # You have to: # Define animated part (deck) as separate element of the model # Define coordinated of pivot point # # Example: # $DUMPER_DECK_PIVOT # polySurfaceShape10 # 0.00 0.9239 -2.59 $DUMPER_DECK_PIVOT Name_Of_The_Deck_Element (x y z) # If you want to add concrete mixer animation # You have to: # Define animated part (drum) as separate element of the model # Define two points as a rotation axis # # Example: # # $MIXER_DRUM # Cylinder024Shape # 0.00 1.92 -0.89 # 0.00 2.8 -4.00 $MIXER_DRUM Name_Of_the_Drum_Element (x y z) (x2 y2 z2) # Animation of the landing gears # Example: # $LANDING_GEAR_ANIM airplanes/c401/wheels.nmf $LANDING_GEAR_ANIM (file) # If you want to add LOD models, you should add paths # to the files in the .ini file # # Example: # $LOD1 vehicles/bus_pz_672/lod.nmf # # also works: # $LOD2, $LODJOINT1, $LODJOINT2 # # Using tokens: $LODDISTANCE1 and $LODDISTANCE2 # you can set distance when LOD1 or LOD2 will be used # Example: # $LODDISTANCE1 100 $LOD1 (path_to_file) $LODDISTANCE1 (meters) # Working animation # # Example: # $WORKING_ANIM vehicles/service_buldozer_small/mining.nmf 0 0 $WORKING_ANIM (file X_offset Z_offset) # ----------------------------------------------------------------- # Garbage loading/unloading animation # If you want to add animation fo loading/unloading garbage # you need to use tokens below # as a parameter you have to add path to the file # Example: # # $GARBAGE_LOADING_ANIM vehicles/garbage_big_mckR/loading.nmf # $GARBAGE_UNLOADING_ANIM vehicles/garbage_big_mckR/unloading.nmf # $GARBAGE_UNLOADING_ANIM2 vehicles/garbage_big_mckR/tilting.nmf # ----------------------------------------------------------------- $GARBAGE_LOADING_ANIM (file) $GARBAGE_UNLOADING_ANIM (file) $GARBAGE_UNLOADING_ANIM2 (file)

Skills

----------------------------------------------------------------------- # Skills of vehicles # skills mean how good is special vehicle when it harvesting, # sowing, fire extinguishing etc. # higher value, better skill # you can mix some skills, for example bulldozing and gravelmining # but use it wisely :) # ----------------------------------------------------------------------- # for harvesting # example: $SKILL_HARVESTING 22 $SKILL_HARVESTING (value) # for fire extinguishing # example: $SKILL_FIRETRUCK 8 $SKILL_FIRETRUCK (value) # for carrying of wood # example: $SKILL_WOODCARRING 20 $SKILL_WOODCARRING (value) # you specifying with this parameter that vehicle is personal car which can # be assigned to parking lot and purchased in car dealer # for personal cars # example: $SKILL_PERSONAL 1 $SKILL_PERSONAL (value) # for gravel mining # example: $SKILL_GRAVELMINING 9 $SKILL_GRAVELMINING (value) # for bulldozing # example: $SKILL_CONSTRUCTION_BULLDOZER 9 $SKILL_CONSTRUCTION_BULLDOZER (value) # for groundworks # example: $SKILL_CONSTRUCTION_GROUNDWORKS 37 $SKILL_CONSTRUCTION_GROUNDWORKS (value) # for cranes # example: $SKILL_CONSTRUCTION_CRANE 23 $SKILL_CONSTRUCTION_CRANE (value) # for pavers # example: $SKILL_CONSTRUCTION_ASPHALT_LAYING 45 $SKILL_CONSTRUCTION_ASPHALT_LAYING (value) # for asphalt rollers # example: $SKILL_CONSTRUCTION_ROLLING 18 $SKILL_CONSTRUCTION_ROLLING (value) # for tractors # example: $SKILL_SEEDING 28 $SKILL_SEEDING (value) # for ambulances # example: $SKILL_AMBULANCE 1 $SKILL_AMBULANCE (value) # for forklift # example: $SKILL_FORKLIFT 1 # vehicle with this flag is usable as forklift, # the 1 (value) doing nothing special. forklifts are different like regular trucks # by amount of cargo which can transport and engine power $SKILL_FORKLIFT (value) # for snowplows # example: $SKILL_SNOWPLOW 23 # Value is a spped of working snowplow $SKILL_SNOWPLOW (value) # For a prison buses: # example: $SKILL_POLICEBUS 1 # Of course you also have to define capacity # like for a normal bus :) $SKILL_POLICEBUS 1 # For a police car: # example: $SKILL_POLICECAR 1 $SKILL_POLICECAR 1 # for track builders # Example: # $SKILL_CONSTRUCTION_RAIL_CRANE 10 20 $SKILL_CONSTRUCTION_RAIL_CRANE (power menpower) # Example: $SKILL_CONSTRUCTION_RAIL_TRACK_LAYER 35 25 3 $SKILL_CONSTRUCTION_RAIL_TRACK_LAYER (power menpower speedfactor) # For tunnel boring machine # You have to add $TUNNELING_TEETH token (no parameters) # and add token for skill # Example # $SKILL_CONSTRUCTION_RAIL_TUNNEL_BORING 260 $TUNNELING_TEETH $SKILL_CONSTRUCTION_RAIL_TUNNEL_BORING (power) # For waste trucks # Example: # $SKILL_WASTE_CONTAINER_SMALL 1 # $SKILL_WASTE_CONTAINER_BIG 1 $SKILL_WASTE_CONTAINER_BIG (value) $SKILL_WASTE_CONTAINER_SMALL (value)

Sounds

# ------------------------------------------------------------------------ # SOUNDS # ------------------------------------------------------------------------ # Importing sounds definitions for vehicle # More info DOC.sounds.ini (work in progress) # # example: $SOUND_PARAMS sounds/car1.ini # path is relative to media_soviet folder # # You can import more than one definition file # # Note: Currently is the best practice just copy sound params from similar # vehicle later we will add option to put your own SFX and params $SOUND_PARAMS (path_to_sounds_ini_file)

Various

# ------------------------------------------------------------------------ # Various # ------------------------------------------------------------------------ # Water emiter for firetrucks # Example: $WATER_POINT 0.00 2.7080 -1.3130 $WATER_POINT (x_position y_position z_position) # If vehicle should not be available for purchasing # for example: trailers, train/tram module # You can exclude it from list of available vehicles # variable has no parameters $PURCHASE_EXCLUDE

Joining Models & Resource Visualization

# ----------------------------------------------------------------------- # Joining models - trailers # ----------------------------------------------------------------------- # If you want to join some models # for example: truck and trailer, Trainset modules, etc. # path is relative to media_soviet # Example: $JOINT vehicles/bus_cavb14/joint.nmf 1.5 1.2 # # offset - it is offset of joined model to original model # rotatingoffset - magic variable to correct rotating joined model when # vehicle is turning $JOINT (path_to_NMF_model offset rotatingoffset) # related (parent) vehicle # parameters like years are taken from this vehicle # example: $FAMILY gravel_zil_133 $FAMILY folder_name_of_parent_vehicle # rotate - angles of rotate cargo # # min - coordinates of resource center for almost empty truck # max - the same for full loaded trucks # # in next line is a scale of resource # # you have to change these parameters to fit cargo inside truck :) # # example: # $RESOURCE_VISUALIZATION # rotation # 0 0 0 # min # 0.000 1.4167 -1.4704 # 0.810 1.0 0.728 # max # 0.000 1.8396 -1.4704 # 0.810 2.438 0.728 $RESOURCE_VISUALIZATION rotation (x y z) min (x_coord y_coord z_coord) (x_scale y_scale z_scale) max (x_coord y_coord z_coord) (x_scale y_scale z_scale) # --------------------------------------------------------------- # Visualization of vehicles as a cargo. # Used when truck transports other vehicle # # min and max parameters means coordinates of # opposite apexes of " cargo box" # # max # __________________________o # / /| # / / | # +-------------------------+ | # | | | # | | | # | | / # | |/ # o-------------------------+ # min # # Note: Specifying this flag you will make vehicle capable for transport # other vehicles such as brand new cars or construction mechanisms # # Note2: Only one $CARGOVEHICLE_VISUALIZATION token per vehicle is # supported now $CARGOVEHICLE_VISUALIZATION min -1.1302 1.2959 -3.4683 max 1.1302 1.2959 1.2426 # $CARGOVEHICLE_MUSTBE_LOADED # vehicle must be loaded to another vehicle in order to transport, like tower cranes # $CARGOVEHICLE_CANBE_LOADED # vehicle may be loaded to another vehicle to transport like paver, # excavator, specifing this flag vehicle can be taken # to construction by flatbed vehicles # $WORKING_ANIM (file offsetX, offsetZ) # this is used now only for animated excavators when working # on constructions or in quary. # OffsetX and OffsetZ are just tweak if you need offset a bit vehicle during animation

Trains

# ------------------------------------------------------------ # # TRAINS # # ------------------------------------------------------------ # # $TRAIN_BBOX_FORWARD_CORRECTION # $TRAIN_BBOX_BACKWARD_CORRECTION # # These parameters are responsible for # model position correction when # model consists of many submodels # for example long trams, trainsets # So with this params you can override the model bounding box # For example.. if you look at trains\russian_tram_kt8 and # trains\russian_tram_kt8_v you get idea how to do if you need connect # three parts of tram # For two parts tram/train check trains\russian_set_svt137 # # Example: $TRAIN_BBOX_FORWARD_CORRECTION 0.9 # # IMPORTANT NOTE.. if you change values there you need to delete bbox.bin # to regenerate it $TRAIN_BBOX_FORWARD_CORRECTION (value) # Train group # Type of group affects where vehicle # is shown in game (vehicle buy window) # # Possible train group: # $TRAINGROUP_VAGON # $TRAINGROUP_MOTORVAGON # $TRAINGROUP_LOCOMOTIVE # game will recognize automatically if diesel or electric # by defined particles (check particles section # $TRAINGROUP_TRAM # $TRAINGROUP_TRAINSET # $TRAINGROUP_TRACKBUILDER # $TRAINGROUP_METRO # # Example: $TRAINGROUP_LOCOMOTIVE $TRAINGROUP_LOCOMOTIVE # This is if you would like to create the train set which is set of more # vehicles.. you should add to your # this will create set of three parts/vagons… # one current vehicle (the head/first one) - russian_set_d1 # second will be russian_set_d1_v - the vagon with $PURCHASE_EXCLUDE flag # defined in the its INI file # third one again russian_set_d1 but reversed 180 $TRAINSET russian_set_d1_v $TRAINSET_REVERSE russian_set_d1 # If you will creating workshop item it will be like this # your ItemID will be like 1548789431 # into your folder workshop_wip/1548789431/ you will place two folders # “head” and “vagon” # so workshop_wip/1548789431/head and workshop_wip/1548789431/vagon # every folder is one vehicle with own INI # in vagon script.ini you should define $PURCHASE_EXCLUDE # then you will connect it to trainset like this # in the head script ini: $TRAINSET 1548789431/vagon $TRAINSET 1548789431/vagon $TRAINSET_REVERSE 1548789431/head # This will create 4 parts train set # (head + vagon + vagon + head reversed ) # dont forget to link all folders in the workshopscript.ini # $OBJECT_VEHICLE vagon # $OBJECT_VEHICLE head

Ships

# ------------------------------------------- # # SHIPS # # ------------------------------------------- # Definition of ship’s wake (kilwater) # Each ship can make more wakes # # Parameters: # position: position of front of wave # coordstep: how fast is making # bumbfactor: how high are waves # srcsize: sources size of waves in 0 seconds after launching # dstsize: size of the waves at the end of the waves - after max time (seconds) after launching # maxtime: how long will waves exist in the water in seconds.. more value .. longer waves $WAVEPOINTFRONT position 0.0 0.5 32.0 coordstep 0.0008 bumpfactor 1.5 srcsize 2.0 dstsize 100.0 maxtime 30.0 $WAVEPOINTBACK position 0.0 0.5 -27.0 coordstep 0.0013 bumpfactor 1.5 srcsize 7.0 dstsize 35.0

Obsolete

# ------------------------------------------------------------ # # Obsolete # # ------------------------------------------------------------ $MOVEMENT_CONSPUMPTION 0 $DESCRIPTION 39082

Appendix A - Countries

#------------------------------------------------------------- # # APPENDIX A: # #------------------------------------------------------------- Countries dictionary: 38998 Domestic product 38999 Unknown country 39000 Czechoslovakia 39001 Czechia 39002 Slovakia 39003 Germany 39004 East Germany 39005 West Germany 39006 Poland 39007 Hungary 39008 Bulgaria 39009 Romania 39010 Yugoslavia 39011 Soviet Union 39012 Lithuanian SSR 39013 Latvian SSR 39014 Belarusian SSR 39015 Ukrainian SSR 39016 France 39017 Italy 39018 USA 39019 Belarus 39020 Ukraine 39021 Russia 39022 Sweden 39023 Spain 39024 South Korea 39025 Serbia 39026 Bosnia and Hercegovina 39027 Croatia 39028 Albania 39029 North Korea 39030 Japan 39041 United Kingdom

Airplanes, Helicopters

# ------------------------------------------------------- # # AIRPLANES # # ------------------------------------------------------- # Each planes has distance to take-off # distance in m # Example: # $TAKEOFF_DISTANCE 150 $TAKEOFF_DISTANCE (len) # if plane has a wheels (front or back ones) # you can set coordinates of the wheels # # Example: # $MOVEMENT_WHEEL_FRONT 1.76 -1.54 2.2 # $MOVEMENT_WHEEL_BACK 0 0 -5.67 $MOVEMENT_WHEEL_FRONT (x y z) $MOVEMENT_WHEEL_BACK (x y z) # Object for propeller (if any) # _STATIC, _DYNAMIC and _LOW for different speed # Example: # $PROPELER_STATIC airplanes/an2/propeler_con.nmf # $PROPELER_DYNAMIC airplanes/an2/propeler_high.nmf # $PROPELER_LOW 1.8 airplanes/an2/propeler_low.nmf airplanes/an2/material_propeler.mtl # PROPELER_LOW has a two parameters, because needed different texture/material for low propeper.. it is a blurred propeler $PROPELER_STATIC (path_to_nmf_model) # Point of showing propeller in model # Example: # $PROPELER_POINT 0.0 0.97 4.9 $PROPELER_POINT (x y z) # Propeller for a helicopter # Example: # $PROPELER_HELICOPTER 1 helicopters/mi10c/screwcon.nmf helicopters/mi10c/screwhi.nmf helicopters/mi10c/screwlo.nmf helicopters/mi10c/material_propeler1.mtl $PROPELER_HELICOPTER (scale path_to_static path_to_high path_to_low path_to_material) # Pinpoint for a helicopter propeler # This token use 6 parameters: # - 3 for a coordinates # - 3 for rotation of propeller # # Example: $PROPELER_HELICOPTER_POINT_DIR 0 1.9272 0 0.0 0.0 0.0 $PROPELER_HELICOPER_POINT_DIR (x y z x_rotation y_rotation z_rotation)

Source: https://steamcommunity.com/sharedfiles/filedetails/?id=1861143159					

More Workers & Resources: Soviet Republic guilds