Jump to content

Getting the name of the model.


Einlander
 Share

Recommended Posts

Thanks, it seems to work. The goal is to build a house with sub models: Roof, building, steps. I will create a prefab that a script will be attached to. This script will choose a color from a pre-specified list. It will then look for all the children, check their surfaces and get materials. If the materials match a pre-made list of black and white textures it will change the color of that material and reapply it to the mesh. This will happen in onstart. The result will be houses that have different colors every time you load the level. Also each house that is put in the level will have a different color. This will break up the monotony of having the same house in close vicinity.

  • Upvote 2
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...