核心在say界面的window样式,一种比较简单的修改:
[RenPy] 纯文本查看 复制代码 init python:
textbox_alpha = 0.2
init python:
def textbox_tranparent(trans, st, at):
global textbox_alpha
trans.alpha = textbox_alpha
transform textbox_transparent_trans(alpha):
alpha alpha
image textbox_bg:
"gui/textbox.png"
xalign 0.5
yalign 1.0
function textbox_tranparent
style window:
xalign 0.5
xfill True
yalign gui.textbox_yalign
ysize gui.textbox_height
#background Image("gui/textbox.png", xalign=0.5, yalign=1.0)
background "textbox_bg"
不过直接修改 textbox_alpha 的值不会影响GUI,需要修改后调用重建gui的API:
[RenPy] 纯文本查看 复制代码 label main_menu:
return
label start:
scene white
"start..."
$ textbox_alpha = 1.0
$ gui.rebuild()
"End"
直接怎么在设置界面修改 textbox_alpha 就自己弄一下吧…… |