This is an introduction to the basic use of Cryects tools there is limitless possibilities for what you can do with his tools, but this should give you a good idea and run down of a each tool and what can be done with it along with a more technical explanation. Some of this information may be off (I've noted where I'm not completely positive about something). Feel free to correct me, or suggestion additions to this guide. A lot of this information is pulled from the WoW.Dev and Sourcepeek wiki's as well as specific user's work on the M2, ADT and WMO entries.
FileInfo
Syntax: Fileinfo <adt file>
Outputs all the ADT info about textures used, MD2's used, where the MD2's are, WMO's used, WMO Info into a text file used named after the ADT name. After running the fileinfo exe on an ADT file it outputs an text file with information pulled from that ADT file and it's corresponding chunks. The text file is set up like so (unless otherwise noted):
Code:
CHUNK_NAME CHUNK_COUNT
NUMERICAL_VALUE TREE_PATH_TO_WHATEVER_THE_CHUNK_REFERENCES
CHUNK_NAME referrers to the chuck containing information in the ADT; MWMO, MDDF and so on. Each are detailed below. CHUNK_COUNT contains how many models, wmo's etc are contained in the chunk. The NUMERICAL_VALUE is just an increasing value. Like a list. Lastly TREE_PATH_..._REFERENCES is just a treepath to the model, wmo or whatever else that chunk is referencing. Just like you would find in MWS.
MMDX Chunk:
List of filenames for M2 models that appear in this map tile.
MWMO Chunk:
List of filenames for WMOs (world map objects) that appear in this map tile.
MDDF Chunk:
This chuck is used for placement information for doodads (M2 models). This chunk is set up differently than the other chunks:
Code:
CHUNK_NAME CHUNK_COUNT
ID unique identifier Position (X,Y,Z) Orientation (A,B,C) scale factor * 1024
The instance information specifies the actual M2 model to use, its absolute position and orientation within the world. The orientation is defined by rotations (in degrees) about the 3 axes as such (this order of operations is for OpenGL, so the transformations "actually" happen in reverse):
1. Rotate around the Y axis by B-90
2. Rotate around the Z axis by -A
3. Rotate around the X axis by C
Finally the scale factor is given by an integer, multiplied by 1024. So the model needs to be scaled by scale/1024.
MODF Chunk:
Placement information for WMOs. 64 bytes per WMO instance. This chunk is set up differently than the other chunks:
Code:
CHUNK_NAME CHUNK_COUNT
ID unique identifier Position (X,Y,Z) Orientation (A,B,C) Up Ext. Low Ext. 0 Doodad Set Name Set
The positioning and orientation is done the same way as in the MDDF chunk. There is no scaling. Two additional positions and two integers are also given. The unique identifier is important for WMOs, because multiple map tiles might want to draw the same WMO. This identifier is used to ensure that each specific instance can only be drawn once. (a unique identifier is required because the model name is not usable for this purpose, since it is possible to have more than one instance of the same WMO, like some bridges in Darkshore).
ModelSwap
Syntax: <ADT File> <MDX Model to Replace> <MDX Model to Swap In>
Instead of Swapping the models and changing every single place where its located you can instead modify the appropriate ADT file to swap the model there. The only requirement is the string length of the replacement model be shorter or equal length of the model you are replacing. What this does is takes the information contained in the MMDX Chunk, which holds a list of m2's placed on a map chunk and allows you to replace that specific model with one of your choosing.
This way it only chances it for THAT adt file, rather than any adt that uses it.
MapMover
Syntax: <MapName> <LowerX> <LowerY> <UpperX> <UpperY> <NewMapName> <OffsetX> <OffsetY>
Tool that just makes it really easy to move files and renames them for you.
CreateWDT
Syntax: <MapName> <LowerX> <LowerY> <UpperX> <UpperY>
WDT files specify exactly which map tiles are present in a world, if any, and can also reference a "global" WMO. For worlds with terrain, the MWMO chunk is empty and there is no MODF chunk. For a global-WMO-only world, these chunks specify an object in the same format as it is already done in ADT files. The MWMO chunk contains a list of WMOs contained on this map tile. The MODF chunk contains placement information for the WMOs. Which is exactly the same as the MODF chunk from ADT files.
What CreateWDT allows you to do is create a valid WDT file for the specified map name for a rectangle of ADT's between (LowerX,LowerY) to (UpperX, UpperY)
OffsetFix
Syntax: <MapName> <ZOffset Optional Default=0>
After moving ADT files there is a chance they become messed up, this allows you to change the ZOffset so that you do not fall to your death, etc. when zoning into an instance.
RemoveTheWalls
Syntax: <ADT File>
Disables all invisible wall chunks in the ADT file.
LoadInfo
Syntax: <adt file>
Takes the info outputted from FileInfo and reloads it into a file be careful minor errors result in major issues
PatchHoles
Syntax: <adt file>
Removes all the holes from a tile.
AllWater
Syntax: <adt file> <water level> <optional waterflags default 14>
Allows you to set the entire water of an ADT tile to the specified level.
The water flags are (not 100% confirmed):
0 see through water, at top
1 nothing
2 red water
3 green water
4 NORMAL
5 nothing
6 red water
7 green water
8 see through water, at top
9 nothing
10 red water
11 green water
12 see through water, at top
13 nothing
14 red water
15 nothing
16 see through water, at top
17 nothing
18 red water
19 green water
20 DEFAULT normal
21 nothing
WMOOutdoors
Syntax: <wmo file>
This takes a WMO root file; which lists textures, materials, models, groups, visibility information etc. and converts it so that its outdoors this needed to get the water effect inside a WMO though at this time you don't get the water physics.
MakeMap
Syntax: <InstanceName> <LowerX> <LowerY> <Width> <Height>
Composites all the RAW files outputted by wowmapview into one large raw map file.
M2Modder
Syntax: <M2 FileName>
This lets you edit a lot of properties with M2 model files though its limited in a lot of ways its still a very powerful tool for model existing M2's
t - Edit Textures Definitions
t - Change Texture Type
0 Texture given in filename
1 Body + clothes
2 Cape
6 Hair, beard
8 Tauren fur
11 Skin for creatures
12 Skin for creatures #2
13 Skin for creatures #3
Texture type is 0 for regular textures, nonzero for skinned textures (filename not referenced in the M2 file!) For instance, in the NightElfFemale model, her eye glow is a type 0 texture and has a file name, the other 3 textures have types of 1, 2 and 6.
n - Change Texture File Name
This Allows you to change the name of the BLP(s) used by the M2.
f - Change Texture Flag
1 Texture wrap X
2 Texture wrap Y
u - Edit Texture Units
t - Change Texture
Alter texture number/Change Unit Texture Used.
m - Change Mapping
nTexUnits 16-bit integers starting at ofsTexUnits. (values: -1, 0, 1) (I think, feel free to correct me).
g - Change Flag
16 static textures
0 animated textures
r - Change Render Flag Used
f - Change Render Flag
1 Unlit
2 Unfogged
4 2-sided
8 ?
16 Disable z-buffer
b - Change Render Blend
0 Opaque
1 Alpha testing
2 Alpha Blending
3 Additive
4 Additive Alpha
5 Modulate
6 Deeprun Tram Glass
b - Edit Bones
t - Edit Translation
0x0C AnimationBlock (float, float, float) Animation data for translation
r - Edit Rotation
0x28 AnimationBlock (float, float, float, float) Animation data for rotation
s - Edit Scaling
0x44 AnimationBlock (float, float, float) Animation data for scaling
f - Edit Flags
8 billboarded
512 transformed
The billboarding bit is used for various things:
* Light halos around lamps must always face the viewer
* The cannonball stack model (in the Deadmines or Booty Bay), where each cannonball is a crude hemisphere, they always face the viewer to create the illusion of actual cannonballs.
p - Edit Pivot Point
0x60 float[3] Pivot point
a - Edit Animation IDs
Allows you to change the animations ID which is referenced from AnimationData.dbc (correct me if I'm wrong).
p - Edit Particles
f - Change Flags
Flags used by the Particle Emitters (Couldn't locate a list here... help would be nice). Though I believe this to be it (haven't tested):
0 "normal" particle
1 large quad from the particle's origin to its position (used in Moonwell water effects)
2 seems to be the same as 0 (found some in the Deeprun Tram blinky-lights-sign thing)
n - Change Bones
Bones used by the Particle Emitters
p - Change Position
Allows you to change a position of a texture in X Y Z format.
r - Change Rotation
0 for none
1 to rotate the particle 360 degrees throughout its lifetime
t - Change Texture
Allows you to change the texture used by a particle.
c - Change Colors
Allows you to change the colors of a Particle (Start, Mid, End format).
b - Change Blending
Allows you to change the blending mode of a particle.
0 Opaque
1 Alpha testing
2 Alpha Blending
3 Additive
4 Additive Alpha
5 Modulate
6 Deeprun Tram Glass
y - Change Emitter Type
1 Plane (rectangle)
2 Sphere
3 (Spline?)
s - Change Sizes
Particle sizes (start, mid, end)
a - Edit Animation Block
0 - Emission Speed
1 - Speed Variation (range 0 to 1)
2 - Rotation \\Tumble Spread (range 0 to pi)
3 - ? (range: 0 to 2pi)
4 - Gravity
5 - Lifespan
6 - Emission Rate
7 - Emission Area Length
8 - Emission Area Width
9 - Gravity? (much stronger)
r - Edit Ribbons
N/A
PExtracter
Syntax: <M2 Filename>
Extracts all the particles from a file to a separate file just containing the particles
PInjector
Syntax: <M2 Filename> <Particle Filename>
Replaces the particles of the model with the particles from the particle file.
LayerAdder
Syntax: <M2 Filename>
Adds a second layer to a model based on a specified texture. (doesn't add anything else which you might need to do by hand)
LightsOut
Syntax: <WMO Filename>
Sets all lights from WMO's of both the root & group to pitch black editing the source you can set it up to alter the lighting to a specific color (think of Sno's Frozen Core :P). In the LightsOut source lights are set by changing this (0xff000000, which is pitch black) to the color you would like. It's structured as so:
0xff(alpha)
00(red)
00(green)
00(blue)