Issue with GLTF loader?

hi all! How can I apply all of my model’s textures to the appropriate parts of my GLB model? So I have a stork loaded in GLB format & would like to apply the correct textures to the correct parts of the model.

Here is the code I have :

var loader = [ ];

loader [ 0 ] = new THREE.GLTFLoader ( );

var scene = new THREE.Scene ( );

LoadModel = function ( scene, loader, fileLocation ) {

    textureLoader = new THREE.TextureLoader ( );
    texture = textureLoader.load ( 'assets/models/glb/green.png' );
    texture.flipY = false;

    modelobj = loader.load ( fileLocation, function ( gltf ) {

        model = gltf.scene;
        console.log ( model );
        texture.flipY = false; // for glTF models only
    model.children [ 0 ].material.map = texture;
        scene.add ( model );

    } );

    return ( modelobj );

}

LoadModel (
    scene, loader [ 0 ], 'assets/models/glb/stork.glb'
);

Any help is GREATLY appreciated!

Thank You! <3

We cannot help you without more information. Are the model and the texture designed to work together, or can you share them?

If you want the texture to apply to specific parts of the model, the model must have a UV map (or “texture coordinates”) designed to allow that to happen. I would recommend doing this in Blender, look for youtube videos on texturing and creating UV maps.