The two are totally independent. ScaleEntity only repositions vertices, not UV coords.
If you have a 256x256 terrain, a texture applied to it, by default, will be repeated 256 times along each axis.
If you scale the texture by 128x128, the texture will be repeated twice along each axis (128+128=256). Scaling the texture by 256x256 would make the texture exactly fit the terrain.
If you have a 256x256 terrain, a texture applied to it, by default, will be repeated 256 times along each axis.
If you scale the texture by 128x128, the texture will be repeated twice along each axis (128+128=256). Scaling the texture by 256x256 would make the texture exactly fit the terrain.