Release Healer Man 0.1.9
This commit is contained in:
1 parent
c245a199b6
commit
d060296ade
74 files changed
+5901
-334
No files matched your search
@@ -32,6 +32,12 @@ type RunewakerCombatMotion = "melee" | "bow" | "spell";
|
||||
|
||||
export type CharacterBaseMotion = "idle" | "walk" | "run";
|
||||
|
||||
export type CharacterWeaponStance =
|
||||
| "bow"
|
||||
| "one-handed"
|
||||
| "two-handed"
|
||||
| "two-handed-left";
|
||||
|
||||
export interface CharacterClipSelection<TClip extends NamedAnimationClip> {
|
||||
readonly clip: TClip;
|
||||
readonly loop: boolean;
|
||||
@@ -108,7 +114,21 @@ export function selectWoWAnimationVariation<TClip extends NamedAnimationClip>(
|
||||
export function selectCharacterBaseClip<TClip extends NamedAnimationClip>(
|
||||
clips: readonly TClip[],
|
||||
motion: CharacterBaseMotion,
|
||||
weaponStance?: CharacterWeaponStance,
|
||||
): TClip | undefined {
|
||||
if (motion === "idle" && weaponStance) {
|
||||
const readyIds = weaponStance === "bow"
|
||||
? [109, 29, 26]
|
||||
: weaponStance === "one-handed"
|
||||
? [26]
|
||||
: weaponStance === "two-handed-left" ? [28, 27] : [27, 28];
|
||||
const runewakerIdle = weaponStance === "bow"
|
||||
? "idle - bow_idle"
|
||||
: weaponStance === "one-handed" ? "idle - 1h_idle" : "idle - 2h_idle";
|
||||
const ready = selectWoWAnimationVariation(clips, readyIds)
|
||||
?? clips.find((clip) => clip.name.toLowerCase().startsWith(runewakerIdle));
|
||||
if (ready) return ready;
|
||||
}
|
||||
const ids = motion === "run" ? [5, 4, 0] : motion === "walk" ? [4, 5, 0] : [0, 4, 5];
|
||||
return selectWoWAnimationVariation(clips, ids);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user