Page 1 of 1
Choices in columns instead of rows?
Posted: Fri Jul 28, 2017 7:28 pm
by Roselia-Thorns
I want my choices to be in columns instead of rows.
Let's say I have this
And I want it to look something like this

Re: Choices in columns instead of rows?
Posted: Sat Jul 29, 2017 8:46 am
by Vnigma
you must edit the choice menu in the screen file to display the menu programmiaclly
Re: Choices in columns instead of rows?
Posted: Sat Jul 29, 2017 1:34 pm
by Roselia-Thorns
Ah sorry, I'm kind of noob and I don't understand what you mean or how to do that.
Re: Choices in columns instead of rows?
Posted: Sun Jul 30, 2017 1:28 am
by shin.e.d
Hi. :3 You can do that by putting
box_wrap and ymaximum into the choice menu in screens.rpy. Like this...
Choice menu with columns example:
Code: Select all
screen choice(items):
style_prefix "choice"
vbox:
## wrap around into columns or rows depending on if it's in vbox or hbox.
box_wrap True
## ymaximum is used for vertical box wrap.
## It includes the size of your button + spacing.
## To make things easier I just put the gui variables in.
## it normally looks something like this: ymaximum 100
## the *number at the end changes how many buttons are in the column.
## if nonetype error make sure the gui.choice variables are defined.
ymaximum (gui.choice_button_height + gui.choice_spacing) *3
for i in items:
textbutton i.caption action i.action
## This overwrites the variables in gui.rpy when put in screens.rpy
define gui.choice_button_width = 350
define gui.choice_button_height = 50
define gui.choice_button_text_xalign = 0.0
define gui.choice_spacing = 0