Good afternoon from Italy!
So, as I was coding for my Visual Novel, I realized that I need a particular kind of transitions to make the monster enemies killed by the main characters disappear.
What I was thinking of was a transition that makes the sprite shake while dissolving. Can this be done? And if so, with what kind of code?
Quaking Dissolve
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
- Meinos Kaen
- Regular
- Posts: 107
- Joined: Wed Jan 04, 2012 1:01 pm
- Completed: JPDE - Sonata of Fire
- Projects: JPDE, Ars Oratoria, ONHA
- Skype: therealmeinoskaen
- Location: Somewhere in Italy...
- Contact:
- Donmai
- Eileen-Class Veteran
- Posts: 1960
- Joined: Sun Jun 10, 2012 1:45 am
- Completed: Toire No Hanako, Li'l Red [NaNoRenO 2013], The One in LOVE [NaNoRenO 2014], Running Blade [NaNoRenO 2016], The Other Question, To The Girl With Sunflowers
- Projects: Slumberland
- Location: Brazil
- Contact:
Re: Quaking Dissolve
Buon pomeriggio dal Brasile.
You want an ATL transform.
https://www.renpy.org/doc/html/atl.html ... n-language
Something like:You can use it this way:I like to create a separate script called transforms.rpy, and put my special effects there.
You want an ATL transform.
https://www.renpy.org/doc/html/atl.html ... n-language
Something like:
Code: Select all
transform blast:
alpha 1.0 xoffset 0
choice:
block:
linear 0.05 xoffset 10
linear 0.05 xoffset -10
repeat 2
block:
choice:
linear 0.05 xoffset 10
linear 0.05 xoffset -10
repeat 2
choice:
linear 0.05 xoffset 10
linear 0.05 xoffset -10
linear 0.05 xoffset 10
repeat 2
choice:
block:
linear 0.05 xoffset -10
linear 0.05 xoffset 10
repeat 2
block:
choice:
linear 0.05 xoffset -10
linear 0.05 xoffset 10
repeat 2
choice:
linear 0.05 xoffset -10
linear 0.05 xoffset 10
linear 0.05 xoffset -10
repeat 2
linear 0.07 xoffset 0
linear 2.0 alpha .0 # two seconds to dissolve
Code: Select all
play sound "fx/blast.ogg"
show monster at blast, center #center, or any other screen position the monster was located before being "blasted"
m "Argh!"
hide monster # don't forget to actually hide it, to free memory
No, sorry! You must be mistaking me for someone else.
TOIRE NO HANAKO (A Story About Fear)
TOIRE NO HANAKO (A Story About Fear)
- Meinos Kaen
- Regular
- Posts: 107
- Joined: Wed Jan 04, 2012 1:01 pm
- Completed: JPDE - Sonata of Fire
- Projects: JPDE, Ars Oratoria, ONHA
- Skype: therealmeinoskaen
- Location: Somewhere in Italy...
- Contact:
Re: Quaking Dissolve
Hi, thanks for the answer!Donmai wrote:Buon pomeriggio dal Brasile.
You want an ATL transform.
https://www.renpy.org/doc/html/atl.html ... n-language
Something like:You can use it this way:Code: Select all
transform blast: alpha 1.0 xoffset 0 choice: block: linear 0.05 xoffset 10 linear 0.05 xoffset -10 repeat 2 block: choice: linear 0.05 xoffset 10 linear 0.05 xoffset -10 repeat 2 choice: linear 0.05 xoffset 10 linear 0.05 xoffset -10 linear 0.05 xoffset 10 repeat 2 choice: block: linear 0.05 xoffset -10 linear 0.05 xoffset 10 repeat 2 block: choice: linear 0.05 xoffset -10 linear 0.05 xoffset 10 repeat 2 choice: linear 0.05 xoffset -10 linear 0.05 xoffset 10 linear 0.05 xoffset -10 repeat 2 linear 0.07 xoffset 0 linear 2.0 alpha .0 # two seconds to dissolve
I like to create a separate script called transforms.rpy, and put my special effects there.Code: Select all
play sound "fx/blast.ogg" show monster at blast, center #center, or any other screen position the monster was located before being "blasted" m "Argh!" hide monster # don't forget to actually hide it, to free memory
Sadly it doesn't work :/ The game crashes when it tries to do your thing.
- Donmai
- Eileen-Class Veteran
- Posts: 1960
- Joined: Sun Jun 10, 2012 1:45 am
- Completed: Toire No Hanako, Li'l Red [NaNoRenO 2013], The One in LOVE [NaNoRenO 2014], Running Blade [NaNoRenO 2016], The Other Question, To The Girl With Sunflowers
- Projects: Slumberland
- Location: Brazil
- Contact:
Re: Quaking Dissolve
Of course it works, I've used that code myself. What exactly "The game crashes" means?
No, sorry! You must be mistaking me for someone else.
TOIRE NO HANAKO (A Story About Fear)
TOIRE NO HANAKO (A Story About Fear)
- Meinos Kaen
- Regular
- Posts: 107
- Joined: Wed Jan 04, 2012 1:01 pm
- Completed: JPDE - Sonata of Fire
- Projects: JPDE, Ars Oratoria, ONHA
- Skype: therealmeinoskaen
- Location: Somewhere in Italy...
- Contact:
Who is online
Users browsing this forum: Zahdernia