WTS/game/scripts/interface/popup.rpy
2024-05-24 15:19:34 +01:00

35 lines
711 B
Plaintext

transform popup_animation(time=4.0, xx=-200):
xoffset xx
linear 0.5 xoffset absolute(0)
pause time
linear 0.5 xoffset absolute(xx)
screen popup_window(msg="", xpos=0, ypos=60):
tag popup_window
zorder 100
style_prefix gui.theme()
timer 5.0 action Hide("popup_window")
frame:
at popup_animation
pos (xpos, ypos)
text msg align (0.5, 0.5) size 12
label give_reward(text=_("You found something!"), gift="interface/icons/box_blue_2.webp", sound=True):
if sound:
play sound "sounds/win2.ogg"
show screen gift(gift)
show screen notes
with d3
"[text!it]"
hide screen gift
hide screen notes
with d3
return