Is there really only one animation that is exactly played in reverse? My guess would have been that they just duplicated the animations when that block was reusing one.
//First I make an int array with valid (Not == -1 in Anim lookup) AnimIDs in it//then I start to mapif(131 in AnimIDs){ ID=131;//131 is Drown} else { ID=0;}Flag=3;//3 means Freeze which is what happens with Drowned as you don't move after
void CGUnit_C::UpdateLootAnimKit (int desired){ uint current_state = this->current_anim_kit ? this->current_anim_kit->GetID() : 0; uint new_state; if ( this->IsLooting() && this->ShouldKneelForLoot() ) { new_state = (desired == 0 && current_state > 203) ? 204 : 202; } else { new_state = current_state == 202 ? 204 : 0; } if ( current_state != new_state ) { if ( this->current_anim_kit ) { this->current_anim_kit->SetStopCallback (0LL, 0LL); this->current_anim_kit->Stop (1, 0LL); this->current_anim_kit->Release(); } if ( new_state ) { this->current_anim_kit = this->animKitManager->PlayAndMaintain (new_state, (ANIMATIONDATAENUM)-1, 0LL); if ( this->current_anim_kit ) { this->current_anim_kit->SetStopCallback (&UnitCallbacks::LootAnimKitStopCallback, this->field_2050); } } else { this->current_anim_kit = 0LL; } }}
Seeing as I spent about 5 hours to get to the point of being able to show you that code with confidence, I don't think it qualifies as cheating too much.
In addition to hardcoded animkits, there is also fallbacks for some in dbcs: flystand, flyhover, flyshuffleleft/right, flymount, flyfly, flydrown, flydrowned, open, close, opened, closed.
Note : This apply only when there is no real animation for the action.Flag | Name | AnimID | From3 Dead 6 Death0 CombatCritical 10 CombatWound1 Walkbackwards 13 Walk1 SwimBackwards 45 Swim3 SitGround 97 Sit3 Sleep 100 SleepDown1 SleepUp 101 SleepDown3 KneelLoop 115 Kneel3 UseStandingLoop 123 Stand3 Drowned 132 Drown0 JumpLandRun 187 Run3 LootHold 188 Loot1 LootUp 189 Loot
short Fallback[226];//*Extract Fallback IDs from the DBC or put them by hand in the Fallback array*short getTrueID(short ID){ if(ID in AnimIDs){ return ID; } return getTrueID(Fallback[ID]);}