Multiple speaking animations in one pose?
Posted: Sun Apr 25, 2021 8:58 pm
I'm trying to figure out a way to switch between different speaking animations within a single layered image - for example, one for regular talking, one for yelling, one for if the head is at a 3/4 view, etc. - which then play in sync with the dialogue. So far, the only method I could figure out is to duplicate the entire layered image and define it as a new pose with a different animation assigned to its speaking attribute. It works, but it hardly seems efficient. Is it possible to have multiple speaking animations within a single pose that can be chosen in the script and then run in sync with the dialogue display?
This is a snippet of my layered image setup, which is basic since I'm just testing things out. I'm still trying to wrap my head around how variants work.
My current speaking animation:
And then, because I really wanted the lip flap to stop when the dialogue finishes displaying, I'm using this callback I found via some heavy googling. (When I tried the config speaking attribute instead, I couldn't get the lip flap to stop until I clicked to narration or a different character.)
This was the only way I could find to stop the lip flap, but then it bakes in the neutral-mouth expression, and I'm not sure if there's a better way to go about this.
Does anyone have any suggestions? I'm brand new to this, so any help is greatly appreciated!
This is a snippet of my layered image setup, which is basic since I'm just testing things out. I'm still trying to wrap my head around how variants work.
Code: Select all
layeredimage merritt:
always "merritt_base"
group eyes auto:
attribute blinking default:
"merritt_blinking"
group mouth auto:
attribute neutral default
attribute speaking:
"merritt_talking"Code: Select all
image merritt_talking:
"merritt_mouth_opentalk"
.25
"merritt_mouth_pursed"
.25
"merritt_mouth_opentalk"
.25
"merritt_mouth_neutral"
.25
repeatCode: Select all
init python:
def shutup_merritt(event, interact=True, **kwargs):
if event == "slow_done" or event=="end":
renpy.show("merritt neutral")
renpy.restart_interaction() # this
elif event == "begin":
renpy.show("merritt speaking")
define m = Character("Merritt", image="merritt", callback=shutup_merritt)Does anyone have any suggestions? I'm brand new to this, so any help is greatly appreciated!