Search found 4 matches
- Sat Jul 22, 2023 11:09 pm
- Forum: Ren'Py Cookbook
- Topic: Dynamic blinking animation
- Replies: 0
- Views: 9326
Dynamic blinking animation
Long story short, I wanted my characters to have blink animations and got tired of having to copy-paste the animation code block for every character. I also wanted them to have a random duration between blinks to make it look more organic. Partial solution was to adapt this code which uses only eyes...
- Sat Jul 22, 2023 10:34 pm
- Forum: Ren'Py Questions and Announcements
- Topic: [SOLVED] Trying to find a more efficient solution to blink animations for multiple characters...
- Replies: 5
- Views: 439
Re: Trying to find a more efficient solution to blink animations for multiple characters...
Just a guess, you could define a variable for this like: init python: def blinking_animation(character): global blink_sequence return Animation( "chars/{}/{}_eyes_open.png".format(character, character), renpy.random.choice(blink_sequence), "chars/{}/{}_eyes_half.png".format(char...
- Thu Jul 20, 2023 2:50 am
- Forum: Ren'Py Questions and Announcements
- Topic: [SOLVED] Trying to find a more efficient solution to blink animations for multiple characters...
- Replies: 5
- Views: 439
Re: Trying to find a more efficient solution to blink animations for multiple characters...
Okay - fast forward several hours, a lengthy video course on Python, a few back and forths with GPT-4, and a bunch of googling later, and I have found my solution! Here's the code in case anyone else needs to modify it: init python: def blinking_animation(character): return Animation( "chars/{}...
- Wed Jul 19, 2023 12:35 pm
- Forum: Ren'Py Questions and Announcements
- Topic: [SOLVED] Trying to find a more efficient solution to blink animations for multiple characters...
- Replies: 5
- Views: 439
[SOLVED] Trying to find a more efficient solution to blink animations for multiple characters...
So in short, I use the LayeredImage function for sprites and have a blinking animation that uses three separate images for each character with a pretty standard setup (as in I probably copy-pasted it from the LayeredImage tutorial but it's been so long I don't remember), ex.: image noa_blinking: &qu...