Scrolling textures?

  • If you're asking a question make sure to set the thread type to be a question!

Tuaam

L6: Sharp Member
Jun 26, 2015
376
248
Alright so I have the file set up for editing but I need to know how to make a texture scroll? How would I edit the text to make this texture scroll (Both alphas). I need this for a map I'm making that takes place on a train.

Here's the code:
====================
"WorldVertexTransition"
{
"$basetexture" "Nature/rockwall001forest"
"$basetexture2" "Nature/snow_full001"
"%tooltexture" "Nature/rockwall001forest"
"$blendmodulatetexture" "Nature/snowwall_blendmask"
"$bumpmap" "Nature/rockwall001_normal"
"$bumpmap2" "Nature/rockground002_height-ssbump"
"%keywords" "tf"
"$surfaceprop" "dirt"
TextureScroll
{
textureScrollVar $bumpTransform
textureScrollrate 1.3
texturescrollangle 270.00
}

}
====================

This is the section of code I put in:
=========================
TextureScroll
{
textureScrollVar $bumpTransform
textureScrollrate 1.3
texturescrollangle 270.00
}
=========================

So can somebody post code indicating how to make this scroll?
 

Tuaam

L6: Sharp Member
Jun 26, 2015
376
248
Moderator Warning: Unnessacary bump
anybody?
 

ibex

aa
Sep 1, 2013
308
528
From the little I've learned I think the material has to be an unlitgeneric to allow the texture scroll property. So no blend textures.
 

Izotope

Sourcerer
aa
May 13, 2013
698
764
I'm not entirely sure, but I believe you need to specify the basetexture in your textureScrollVar, not the bumpmap.
Try $basetexture
 

Blade x64

Logical insanity
aa
Sep 3, 2009
239
633
You didn't contain the texture scroll proxy within "proxies". You're also scrolling the bumpmap with bumpmaptransform. Basetexturetransform handles both that and the basetexture.

Code:
"Proxies"
{
  "TextureScroll"
  {
    "textureScrollVar" "$basetexturetransform"
    "textureScrollRate" 0.25
    "textureScrollAngle" 90
  }
}

If proxies are supported in world blends, chances are it would use basetexturetransform2 or basetexture2transform for the second texture.

You can read more on texture manipulation here: http://www.nodraw.net/2010/01/dynamic-materials-with-proxies/.
 

Pocket

Half a Lambert is better than one.
aa
Nov 14, 2009
4,694
2,579
From the little I've learned I think the material has to be an unlitgeneric to allow the texture scroll property. So no blend textures.
Whether this is true or not, from a purely logistical perspective, your blend mask wouldn't scroll along with the individual textures because it's defined by the vertices of the displacement. Open up the texture tool, select the faces you're trying to scroll, and hold down one of the arrow buttons to shift the X or Y offset and watch what happens; that's more or less what you'd get if you were able to scroll the texture.