Jump to content

Converting Models in Blender


Recommended Posts

I'm usually pretty good at finding stuff online and I just hit the motherload in free, low poly woodland models. Trees, shrubs, weeds, grass...pretty much everything I need. Each model has a default skin in .png or paint.net file type and the models are in .3ds, .b3d, .dbo, .dts, .mdl, .ms3d, .mtl, .obj, and .x formats. 

 

What would be the process for converting these to .md3, What about the texture they all share? Is it just a simple resize and putting the new model into Map Objects/ ??????? with the texture? 

Link to comment

Import .obj in a package that supports .md3 and export. You said each model as a default texture and then ask about the texture they all share?? Does that mean some of them have unique textures and additional parts shared (live leaves or something)?

Link to comment

Here's a screenshot of what I'm dealing with for one particular Pine Tree model.

 

All the models listed in various formats are all the same mesh or f_pinteree1. The two images (one I opened) are the same, just different formats, which you can see on the left. I know I can import an .obj into Blender and spit out and .md3 since I have the plugins. Now, when I import the .obj do I have to anything else than re-size it when exporting? 

 

model%20stuff_zps79abuwba.jpg

Link to comment

I think just follow the standard procedure of Mr Wonko's plugin. Set the custom properties to

'md3shader'

'path/to/texturesNoFileExtension'

 

then 'Export md3' and put the file path of the md3 (with extension) in the md3 name field.

 

I exported one and the trunk and texture turned out alright but the branches got all messed up. Their texture also didn't have the transparency, either. 

 

shot0014_zpsgqnurwke.jpg

 

Here is what it is supposed to look like.

 

pinetr1-polys493_zpseovhemmc.jpg

Link to comment

First: I saw a two image with the same name but with diffrent formats. Choose one transparent format and delete the other one. The game maybe reads image that is not working good with the image

 

Second: Make sure the shader is for this format. I think the shader for TGA looks diffrent than shader for PNG

 

Third: Show use the shader

Edited by Langerd
Link to comment

I exported one and the trunk and texture turned out alright but the branches got all messed up. Their texture also didn't have the transparency, either. 

 

shot0014_zpsgqnurwke.jpg

 

Here is what it is supposed to look like.

 

pinetr1-polys493_zpseovhemmc.jpg

 

this is a shader problem, create a shader of pine leaves and branch like this:

 

models/map_objects/MODMODELS/Pine_branchs

{

    q3map_material    GreenLeaves

    polygonOffset

    cull    disable

    deformvertexes    wave    256 sin 0 0.5 0.2 0.6

    q3map_onlyvertexlighting

    {

        models/map_objects/MODMODELS/Pine_branchs

        alphaFunc GE128

        depthWrite

        rgbGen identity

    }

    {

        map $lightmap

        blendFunc GL_DST_COLOR GL_ZERO

        depthFunc equal

        rgbGen identity

    }

} NOTE: use deformvertexes ONLY for leaves for create the illusion of movement affected by wind. if not, not use this parameter.

Link to comment

} NOTE: use deformvertexes ONLY for leaves for create the illusion of movement affected by wind. if not, not use this parameter.

 

Unlikely... unless he can get a working .skin of the model and reassign separately branches and trunk, that shader will get the whole tree to deform. Which would be good for a Halloween map, but not for a more realistic one. Notice what the texture looks like:

 

 

model%20stuff_zps79abuwba.jpg

Link to comment

Alrighty... I'm ALMOST there....I imported a .3ds instead of a .obj just to for a change, flipped the normals, and my pine tree exported properly. I'm still running into an issue with the transparency on the branches showing up black. This happens in MD3 view which will happen in game as well.

 

So, how the heck do I get rid of that one last issue? 

Link to comment

The MD3viewer doesnt read shaders i think. So You must check it in the game to see if it works.

Yes. I've been using ModView, MD3View, and all the rest for years - they never show shaders, that's how they're done. They're not like Blender and the rest of 3D programs that view the whole scene, they only display model itself... And without environment, there is no shadering. ;)

Link to comment

Good point of Ramikad, make two separated meshes, one for bark and one for branchs, so you can apply different shaders. :)

and so you can use deformvertexes on branch and not use this on trunk. for trunk put on

string

q3map_material SolidWood

instead of

greenleaves.

 

check the path of your shader file. the shaders are putted into Shaders folder and the file txt need to get a .SHADER extension.

;)

Link to comment

If things look messed up after MD3 export from Blender - did you forget to triangulate before you exported (CTRL T)?

 

For applying the shader, make sure that the path under 'md3shader' in Custom Properties (in Blender) is pointing to the path of your shader, not the texture you're using (although it might work if they have the same name).

 

Example:

 

md3shader

models/map_objects/trees/nameOfShader

 

 

Shader (file most likely located something like base/shaders/IrocJeffsMap.shader):

 

models/map_objects/trees/nameOfShader

{

     //content with stages pointing to your  texures, with appropriate blending modes etc...

}

Link to comment

If things look messed up after MD3 export from Blender - did you forget to triangulate before you exported (CTRL T)?

 

For applying the shader, make sure that the path under 'md3shader' in Custom Properties (in Blender) is pointing to the path of your shader, not the texture you're using (although it might work if they have the same name).

 

Example:

 

md3shader

models/map_objects/trees/nameOfShader

 

 

Shader (file most likely located something like base/shaders/IrocJeffsMap.shader):

 

models/map_objects/trees/nameOfShader

{

     //content with stages pointing to your  texures, with appropriate blending modes etc...

}

You are right something could be not right with the model too . But if for example normals would be flip wrong ... The func twosided in the shader should solve the problem.

 

In my opinion it is still shader issue. And adding it to the shaderlist shouldnt be required for this one

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...