[SOLVED] How to make the screen shake with imagebutton?

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
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
Message
Author
User avatar
GeeSeki
Regular
Posts: 112
Joined: Sat Dec 17, 2016 3:39 am
Projects: A Town Uncovered
itch: geeseki
Contact:

[SOLVED] How to make the screen shake with imagebutton?

#1 Post by GeeSeki »

Hi,

I'm wondering if there was a way to use the hpunch screen shake or any similar screen shake at a click of an imagebutton that doesn't involve jumping to a label.

Thanks.
Last edited by GeeSeki on Thu Sep 16, 2021 4:09 am, edited 1 time in total.

Daisetsu
Newbie
Posts: 1
Joined: Wed Apr 14, 2021 9:25 pm
Contact:

Re: How to make the screen shake with imagebutton?

#2 Post by Daisetsu »

I'm not in a position to test right now, but something lile this should work.

Code: Select all

imagebutton auto myimage action [NullAction(), With(hpunch)]
The NullAction() might not even be necessary.

User avatar
GeeSeki
Regular
Posts: 112
Joined: Sat Dec 17, 2016 3:39 am
Projects: A Town Uncovered
itch: geeseki
Contact:

Re: [SOLVED] How to make the screen shake with imagebutton?

#3 Post by GeeSeki »

Yeah! It works, NullAction() isn't needed.

Post Reply

Who is online

Users browsing this forum: No registered users