Unsolved Renaming Prefeb materials

Discussion in 'Mod Support' started by Ax50, Dec 3, 2023.

  1. Ax50

    Ax50
    Expand Collapse

    Joined:
    Aug 12, 2019
    Messages:
    503
    What's the procedure to rename materials used in a prefab so they don't conflict with the games original files when making a scenario?
     
  2. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    620
    A prefab itself has no materials since it’s a collection of dae assets packed together. If you use assets from the level you don’t have problems. If you have two different materials with the same name you could open the model in blender, rename the material to a unique name, export the model as dae again, change the name and mapto field in materials json and then you should be safe after a reload of the map.
     
  3. Ax50

    Ax50
    Expand Collapse

    Joined:
    Aug 12, 2019
    Messages:
    503
    Thanks for the precision. I just don't understand the last sentence "change the name and map to field in materials json.", should I rename something to "field" in one of the .json files?

    Also, is there a place where all of this is explained in detail? I couldn't find any info on how to pack missions/scenario mods for repo sharing here yet everybody seems to know how to do it...
     
  4. AlexKidd71

    AlexKidd71
    Expand Collapse

    Joined:
    Mar 16, 2022
    Messages:
    620
    Every material in the material json has the two fields: name, mapto at the beginning. Name is the name in the world editor, mapto has to be filled with the materialname in the dae file so that the game can map the material defined in the game with the material in the 3d model. Most of the time the fields are both filled with the materialname from the model.

    I didn’t do a scenario myself but there are some videos on YouTube.
     
    #4 AlexKidd71, Dec 3, 2023
    Last edited: Dec 3, 2023
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice