- May 9, 2017
- 152
- 79
I am creating a mod for myself but my poor knowledge that made me stuck, somebody help me please.
This is an example : game "Mybestfriendsdaughter" and this stage are : episode 2 to 15 (episode 1 is intro), each episode has 1 to 100 variables (ex : e2_10, e7_8, e12_22 ), value 1 or 0
I writed myself a mod that made me easy tracing but i tried someways and failed. So help me fix these please.
This is an example : game "Mybestfriendsdaughter" and this stage are : episode 2 to 15 (episode 1 is intro), each episode has 1 to 100 variables (ex : e2_10, e7_8, e12_22 ), value 1 or 0
I writed myself a mod that made me easy tracing but i tried someways and failed. So help me fix these please.
hbox spacing 5 :
vbox :
if episode1 == 1 :
textbutton "Ep1" action [] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode2 == 1 :
textbutton "Ep2" action [SetVariable("Ep_check", 2)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode3 == 1 :
textbutton "Ep3" action [SetVariable("Ep_check", 3)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode4 == 1 :
textbutton "Ep4" action [SetVariable("Ep_check", 4)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode5 == 1 :
textbutton "Ep5" action [SetVariable("Ep_check", 5)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode6 == 1 :
textbutton "Ep6" action [SetVariable("Ep_check", 6)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode7 == 1 :
textbutton "Ep7" action [SetVariable("Ep_check", 7)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode8 == 1 :
textbutton "Ep8" action [SetVariable("Ep_check", 8)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
vbox :
if episode9 == 1 :
textbutton "Ep9" action [SetVariable("Ep_check", 9)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode10 == 1 :
textbutton "Ep10" action [SetVariable("Ep_check", 10)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode11 == 1 :
textbutton "Ep11" action [SetVariable("Ep_check", 11)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode12 == 1 :
textbutton "Ep12" action [SetVariable("Ep_check", 12)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode13 == 1 :
textbutton "Ep13" action [SetVariable("Ep_check", 13)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode14 == 1 :
textbutton "Ep14" action [SetVariable("Ep_check", 14)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
if episode15 == 1 :
textbutton "Ep15" action [SetVariable("Ep_check", 15)] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)-5
viewport :
xsize x_col/2
xpos 100 + (x_col+50) *1
ypos 100
ymaximum 900
scrollbars "vertical"
mousewheel True
vbox :
for u in range(1,100) :
textbutton "e[Ep_check]_ = " + check_stagesx(Ep_check,u) action [] style 'xmod_button_nb' text_style 'xmod_button_txt' text_size (x_text_size) xsize (x_col/2)
init python:
def check_stagesx(Ep_check,u) :
vars_x = ("e" + Ep_check + "_" + u)
if vars_x > 0 :
return "1"
else :
return "0"