Detail mask only applies UV1 even when set to UV2
Tested versions
v4.3.stable.steam [77dcf97d8]
System information
Windows 10
Issue description
Just trying to get a hang of material importing in Godot and I think I found a really annoying bug. I was making a road texture with the road lines as a detail texure on top. The asphalt and the roadlines have 2 seperate UVs that both imported properly
I used the detail section of the material to put the roadlines on top and set it to UV2. The roadlines need a mask to mask out just the roadlines.
Everything works fine without the mask:
But when I add the (obviously needed) mask to the detail section it reverts to UV1 even though its still set to UV2
Steps to reproduce
Take a mesh with two UV maps.
enable Detail in material, Set Detail to UV2, add Detail Mask
Minimal reproduction project (MRP)
all you have to do is go into the surface 0 material on the included model and under Detail/Mask add the Roadlines_mask.png
before you add that mask you can see UV2 is working properly. After you add the mask you can see it's still using UV1
godot hard codes the second uv for gi mapping in many places. I suggest using the uvs from 3rd to 8th uvs for this purpose.
This PR adds scale/offset as separate properties from uv2.