Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Materials for Wraps Ads and Recoloring

Image Added

The bus customization replaces several materials on the bus automatically the standard materials, setup in your bus, on runtime with the player customized ones by the player. To tell the game which materials be able to replace them, we need to setup the blueprint accordingly. If you look into the “BusBaseConfig“ data asset you will see several preset materials. Those are the parent materials used throughout the game. The game will search for these materials in the customization and replaces them when with the customized ones when the player customizes their bus. If you want to change default visuals of the bus, e.g. if you want to change the default chassis color of your bus, create a material instance of the default chassis material and assign it to your bus chassis. You can then change the color in the material instance. The new color will be used by default when the bus is bought ingame.

Static Mesh

look at all materials on the bus and check if a material is a material instance of one of the base materials setup in the “BusBaseConfig”. If we find such a material on the bus we will replace that material if the bus has been customized.

E.g. If you want to be able customize the chassis of your bus do the following:

  1. open the BusBaseConfig and locate the default chassis material

  2. click the looking glass next to the material to navigate to the file location

  3. right click the material and create a material instance

  4. move the material instance to your mod folder. If the material is not in your mod folder it will not be packaged and not be available once you load the mod to the game.

  5. assign the material instance to your bus

  6. (optional) change the material instance to your liking, the look of this material instance will be the default visuals players will see when they buy your bus.

Static Mesh for decal placement

Decals are directly baked into the material, this is done by calculating the UV coordinates of the player interaction on the bus and placing the selected decal image on the selected UV coordinates. Those UV coordinates are calculated by raycasting against an invisible static mesh representation of the bus. To create this static mesh open the skeletal mesh of your bus and click the Make Static Mesh button .

Image RemovedImage Added

Save this mesh inside your plugin folder and don’t forget to assign this mesh to the Customisation Mesh variable in the ModInfo.

Without this static mesh setup players won’t be able to place decals on their bus.

Next Step

Shop Video

On this page:

Table of Contents
minLevel1
maxLevel7
outlinetrue
stylenone
printablefalse