function addAllClothing(scene){
            //loop to add all clothing instead of individual lines
            function addAllClothingOfType(numberofClothes,clothingNameString,clothingType){
                for (let i = 1; i <= numberofClothes; i++){
                    createClothing(clothingNameString+i,clothingType,scene);
                }
            }
            addAllClothingOfType(16,"hat",clothingTypes.hat);
            addAllClothingOfType(15,"shoe",clothingTypes.shoe);
            addAllClothingOfType(16,"shirt",clothingTypes.shirt);
            addAllClothingOfType(16,"pants",clothingTypes.pants);
        }
//Adds clothing assets to the scene
Adds clothing assets to the scene
Adds clothing assets to the scene
function addAllClothing(scene){
            function addAllClothingOfType(numberofClothes,clothingNameString,clothingType){
                for (let i = 1; i <= numberofClothes; i++){
                    createClothing(clothingNameString+i,clothingType,scene);
                }
            }
            addAllClothingOfType(16,"hat",clothingTypes.hat);
            addAllClothingOfType(15,"shoe",clothingTypes.shoe);
            addAllClothingOfType(16,"shirt",clothingTypes.shirt);
            addAllClothingOfType(16,"pants",clothingTypes.pants);
        }
function addAllClothing ( scene ) { function addAllClothingOfType ( numberofClothes , clothingNameString , clothingType ) { for ( let i = 1 ; i <= numberofClothes ; i ++ ) { createClothing ( clothingNameString + i , clothingType , scene ) ; } } addAllClothingOfType ( 16 , "hat" , clothingTypes . hat ) ; addAllClothingOfType ( 15 , "shoe" , clothingTypes . shoe ) ; addAllClothingOfType ( 16 , "shirt" , clothingTypes . shirt ) ; addAllClothingOfType ( 16 , "pants" , clothingTypes . pants ) ; }
Adds clothing assets to the scene
Adds clothing assets to the scene
//loop to add all clothing instead of individual lines