Learn how to script lip flap and blinking animations for your renpy game and discover tips, tricks, and common pitfalls in this short interactive tutorial made for Make Visual Novel Assets! Jam.

How to use:

This is an interactive tutorial.

Left-click or hit space or enter to advance text. Hold ctrl to skip past already seen content. Right-click to access the menu, including a help screen with further commands.

Credits:

Art: Illumenos

Music: CrazyCowLady with mastering by WeeabooOverlod

Scripting: Illumenos

Built on Code from: Asceai, in a lemmasoft forums thread

How to install:

You can check out this interactive tutorial in your browser or download it onto your PC.

You can also get the full project from gitlab.

Windows

Download and unzip the file. Double-click "LipFlapsAndBlinks.exe" to launch the game.

MacOS

Unzip the game file you downloaded from itch.io, then control-click the app icon. Click on "open" at the top of the shortcut menu, before confirming that you want to open the game by clicking "open" again.

Afterwards, whenever you want to play the game again, your computer will remember your choice and let you open it by double-clicking.

Published 4 days ago
StatusReleased
CategoryTool
PlatformsHTML5, Windows, macOS, Linux
Rating
Rated 5.0 out of 5 stars
(2 total ratings)
AuthorsNotHack Europa, Illumenos
Made withRen'Py, Audacity, Clip Studio Paint
TagsAnimation, programming, Ren'Py, scripting, Tutorial
Asset licenseCreative Commons Attribution v4.0 International
Average sessionA few minutes
LanguagesEnglish
InputsKeyboard, Mouse
AccessibilityColor-blind friendly, Subtitles

Download

Download
LipFlapsAndBlinks-1.0.1-pc.zip 58 MB
Download
LipFlapsAndBlinks-1.0.1-mac.zip 53 MB

Comments

Log in with itch.io to leave a comment.

(+1)

Part3:
I like what you are doing this and I want this to succeed. I want to see more of good mouth flaps. However, when I see the code provided. I see multiple points I feel I shouldn't just leave like that.

So, here's some thing I'd suggest. Maybe you can learn too, the same way this presentation had things for me to learn.

Oversampling

Ren'Py already comes with oversampling out-of-the-box. You only need to use the "@" in the file name and Ren'Py takes care of oversampling for you.
Manual: https://www.renpy.org/doc/html/displaying_images.html#oversampling

Namespacing

I'd like if this example also made use of namespacing. In this case, it involves making us of the "in" modifier for python init.

E.g.
Instead of:

init python:

do:

init python in flapsAndBlinks:


This avoids clashing with functions of other libraries or the VN maker's

Choice

When doing choice, reduce repetition. Make use of the simple expression whenever viable. Ren'Py caches these expressions.

E.g.

alpha 1
choice:
    closed_eyes
choice:
    closed_eyes
choice:
    closed_eyes
    pause 0.05
    alpha 0
    pause 0.2
    alpha 1
    closed_eyes
pause 0.05

->

alpha 1
closed_eyes
choice 2:
    pass
choice:
    pause 0.05
    alpha 0
    pause 0.2
    alpha 1
    closed_eyes
pause 0.05

-----

alpha 1
choice:
    pause  0.1
    mouth_open
    pause  0.1
    mouth_half_open
    repeat 3
choice:
    pause  0.1
    mouth_open
    pause  0.1
    mouth_half_open
    repeat 6

->

alpha 1
pause  0.1
mouth_open
pause  0.1
mouth_half_open
choice:
    repeat 3
choice:
    repeat 6

(code is hard to type in itch....)

WhileSpeaking is intelligently made

The way you do this is smart:

def WhileSpeaking(name, speaking_d, done_d=Null()):
 return DynamicDisplayable(curried_while_speaking(name, speaking_d, done_d))


Finally

Thank you for making this tutorial. I hope it's picked up by many people and this can be used by many more people.

(+1)

Wow, thank you for this amazing feedback! I'm sure Illumenos and I can incorporate this into a future version of this tool! I know he wants to expand it to also offer help to artists wanting to draw the frames/expressions for lip flaps, so I'm sure there'll be an update sooner or later.

We were actually looking at "proper" software licenses first (both of us are coming from a software development background, but neither does a lot of work in the open source community or with Python for that matter), but then figured that nothing would stop us from just slapping CC BY on it and call it a day, especially since we want the rest of the repo's content to be available for people as well, and for the art and music CC BY felt more appropriate. But yeah, definitely a weird choice and we were discussing MIT/Apache as well before just going with one license for everything.

As I already said, neither of us is using Python professionally, so this was all kinda hacked together within the time constraints of several game jams without digging deeper into the language and its best practices or really paying much attention to quality. So getting pointers for this is especially interesting for us. Usually we just take a break after jams because we're all tired, and then when the next jam rolls around it's all deadlines and stress again, so no one ever takes the time to truly figure stuff out. This is super helpful and a great way to get us to sort things out.

Thanks again,

CCL

Thank you for your time to answer and explain your situation.

For licensing, in my case I ended up with MPL 2.0. It's strict enough for my creation but loose enough to allow others to use it. Attribution enforced by the license is really something I'd like it to have. I could edit it but then it's a custom license that is untested and unproven (and couldn't be called MPL or any variation of that).

I'm open to cooperate and help making stuff that is useful for the community. Like these tools you spent a lot of time on. If I can help, I'm open to help. I want Ren'Py to succeed and I believe these tools help achieving just that.

If you ever feel like cooperating with something, I help with what I can. You can find me here or Discord or lemmasoft forums. I'm brunoais pretty much everywhere. See you soon 😉.

(+1)

Hi 👋

Thanks a lot for the time you put into reviewing this! Especially thanks for the pointers. For these alone making this tutorial has already been worth the time. I will adapt the code on gitlab in the next couple days, but for this jam it has to stay on 1.0.1 during rating.

Regarding a chance for a collaboration: On this specific code I think I want to implement some of the things you mentioned on my own to get the learning experience. After that we (community and our team) can manage this project through merge requests and forks. It is intended to be open source.

I'd be happy if you helped with the project after the initial rating period, in case you find code you really want to fix :D

Regards,

Illumenos

Sounds good. 👍

There's some things I really would want to implement such as the concept of namespacing the variables, functions, transforms, etc... so it doesn't clash with other stuff. The rest, that's not as important.

I'm open for discussion or comments, if you want. You can contact me. I'm also on Discord and other discussion forums.

(1 edit) (+1)

Part2:
When I read this VN's source code, specially the code used for the examples, it makes me want to 

Using a CCA license for software is weird. However, nowadays mature (and tried-and-true) software licenses do not enforce attribution. I know that feel and I just decided to accept that and hope for people's good faith.

(+1)

Well done. I wish I could provide such through and complete usage manuals as this one with practical examples to boot.

I have a few separate things I'd like to comment related to this tool, so I'll create a separate comment for each of both.

For starters, It's well presented and it's well done. Quite visually interesting. I see quite some (intended or not) inspiration from Ren'Py's own tutorial. That makes it flow nicely. The links are also fairly welcome.

By the way, while checking this out I found a single typo:

Let us first look at how we put voice lines into our sript. This is important.

With all that text for a jam, typos are those things that appear out of nowhere, no matter how many times you read, you read it right until someone points it out and then it magically becomes wrong 🤣.