見出し画像

【ティラノスクリプト】初回起動時のみ、プロローグを表示し、初回以降、別ページからプロローグを表示させる方法


first.ks

[stop_keyconfig]

@call storage="tyrano.ks"

@layopt layer="message" visible=false

[hidemenubutton]

[jump storage="title.ks" cond="sf.prologue == false"]

[jump storage="prologue.ks" target="*start"]

prologue.ks

*extra
[eval exp="sf.extra = true"]

*start
[cm  ]
[clearfix]
[start_keyconfig]


[bg storage="room.jpg" time="100"]

@showmenubutton

[position layer="message0" left=160 top=500 width=1000 height=200 page=fore visible=true]

[position layer=message0 page=fore margint="45" marginl="50" marginr="70" marginb="60"]

@layopt layer=message0 visible=true

[ptext name="chara_name_area" layer="message0" color="white" size=28 bold=true x=180 y=510]

[chara_config ptext="chara_name_area"]

#
プロローグを開始します。[p]

#
プロローグを終了します。[p]

[eval exp="sf.prologue = false"]

@layopt layer="message0" visible="false"

[jump storage="extra.ks" cond="sf.extra == true"]

[jump storage="title.ks"]

title.ks

[cm]

[hidemenubutton]
[clearfix]
@clearstack
@bg storage ="title.png" time=100
@wait time = 200


*start

[button x=135 y=230 graphic="title/button_start.png" enterimg="title/button_start2.png"  target="gamestart"]
[button x=135 y=320 graphic="title/button_load.png" enterimg="title/button_load2.png" role="load" ]
[button x=135 y=410 graphic="title/button_config.png" enterimg="title/button_config2.png" role="sleepgame" storage="config.ks" ]
[button x=135 y=500 graphic="title/extra.png" enterimg="title/extra2.png" storage="extra.ks"]

[s]

*gamestart

@jump storage="scene1.ks"

extra.ks

[cm]

[hidemenubutton]
[clearfix]
@clearstack
@bg storage ="extra.png" time=100
@wait time = 200

[button x=135 y=230 graphic="title/button_cg.png" enterimg="title/button_cg2.png" storage="cg.ks" ]
[button x=135 y=320 graphic="title/button_replay.png" enterimg="title/button_replay2.png" storage="replay.ks" ]
[button x=135 y=410 graphic="title/prologue.png" enterimg="title/prologue2.png" storage="prologue.ks" target="*extra"]
[button fix="true" graphic="config/menu_button_close.png" enterimg="config/menu_button_close2.png" storage="title.ks" x="1160" y="20"]

[s]