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.
Post Reply
- Print view
7 posts• Page 1 of 1
Message
Author
neometalero
- Veteran
- Posts: 202
- 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:
Contact neometalero
Send private message
Shake Screen/Sprite
- Quote
#1Postby neometalero »
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.
Working on many weird narrative games at Curse Box Studios
https://www.curseboxstudios.com/
Top
Donmai
- Eileen-Class Veteran
- Posts: 1965
- 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:
Contact Donmai
Send private message
Re: Shake Screen/Sprite
- Quote
#2Postby Donmai »
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.
No, sorry! You must be mistaking me for someone else.
TOIRE NO HANAKO (A Story About Fear)
Top
neometalero
- Veteran
- Posts: 202
- 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:
Contact neometalero
Send private message
Re: Shake Screen/Sprite
- Quote
#3Postby neometalero »
There is any way to only shake the sprite? not the hole scene?
Working on many weird narrative games at Curse Box Studios
https://www.curseboxstudios.com/
Top
Donmai
- Eileen-Class Veteran
- Posts: 1965
- 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:
Contact Donmai
Send private message
Re: Shake Screen/Sprite
- Quote
#4Postby Donmai »
Look at the example script in the shake effect page.
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
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.
No, sorry! You must be mistaking me for someone else.
TOIRE NO HANAKO (A Story About Fear)
Top
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
- Quote
#5Postby Taleweaver »
Moved to Ren'Py Questions.
Scriptwriter and producer of Metropolitan Blues
Creator of The Loyal Kinsman
Scriptwriter and director of Daemonophilia
Scriptwriter and director of The Dreaming
Scriptwriter of Zenith Chronicles
Scriptwriter and director of The Thirteenth Year
Scriptwriter and director of Romance is Dead
Scriptwriter and producer of Adrift
"Adrift - Like Ever17, but without the Deus Ex Machina" - HigurashiKira
Top
neometalero
- Veteran
- Posts: 202
- 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:
Contact neometalero
Send private message
Re: Shake Screen/Sprite
- Quote
#6Postby neometalero »
Donmai wrote: ↑Fri Dec 22, 2017 11:09 pmLook at the example script in the shake effect page.
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
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.
Tks a lot , I will try that
Working on many weird narrative games at Curse Box Studios
https://www.curseboxstudios.com/
Top
neometalero
- Veteran
- Posts: 202
- 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:
Contact neometalero
Send private message
Re: Shake Screen/Sprite
- Quote
#7Postby neometalero »
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.
Working on many weird narrative games at Curse Box Studios
https://www.curseboxstudios.com/
Top
Post Reply
- Print view
7 posts• Page 1 of 1
Return to “Ren'Py Questions and Announcements”
Who is online
Users browsing this forum: No registered users