Skip to content

Commit

Permalink
Added some vertex animation documentation.
Browse files Browse the repository at this point in the history
Started documenting model/engine links.
  • Loading branch information
Five-Damned-Dollarz committed Mar 9, 2021
1 parent d4353ec commit b4a0601
Show file tree
Hide file tree
Showing 5 changed files with 87 additions and 5 deletions.
13 changes: 8 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# io_scene_lithtech

This addon is forked from [io_scene_abc](https://github.com/cmbasnett/io_scene_abc), renamed to io_scene_lithtech due to the increased scope.
This addon is forked from [io_scene_abc](https://github.com/cmbasnett/io_scene_abc), renamed to io_scene_lithtech due to the increased scope.

This addon provides limited support for importing and exporting various Lithtech models formats from [No One Lives Forever](https://en.wikipedia.org/wiki/The_Operative:_No_One_Lives_Forever) to and from Blender 2.8x.
This addon provides limited support for importing and exporting various Lithtech models formats from [various games](https://en.wikipedia.org/wiki/LithTech#Games_using_LithTech) such as [Shogo](https://en.wikipedia.org/wiki/Shogo:_Mobile_Armor_Division), and [No One Lives Forever](https://en.wikipedia.org/wiki/The_Operative:_No_One_Lives_Forever) to and from Blender 2.8x/2.9x.

## How To Install

Download or clone the repository, and zip up the `src` folder. Go to `Edit -> Preferences` in Blender 2.8x, select `install` and then select the zip file you just created.
Download or clone the repository, and zip up the contents of the `src` folder. Go to `Edit -> Preferences` in Blender 2.8x/2.9x, go to the `Add-ons` tab, select `install` and then select the zip file you just created.

To download the respository, click the green `Code -> Download ZIP` at the top of the main page.

Expand All @@ -16,7 +16,8 @@ To download the respository, click the green `Code -> Download ZIP` at the top o

Format | Import | Export
--- | --- | ---
ABC | Rigid and Skeletal | Limited
ABCv6 | Full | Full
ABCv13 | Rigid and Skeletal | Limited
LTA | No | Rigid and Skeletal
LTB (PS2) | Rigid and Skeletal | No
LTB (PC) | Rigid and Skeletal | No
Expand All @@ -31,10 +32,12 @@ Additional format information can be found in [here](https://github.com/haekb/io
- Imported skeletal meshes are mirrored on the X axis (They're flipped back on export!)
- Converters may not provide 1:1 source files
- Converters don't convert lods!
- ABCv6 sometimes exports vertex animation nodes with an odd rotation

![](https://raw.githubusercontent.com/haekb/io_scene_lithtech/master/doc/readme/example.png)

## Credits
* **Colin Basnett** - Programming
* **ReindeerFloatilla** - Research
* **Haekb** - Programming / Research
* **Haekb** - Programming / Research
* **Amphos** - Programming
58 changes: 58 additions & 0 deletions doc/abc-v6-anim-engine-links.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
## ABCv6 Node Names

For dismemberment/locational damage system:

- head
- neck
- torso
- pelvis
- ru_arm
- rl_arm
- r_hand
- lu_arm
- ll_arm
- l_hand
- lu_leg
- ll_leg
- l_ankle
- l_foot
- ru_leg
- rl_leg
- r_ankle
- r_foot
- obj
- l_gun
- r_gun

## ABCv6 Animation Names

Animation names for PV weapon models:

- static_model
- idle
- draw
- dh_draw
- holster
- dh_holster
- start_fire
- fire
- end_fire
- start_alt_fire
- alt_fire
- end_alt_fire

## ABCv6 Frame String Commands

- fire_key:optional int attack_num
- show_weapon:int weapon_num
- extra_key:unknown
- play_sound:string sound_file
sound_random:int max
sound_radius:int radius
sound_volume:int volume
sound_chance:int chance [0-100]
sound_voice:bool is_voice

Examples:
For a gun's PV animation to deal damage the actual fire frame needs: fire_key
To play mon_footstep_1.wav or mon_footstep_2.wav randomly whenever a footstep frame happens: [play_sound:mon_footstep_][sound_random:2][sound_volume:50]
21 changes: 21 additions & 0 deletions doc/abc-v6-vert-anim-basics.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
Vertex animations utilize the shape key feature of Blender.

An example .blend can be found [here](./abc-v6-export-basics/minimal_abc-v6_vert_anim.blend)

## Basics
The exporter will ignore vertex animations entirely if you have less than 2 shape keys.

![](./abc-v6-vert-anim-basics/action_list.png)

For every action, you need to add shape keys equal to the number of keyframes in that action. They should be named the same as the corresponding action, eg. if you have an alt_fire animation, your shape keys should be named alt_fire_0, alt_fire_1, alt_fire_2, and so on.
**Note:** the names after the action name don't matter, but the order does. If alt_fire_2 is the highest in the list it will be attached to the first keyframe.

![](./abc-v6-vert-anim-basics/shape_keys.png)

Even if you don't want vertex animations for a certain action you'll have to create shape keys for it.

# Issues
- Currently there's a bug that affects few vertex animated nodes, they export with a slightly incorrect rotation or translation.

## Misc. Tips
- I usually set the shape key to absolute, and add "d_" prefixed actions to animate the shape keys.
Binary file added doc/abc-v6-vert-anim-basics/action_list.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/abc-v6-vert-anim-basics/shape_keys.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit b4a0601

Please sign in to comment.