A Hat in Time

A Hat in Time

Not enough ratings
Making custom animations compatible with Online Party Animation Repair Tool
By Shararamosh
So, you're a modder and you want your custom Hat Kid-like AnimSet and/or AnimTree to be compatible with Online Party Animation Repair Tool but don't know what to do? Not a problem, in this guide I'll tell you everything you need to do.
   
Award
Favorite
Favorited
Unfavorite
Creating custom ObjectReferencer class with your AnimSets and/or AnimTrees
In case of Online Party Animation Repair Tool ObjectReferencer class is used to hold an array of AnimSets and AnimTrees for Hat Kid-like characters to sync them with online players. Do the following to make it right:
  1. Create a new class by extending ObjectReferencer, name it anything you want (considering that tag you set in the next part of this guide does not exceed 64 symbols) and save it in your Classes folder. It should look something like this (I used the name NewAnimSetInfo):
    class NewAnimSetInfo extends ObjectReferencer;
  2. Add one or several AnimSets to the ReferencedObjects array in defaultproperties. Create defaultproperties structure, copy your AnimSet's full name to clipboard and put it in ReferencedObjects array. Here's how it looks like for array with one AnimSet:
    class NewAnimSetInfo extends ObjectReferencer; defaultproperties { ReferencedObjects.Add(AnimSet'Persona5_AOAPoses_Package.AnimSets.HatKid_Poses_Anims') }
    In the above example I used AnimSet that contains Joker's Final Taunt animation.
    If you want to add more than one AnimSet, just repeat this line but with another AnimSet.
    In case you want to make OPART to consider your custom AnimTree Hat Kid-like and allow all of the custom animations to be properly displayed when used by player using this AnimTree, you should add full path to this AnimTree to the same Array. Here's how it would look like with one AnimSet and one AnimTree:
    class NewAnimSetInfo extends ObjectReferencer; defaultproperties { ReferencedObjects.Add(AnimSet'Persona5_AOAPoses_Package.AnimSets.HatKid_Poses_Anims') ReferencedObjects.Add(AnimTree'HatInTime_Characters.AnimTree.PlatformPlayer_AnimTree') }
    In the above example I used Joker's Final Taunt AnimSet and standard Hat Kid's AnimTree. Standard Hat Kid's AnimTree is supported natively, so you should only add your own custom AnimTrees. There can be several of them - all of them will be considered Hat Kid-like.
  3. Save your class and open your GameMod class.
Editing your GameMod class to support custom animations
Now that we're done with ObjectReferencer class we need to make one edit to the GameMod class we use.
  1. If you don't have defaultproperties structure In your GameMod class then add it. After doing it add the following line to it:
    Tag = "HatKidAnimSet NewAnimSetInfo"
    Where NewAnimSetInfo is the name you used for your ObjectReferencer extended class.
    Once again make sure that Tag you set does not exceed 64 symbols. If it does, re-name your ObjectReferencer extended class to shorter name and copy and paste this new name instead of the old one to the Tag.
    If this Tag is the only thing in your GameMod's defaultproperties then it will look like this:
    defaultproperties { Tag = "HatKidAnimSet NewAnimSetInfo" }
  2. Save your GameMod class, compile scripts and cook the mod.
Congratulations, you've made your mod support Online Party Animation Repair Tool!
1 Comments
Shararamosh  [author] 10 Feb, 2021 @ 1:40pm 
I will not respond to the off-topic comments.
I will remove them.
Please don't be a stupid potato.
Follow the guide.
For any other help about A Hat in Time mods you can contact me at Discord:
Шарарамош#7170