I've recently figured out how to use layered images, via baiyu.
The only thing I can't seem to get to work is the dress up game.
I thought SetVariable would search for any images containing the word hair, but wouldn't seem to be the case :S Anyone who could enlighten me how this work?
Code: Select all
nit python:
outfit, hair = 1, 1 # default dressup items
outfit_styles_num, hair_styles_num = 3, 3 # number of styles for each dressup item
screen dressup_example():
## Ensure this appears on top of other screens.
zorder 100
frame:
xalign 0.5
xsize 700
yfill True
hbox:
xalign 0.5
yalign 0.15
spacing 400
textbutton _("<") action SetVariable('hair', max(hair-1,0))
textbutton _(">") action SetVariable('hair',min(hair+1,hair_styles_num))
add "base.png" xalign 0.5