calculated vehicle capacites with payload and loading volume

Willkommen in der Transport Fever Community

Welcome to the fan community of Transport Fever and Train Fever, the economic simulators of Urban Games. The community is free for you to share and inform yourself about the game. We cultivate a friendly and objective interaction with each other and our team will be happy to answer any questions you may have.

 

Registration and use is of course free for you.

 

We wish you a lot of fun and hope for active participation.

The Team of the Transport-Fever Community

  • An explanation for vehicle modder to support the mod "EMP: Heavy Cargo Challenge (calculated cargo weight)", the follower of the mod "cargo calculated weight" (short CCW) for TPF1.

    If you have already updated a vehicle-mod for the old CCW of TPF1, you know the steps already:


    Payload and loading volume have to be defined in the model definition (*.mdl file). Add new lines for maxWeight and maxVolume in block of transportVehicle and you are done.


    The maximum payload must be given in metric ton (t). Payload just means the allowed weight of cargo without the weight of the vehicle itself.

    The maximum loading volume must be given in cubic meter (m³). Loading volume means the full volume of the loading area. In most cases, this will be equal to the volume that can be calculated through the coordinates given to bbMin and bbMax if given.


    Please use only real values. Unreal values will just break fun of the wanted challenge.



    The block for transportVehicle is documented in TPF2-Wiki here: https://www.transportfever2.co…layer_controlled_vehicles
    Just add the two mentioned values there and the script mod will calculate real capacities.


    illustrative example:

    Code
    transportVehicle = {
      ...               -- already given block
    
      maxWeight = 60.0,  -- payload in t
      maxVolume = 100.0, -- loading volume in m³
    },

    hint: don't forget the comma at the end of the last already given line ;)



    Compartments for wagons/ trailers

    It is a little more complex if you want to map different configurations of a vehicle with different loading areas using compartments. An example of this would be a tandem truck with trailer. In this case, the capacity and payload may be different for the truck and the trailer. Or you want to model cargo streetcars with different wagons.

    With the version from 07.02.2024, lists are also supported for maxWeight and maxVolume. This list must have exactly as many entries as the number of compartments defined. This means that the payload and load volume can be set individually for each compartment.



    Illustrative example for 2 compartments:

    Code
    transportVehicle = {
      ...                         -- already given block
    
      maxWeight = {30.0, 30.0},   -- payload in t
      maxVolume = {50.0, 50.0},   -- loading volume in m³
    },

    hint: don't forget the comma at the end of the last already given line ;)

Share