Jump to content

Custom Material Property (2 questions)


Pancakes
 Share

Recommended Posts

1. Hello. I'm trying to make it so I can assign whatever material I want to a model inside of the editor. I was using the Paint command but I forgot, even though I'm looking at examples right now, how to make it so I can enter in a file name in the custom script menu and have it set the right key so the material will be assigned.

 

2. Anyway, will this hurt performance because let's say I have 2 of the same cube.gmf, but because one is using default material and another is using a different material will that hurt performance?

 

thanks, this could solve all my material problems if I can do it this way

Core I5 2.67 / 16GB RAM / GTX 670

Zbrush/ Blender / Photoshop CS6 / Renoise / Genetica / Leadwerks 3

Link to comment
Share on other sites

not sure i follow but:

 

1) Do you mean this as your model's lua script?

require("scripts/class")
local class=CreateClass(...)

That gives you the standard properties for a model, and one of the options in the Appearance tab in the properties dialog is material.

 

2) Unless you get real creative with using the alpha color to assign the texture coordinates for a particular image on one texture that has multiple images, then you can only have one material per model. So if you assign a material to cube.gmf, then the next cube.gmf will have this texture as well. But if you are talking about a cube that you are creating via CreateCube() then you can paint it whatever you want for each instance.

Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590

LE / 3DWS / BMX / Hexagon

macklebee's channel

Link to comment
Share on other sites

ah okay thanks, the problem was that sometimes the materials option doesn't show up under the appearence tab, even when it had shown up before for the same model. For instance I placed cube into the scene, then used the class script to assign a material, saved the scene, and it all worked. When I opened the same scene again, the material is still successfully applied but the materials is no longer showing up undedr the appearance tab. In fact it doesn't show up at all. Well that's half the problem the other half is that sometimes for some reason my .obj files were exporting without materials

 

Well anyway it's pretty weird, but at least with ADN material editor by Icare it's a whole lot better than it would be otherwise at least for my situation.

 

Maybe this was an old bug that has already been fixed. I am still using 2.31 because I prefer the SSDO and I still can't figure out how to move the SSDO to a newer version

Core I5 2.67 / 16GB RAM / GTX 670

Zbrush/ Blender / Photoshop CS6 / Renoise / Genetica / Leadwerks 3

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...