Instead of begging authors to make separate edits, you can modify xdR animation addons for your personal needs. This guide lists what is possible to do with regular Hex Editors and Files Browsers.
What tools needed
Addon extract
xdR anims are stored in /models/xdreanims/.
Move to different slot
- Rename .mdl and .ani (if exists) files so they have different slot indicated in their name. For ex. if we want to move Coach animations occupying slot 47 to slot 11. rename files to coach_slot_011.mdl and coach_slot_011.ani
- Open renamed .mdl file in hex editor
- Edit it so it references to new .mdl path at beginning
- Near end of file, point to new .ani path
- Save file
Disable specific sequence
Open .mdl file in hex editor. Search for Idle_Standing_Pistol text.
It may find text prefixed with a_ like a_Idle_Standing_Pistol. Don’t touch it, it’s $animation. Keep it, search next.
Needed sequence looks like this. If it has Activity id assigned to it, it usually comes after and has ACT_ prefix.
To disable it, change it’s name and act like this:
I advise changing only one letter in name and act. Name and act length must be same.
Technically, this sequence is still inside model, but it should no longer be triggered in game.
Move animation set to different character
Rename .mdl to needed character and slot.
Original .ani must be renamed so it has same length. Simply replace some letters.
Open .mdl file in hex editor.
Edit so it has new path reference. Path field is 64 bytes long like selection above shows, after .mdl there is padding filled with hex zeroes 00. You must not exceed it.
Near end of file, point to new .ani path
Convert non-xdR anim mod to xdR
Move .mdl file to xdreanims folder and rename to assigned character and slot:
models/infected/anim_charger.mdl —> models/xdreanims/charger_slot_047.mdl
.ani file must be located at same folder and must have same name length. Rename it by changing only some letters.
Edit .mdl file in hex editor so it has new path reference. Path field is 64 bytes long like selection below shows, after .mdl there is padding filled with hex zeroes 00. You must not exceed it.
Near end of file, point to new .ani path
Save file.
Advanced editing
I won’t cover the process, that’s beyond of scope of this guide. I can say though that decompiler can’t produce source files perfectly suitable for editing unless it only has some simple animations. Delta sequences will be complete garbage. Best thing you can do is to create another extension that contains your edited sequences.
After edits
Pack edited addon into .vpk by using vpk.exe or Crowbar.
Conclusion
More Guides:
- Left 4 Dead 2: How to Install “Revised Subtitles” Manually
- Left 4 Dead 2: How to Unlock “Good Ending” in “The Sacrifice” DLC
- Left 4 Dead 2: All Landmarks Location
- Left 4 Dead 2: All Melee Weapons Guide
- Left 4 Dead 2: Expert Realism Campaigns Guide