Shake Screen/Sprite
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.
- neometalero
- Regular
- Posts: 198
- Joined: Sun Oct 23, 2016 3:51 am
- Completed: My Dream Sport Dating Simulator, Attack Helicopter Dating Simulator
- Projects: My Dream Sport Dating Simulator, Attack Helicopter Dating Simulator
- Deviantart: neometalero
- Contact:
Shake Screen/Sprite
How can I shake the screen or the image sprite? I want the character to shake when there is dammage or an angry reaction for example.
- 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: Shake Screen/Sprite
Choose a method: To shake the whole scene (including sprites, not sprites only) you can use the vpunch or hpunch transitions.
https://www.renpy.org/doc/html/transiti ... var-vpunch
https://www.renpy.org/doc/html/transiti ... var-hpunch
Or you can use this old cookbook recipe from the wiki (don't be afraid, it's old but it still works):
https://www.renpy.org/wiki/renpy/doc/co ... ake_effect
Alternatively, you can use an ATL transform. Personally, I think the python shake effect is still the best option.
https://www.renpy.org/doc/html/transiti ... var-vpunch
https://www.renpy.org/doc/html/transiti ... var-hpunch
Or you can use this old cookbook recipe from the wiki (don't be afraid, it's old but it still works):
https://www.renpy.org/wiki/renpy/doc/co ... ake_effect
Alternatively, you can use an ATL transform. Personally, I think the python shake effect is still the best option.
No, sorry! You must be mistaking me for someone else.
TOIRE NO HANAKO (A Story About Fear)
TOIRE NO HANAKO (A Story About Fear)
- neometalero
- Regular
- Posts: 198
- Joined: Sun Oct 23, 2016 3:51 am
- Completed: My Dream Sport Dating Simulator, Attack Helicopter Dating Simulator
- Projects: My Dream Sport Dating Simulator, Attack Helicopter Dating Simulator
- Deviantart: neometalero
- Contact:
Re: Shake Screen/Sprite
There is any way to only shake the sprite? not the hole scene?
- 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: Shake Screen/Sprite
Look at the example script in the shake effect page.When you use the effect in a sprite you only have to add its position (left, center or right). If you don't the shaking sprite will appear at left position.
Code: Select all
# shaking the sprite by placing it at the center (where it already was)
ph "Ng!..."
show phoenix at center, Shake(None, 1.0, dist=5)
with None
No, sorry! You must be mistaking me for someone else.
TOIRE NO HANAKO (A Story About Fear)
TOIRE NO HANAKO (A Story About Fear)
- Taleweaver
- Writing Maniac
- Posts: 3428
- Joined: Tue Nov 11, 2003 8:51 am
- Completed: Metropolitan Blues, The Loyal Kinsman, Daemonophilia, The Dreaming, The Thirteenth Year, Adrift, Bionic Heart 2, Secrets of the Wolf, The Photographer
- Projects: The Pilgrim's Path, Elspeth's Garden, Secret Adventure Game!
- Organization: Tall Tales Productions
- Location: Germany
- Contact:
Re: Shake Screen/Sprite
Moved to Ren'Py Questions.
Scriptwriter and producer of Metropolitan Blues
Creator of The Loyal Kinsman
Scriptwriter and director of DaemonophiliaScriptwriter and director of The Dreaming
Scriptwriter of Zenith ChroniclesScriptwriter and director of The Thirteenth Year
Scriptwriter and director of Romance is DeadScriptwriter and producer of Adrift
More about me in my blog"Adrift - Like Ever17, but without the Deus Ex Machina" - HigurashiKira
- neometalero
- Regular
- Posts: 198
- Joined: Sun Oct 23, 2016 3:51 am
- Completed: My Dream Sport Dating Simulator, Attack Helicopter Dating Simulator
- Projects: My Dream Sport Dating Simulator, Attack Helicopter Dating Simulator
- Deviantart: neometalero
- Contact:
Re: Shake Screen/Sprite
Tks a lot , I will try thatDonmai wrote: ↑Fri Dec 22, 2017 11:09 pm Look at the example script in the shake effect page.When you use the effect in a sprite you only have to add its position (left, center or right). If you don't the shaking sprite will appear at left position.Code: Select all
# shaking the sprite by placing it at the center (where it already was) ph "Ng!..." show phoenix at center, Shake(None, 1.0, dist=5) with None
- neometalero
- Regular
- Posts: 198
- Joined: Sun Oct 23, 2016 3:51 am
- Completed: My Dream Sport Dating Simulator, Attack Helicopter Dating Simulator
- Projects: My Dream Sport Dating Simulator, Attack Helicopter Dating Simulator
- Deviantart: neometalero
- Contact:
Re: Shake Screen/Sprite
Ok that was actually really easy to do, tks for the help. When I first found that example It looked really complicated but it was actually quite simple to use.
Who is online
Users browsing this forum: Bing [Bot], Google [Bot], henne