RE-SS3D / SS3D

Space Station 3D, another remake of SS13, but with an extra D.
https://ss3d.space/
258 stars 137 forks source link

Animation system part 1 #1333

Open stilnat opened 12 months ago

stilnat commented 12 months ago

Summary

Our character needs life. This is absolutely essential for health and combat system, and many more that can't really move on without it. We need to set up a working animator controller for humans, with a bunch of animations, and this issue is here for that.

Goal

It will be also necessary to properly document it all on gitbook.

Media

different holding poses by @EikoBiko

image

Document

Dependencies

1060 might be helpful to give some context

stilnat commented 12 months ago

Eiko comments from discord :

Okay may have come up with a (mostly) comprehensive breakdown of what the humanoid animator needs:

B = bool
F = float
T = trigger
[LAYER] Movement (Base):
B upright (blend tree; idle -> walk -> run)
    [walk and run will also be blend trees, to indicate leg health]
    F leg_injury
        [-1 for left leg injured, 1 for right leg inured, this value will drive limping]
B prone (blend tree; lay down -> crawl)
B sit

[LAYER] Injury (Additive, 100%):
T arm_hurt_L
T arm_hurt_R
T leg_hurt_L
T leg_hurt_R
T head_hurt_F
T head_hurt_B
T torso_hurt_F
T torso_hurt_B

[LAYER] Left Arm Hold (Override, ~90% weight):
B neutral_L
B briefcase_L
B drink_L
B underarm_L
B shoulder_L
B waiter_L

[LAYER] Right Arm Hold (Override, ~90% weight):
B neutral_R
B briefcase_R
B drink_R
B underarm_R
B shoulder_R
B waiter_R

[LAYER] Emote (Override, 100% weight):
T emote
    [code driven, a ScriptableObject with an AnimationClip and disallowed poses. If the requirements are met, will set the AnimationClip and activate]
T cancel_emote 
    [immediately interrupt emote to return to neutral]

Basically, all movement, such as walking, crawling, or sitting will be the base layer. Injury indicators will be layer played additively on top. Hold poses will animate the arms alone, and override the base animation. Emotes are animations that are injected via code, probably via some sort of function in the HumanoidAnimatorController script, and will only properly show if the current set of true bools allow it. (modifié)

If we want an actions layer, we can do that as well, for things like swing or push button or pick up, these can technically be done in the Emote layer, but if not, we would need custom animations for swinging a weapon in the upright position, as well as in the prone and seated positions, and everything else we need an action for, which could become a lot (modifié)

cosmiccoincidence commented 12 months ago

Relevant info and comments which may be helpful: #937