User Tools

Site Tools


modelediting

This is an old revision of the document!


Model Editing

The below was taken from Greths notes on the IGF .. As I go I will reformat and expand up this

Near the end is a link to a ZIP file with some model packages. Here's an overview on what the files are, and how to perform the basic conversions necessary for importing them into your editor of choice.

[b]Common files[/b] Most files in the packages are self explanatory: .png - Textures or icons. *Tint.png - Specialized textures for defining adjustable color regions, like the kind used in character creation. .colormap - Each Tint.png has one of these (a simple text file) matching the color regions to their names. .mesh - Binary file containing the Ogre mesh. .skeleton - Binary file containing the Ogre bone structure (coincides with the mesh file). .anim - Binary file containing the keyframes of a single named animation (Idle, Walk, etc). .material - A text file with render information, often associated with icons. Player races and creatures used centralized materials defined elsewhere.

[b]Convert existing EE meshes[/b] You'll need a program called OgreXMLConverter. It's available from the Ogre Command-Line Tools package. [link]http://www.ogre3d.org/download/tools[/link]

Although it's a console application, you can drag and drop the .mesh and .skeleton files onto OgreXMLConverter to convert them back and forth between binary and .xml formats. But first you must edit EE's meshes.

EE's meshes have a custom defined serializer string, which you'll need to hex edit back to something that OgreXMLConverter recognizes. To do this: Open in a hex editor, any will do. Near the beginning of the file there's a part that looks like this: [MeshSerializer_v1.40o]

Simply delete the 'o' so it looks like this: [MeshSerializer_v1.40]

Save it. OgreXMLConverter should now be able to open it.

[b]Creating new assets[/b] If you have a new model from somewhere and can export it to Ogre mesh/skeleton format, it should work just fine in EE. The Torchlight 2 pets demonstrate that feat.

[b]Editing the mesh[/b] Search for an Import script for your 3D program of choice. If you use Blender, [url=http://code.google.com/p/torchlight-to-blender/]Torchlight To Blender[/url] is good choice, but it doesn't support animations. There are others out there, even one that does support animations to some extent, but you may need to Google them (I haven't kept up to date). Most scripts usually require changing a few parameters inside them, often a path to the OgreXMLConverter utility.

You'll need Export scripts to save them back out. For Blender, there's a link to Blender Exporter in the Tools page above. Depending on which editor, and which version it is, you may need different scripts. Google is your friend.

Here are [url=http://planetforevergame.com:81/DevStuff/ModelSamples.zip]some models[/url] to get started. Biped-Male: The default male body. The animations are shared for both male and female. The base body types are shared for all races, and do not contain faces, tails, or forearms. Biped-Hart_Male: The race-specific stuff for male hart. Face, tail, horns, etc. Boss-Dragon: Demonstrates how simple creatures are. Includes sound files too. Item-1hSword-Basic1: Simple item mesh. Prop-Wooden_Furniture: A collection of many props (provided as is, you'll have to convert them yourself) Converted: An extra folder where I tossed some pre-converted mesh and skeleton XML files for the other models. The binary .skeleton files in this folder contain all the animation data, consolidated from the .anim files. The files in the other folders are provided as is (except for some altered serializer strings).

Requested asset packs can be found in the [url=http://planetforevergame.com:81/DevStuff/Assets/]Assets folder[/url]. Similarly, specifically requested textures can be found in the [url=http://planetforevergame.com:81/DevStuff/Textures/]Textures folder[/url].

These zip files contain all the prop data (textures, meshes, XML files). The mesh files will need binary editing in the post above to use.

Prop-Church1 : Church_Altar1, Church_Rug Prop-Paintings1 : Painting1, Painting1a Prop-Tribal_Furniture : Tribal_{Chair1, Lamp_Unlit, Lamp1, Plate1, Rack, Rug, Stool1, Table1}

modelediting.1381746504.txt.gz · Last modified: 2013/10/14 11:28 by rockfire