I have very little Godot shader experience myself, but looking through some things, I found this question from the Godot QA. It seems the user was wanting to do something very similar to what you are wanting to do, and in the answer provide there is a link to a shader that you may be able to use as a reference.
There is also this post here on the forums where a user posted some code for blending based on vertex color. As far as I know it does not take multiple texture channels into consideration, just the albedo/color texture, but in theory it shouldn't be too hard to modify for multiple texture channels.
Hopefully this helps :smile: