Hey! I'm trying something similar with a star shaped iris for a portrait aspect ratio game but I am having trouble getting it to work.
Here is the alpha mask:
https://photos.app.goo.gl/rCc5UXy1W1Om8i6Q2
I assume that is what we are looking for?
I tried to modify the above code, but I couldn't get it right, I am getting the following error:
Code: Select all
I'm sorry, but an uncaught exception occurred.
While running game code:
File "game/script.rpy", line 174, in script
show haobang with star_zoom
TypeError: star_zoom() got an unexpected keyword argument 'old_widget'
Here is what the relevant code looks like:
In the script header:
Code: Select all
init python:
def star_zoom(st, at):
return Transform("images/stariris.png", anchor=(0.5,0.5), pos=(0.5,0.5), zoom=at*2), 0
config.enter_transition = AlphaDissolve( DynamicDisplayable(star_zoom), 1.0 )
# The game starts here.
label start:
I also tried:
Code: Select all
init python:
def star_zoom(st, at):
return Transform("images/stariris.png", anchor=(0.5,0.5), pos=(0.5,0.5), zoom=at*2), 0
config.enter_transition = ImageDissolve( DynamicDisplayable(star_zoom), 1.0 )
# The game starts here.
label start:
and in the relevant part of the game the code looks like this:
Code: Select all
if result == "b":
play sound "gmhaobang.ogg"
show haobang with star_zoom
jump game
Any ideas?