Same way players can set a color for their skin and gun.
Uses material proxy.
Add to a vmt file to make it compatible:
--------------
Proxies {
VehColor{
resultVar $color2
myVariable $color
}
}
--------------
Change "VehColor" to "VehColor2" for the secondary color!!!
Change "VehColor" to "VehColor2" for the secondary color!!!
--- Entire snippet of one of my VMTs ---
"VertexlitGeneric"
{
"$basetexturetransform" "center .5 .5 scale 60 60 rotate 0 translate 0 0"
"$basetexture" "models/notakid/gtavredux/skin"
"$bumpmap" "models/notakid/gtavredux/skin_normal"
"$phong" 1
"$phongexponent" 5
"$phongboost" 2
"$phongfresnelranges" "[1 1 1]"
"$rimlight" 1
"$rimlightboost" 0.5
"$envmap" "env_cubemap"
"$envmaptint" "[0.07 0.07 0.07]"
"$normalmapalphaenvmapmask" 1
"$phongfix" "{1 1 1}"
Proxies {
VehColor{
resultVar $color2
myVariable $color
}
}
}
...
https://www.youtube.com/watch?v=n_9vnP3lFM8