Repainting base vehicles via material only?

Willkommen in der Transport Fever Community

Wir begrüßen euch in der Fan-Community zu den Spielen Transport Fever und Train Fever, den Wirtschaftssimulatoren von Urban Games. Die Community steht euch kostenlos zur Verfügung damit ihr euch über das Spiel austauschen und informieren könnt. Wir pflegen hier einen freundlichen und sachlichen Umgang untereinander und unser Team steht euch in allen Fragen gerne beiseite.

 

Die Registrierung und Nutzung ist selbstverständlich kostenlos.

 

Wir wünschen euch viel Spaß und hoffen auf rege Beteiligung.

Das Team der Transport-Fever Community


  • Hey.

    I've got a problem. I want to make variant vehicles in Extended Gameplay Two to be more distinct - in order to get it done I want to provide 10 or so color variants for each. However - if I do so by providing a new texture for each variant - that is going to murder GPU memory and this game is already quite hungry for it.


    So - does anyone know a way to do so with materials? Color-configs don't seem to work for wagons and locomotives. Neither do color-blend property from material script...

  • Do You want the variants to just show up randomly in the game or to be selectable via the depot purchase menus?


    In the first case, it would probably not beyond a good scripter to add a bit of random colour to any purchased vehicle via the Cblend option the second the vehicle is bought.


    In the second case, You´d need to provide a bunch of new .mdl files for the menu to offer. This would basically mean a repaint with only need the map_albedo adapted; the rest of the maps that make up a texture could go unchanged. If You want to cut down on ressources, it´d be possible to use a smaller resolution file for the maps. I am under the impression that UV mapping does not yield absolute coordinates but percentages of a given textures width and height, so just throwing a smaller texture file into a material instead of the original one is very much an option. This will of course come at the price of texture detail or, if You will, crispness.

  • In the first case, it would probably not beyond a good scripter to add a bit of random colour to any purchased vehicle via the Cblend option the second the vehicle is bought.

    Doesn't even need a good scripter.

    Because afaik the only way to have variation in one mdl file is via the custom cargo models.


    Models and materials are loaded once, so it is impossible to change anything there when loaded unless you do some very deep digging like eis_os.

  • Do You want the variants to just show up randomly in the game or to be selectable via the depot purchase menus?


    In the first case, it would probably not beyond a good scripter to add a bit of random colour to any purchased vehicle via the Cblend option the second the vehicle is bought.

    Through some sort of UI callback during the creation of a vehicle? That would be optimal. I want to provide a color version for each 'suffix' a vehicle can get. There are ~10 such suffixes so if I were to add 10 versions for each albedo texture, that would amount to gigabytes of data - there are like 100 train vehicles per climate, so 1000 textures to provide. Doing this programatically - by providing a parameter during instantiation of a vehicle would be preferable. I could even add some random variety to each vehicle to break the uniform look. Can you point me to an example of such trickery?


    I'll take a look into it over the weekend.

  • Doesn't even need a good scripter.

    Because afaik the only way to have variation in one mdl file is via the custom cargo models.


    Models and materials are loaded once, so it is impossible to change anything there when loaded unless you do some very deep digging like eis_os.

    The game already supports custom color for each vehicle instance - natively through ColorConfigs for some vehicles or by hand when buying one. If I could access this functionality with a script then I would get what I want without adding additional complexity.

BlueBrixx