See examples/animations/md3_animations_tags for a demo of MD3 support using Tremulous data.
We support almost everything useful from the MD3 file format:
Geometry, possibly textured.
Animations.
We read optional animation.cfg
file alongside the MD3 model that defines animations inside the MD3 file.
Note
|
CGE assumes that all animations from animation.cfg are suitable for the accompanying MD3 file, as long as the number of animation frames is sufficient. It is the developer’s responsibility to actually use only the animations that make sense for given MD3 model. Some games place multiple MD3 files in the same directory with one animation.cfg , and there are game-specific assumptions which animations make sense for which MD3 model. E.g. Tremulous human models have animations like BOTH_xxx (that make sense to play on both upper.md3 and lower.md3 ) and TORSO_xxx (that make sense to play only on upper.md3 ).
|
Without the animation.cfg
file, the MD3 will only contain one long animation called animation
that plays all available frames. You can still use manual approach to play any subrange of this animation, see examples/animations/split_long_animation.
See also the demo of playing animations on Tremulous creatures. You can test playing MD3 animations using Castle Model Viewer.
Skins.
We read optional "skin file" alongside the MD3 model that maps MD3 "shader" names to textures.
By default we read the default
skin, from file xxx_default.skin
.
You can choose a different skin by appending anchor #skin:xxx
to the URL. E.g. loading URL head.md3
will load skin from head_default.skin
, but loading URL head.md3#skin:light
will load skin from head_light.skin
.
Tags.
Tags in MD3 are animated transformations that (by default) don’t show anything.
They can be used together with our ExposeTransforms mechanism to attach things to them, e.g. you can attach a weapon model to a specific place in the character. This allows the weapon to realistically follow the movement of the character’s hands.
To improve this documentation just edit this page and create a pull request to cge-www repository.