This wiki is archived and useful information is being migrated to the main bzflag.org website

Editing Modeltool

Jump to: navigation, search

Warning: The database has been locked for maintenance, so you will not be able to save your edits right now. You may wish to copy and paste your text into a text file and save it for later.

The administrator who locked it offered this explanation: Archived wiki

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 3: Line 3:
 
In normal operation it converts wavefront.obj files to .bzw mesh. The easiest way to do this is to place both the modeltool binary and an obj file in a directory, then open your terminal  and cd to that directory, and ./modeltool your_filename.obj.  A bzw format file will be created, with your mesh inside of it.
 
In normal operation it converts wavefront.obj files to .bzw mesh. The easiest way to do this is to place both the modeltool binary and an obj file in a directory, then open your terminal  and cd to that directory, and ./modeltool your_filename.obj.  A bzw format file will be created, with your mesh inside of it.
 
    
 
    
===Modeltool Arguments:===
+
Modeltool Arguments
{|{{Prettytable}}
+
-g <name>       : use group definition
|-
+
  -tx <dir>       : set texture prefix
| {{Hl3}} |'''Argument'''
+
  -m         : disable materials (matref)
| {{Hl3}} |'''Description'''
+
  -sm         : use the smoothbounce property
|-
+
  -yz         : flip y and z coordinates
| -g <name> || use group definition.
+
  -n         : disable normals
|-
+
  -t         : disable texture coordinates
| -tx <dir> || set texture prefix.
+
  -a         : disable ambient coloring
|-
+
  -d         : disable diffuse coloring
| -m || disable materials (matref).
+
  -s             : disable specular coloring
|-
+
  -s             : disable shininess
| -sm || use the smoothbounce property.
+
  -sf <val>       : shine multiplier
|-
+
  -e             : disable emission coloring
| -yz || flip y and z coordinates.
+
  -gx <val>       : scale the model by this factor
|-
+
  -gsx <val>     : shift the map by this value in X
| -n || disable normals.
+
  -gsy <val>     : shift the map by this value in Y
|-
+
  -gsz <val>     : shift the map by this value in Z
| -t || disable texture coordinates.
+
  -bspskip <val> : skip faces with this material when importing a bsp
|-
+
| -a || disable ambient coloring.
+
|-
+
| -d || disable diffuse coloring.
+
|-
+
| -s || disable specular coloring.
+
|-
+
| -s || disable shininess.
+
|-
+
| -sf <val> || shine multiplier.
+
|-
+
| -e || disable emission coloring.
+
|-
+
| -gx <val> || scale the model by this factor.
+
|-
+
| -gsx <val> || shift the map by this value in X.
+
|-
+
| -gsy <val> || shift the map by this value in Y.
+
|-
+
| -gsz <val> || shift the map by this value in Z.
+
|-
+
| -bspskip <val> || skip faces with this material when importing a bsp.
+
|}
+
  
 +
 
 
In drawinfo mode, a third file, called a diconf is required. This is a plain text file, named with the extension .diconf
 
In drawinfo mode, a third file, called a diconf is required. This is a plain text file, named with the extension .diconf
  
===DIconf Arguments:===
+
DIconf Arguments
{|{{Prettytable}}
+
-lod 0 filename.obj :Specify a mesh to convert
|-
+
-angvel <val>         : Apply angular motion to the drawinfo. In radians per second.
| {{Hl3}} |'''Argument'''
+
  -nomats                   : do not write materials.
| {{Hl3}} |'''Description'''
+
  -bounds                   : compute the bounds and sphere for draw info meshes and write them to the map
|-
+
  -bounding               : generates invisible faces (and a material) to be used  for collision detection
| -lod 0 filename.obj || Specify a mesh to convert.
+
  -comments             : add comments (line numbering) to the resulting bzw file (will make it a lot larger
|-
+
  -striplimit <val>   : the longest triangle strip to use for LODs  (16 recommended)
| -angvel <val> || Apply angular motion to the drawinfo. In radians per second.
+
|-
+
| -nomats || do not write materials.
+
|-
+
| -bounds || compute the bounds and sphere for draw info meshes and write them to the map.
+
|-
+
| -bounding || generates invisible faces (and a material) to be used  for collision detection.
+
|-
+
| -comments || add comments (line numbering) to the resulting bzw file (will make it a lot larger.
+
|-
+
| -striplimit <val> || the longest triangle strip to use for LODs  (16 recommended).
+
|}
+
 
+
 
[[category:Map Making]]
 
[[category:Map Making]]
 
[[category:Map Editors]]
 
[[category:Map Editors]]

Please note that all contributions to BZFlagWiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see BZFlagWiki:Copyrights for details). Do not submit copyrighted work without permission!

To edit this page, please answer the question that appears below (more info):

Cancel | Editing help (opens in new window)

Templates used on this page: