Project1
标题:
怎么把这个窗口改成透明的,或者不要窗口。
[打印本页]
作者:
562613736
时间:
2013-12-22 15:48
标题:
怎么把这个窗口改成透明的,或者不要窗口。
本帖最后由 562613736 于 2013-12-22 16:13 编辑
#==============================================================================
# ■ Window_变量
#------------------------------------------------------------------------------
# 显示变量的窗口。
#==============================================================================
class Window_变量 < Window_Base
#--------------------------------------------------------------------------
# ● 初始化窗口
#--------------------------------------------------------------------------
def initialize
super(0, 0, 640, 60) #窗口大小200 是宽 200是高
self.contents = Bitmap.new(width - 32, height - 32)
refresh
end
#--------------------------------------------------------------------------
# ● 刷新
#--------------------------------------------------------------------------
def refresh
self.contents.font.color = Color.new(0, 0, 0, 255) #字体颜色
self.contents.clear
self.contents.draw_text(-600, -10, width, 50, "X",2) #这里显示文字类,不需要的话可以删掉
self.contents.draw_text(-570, -10, width, 50, "Y",2) #这里显示文字类,不需要的话可以删掉
self.contents.draw_text(-500, -10, width, 50, "年",2) #这里显示文字类,不需要的话可以删掉
self.contents.draw_text(-450, -10, width, 50, "月",2) #这里显示文字类,不需要的话可以删掉
self.contents.draw_text(-400, -10, width, 50, "日",2) #这里显示文字类,不需要的话可以删掉
self.contents.draw_text(-345, -10, width, 50, "时",2) #这里显示文字类,不需要的话可以删掉
self.contents.draw_text(-300, -10, width, 50, "分",2) #这里显示文字类,不需要的话可以删掉
self.contents.draw_text(-250, -10, width, 50, "秒",2) #这里显示文字类,不需要的话可以删掉
self.contents.draw_text(-305, -10, width, 50, $game_variables[1].to_s, 1) #这里显示变量1
self.contents.draw_text(-275, -10, width, 50, $game_variables[2].to_s, 1) #这里显示变量2
self.contents.draw_text(-220, -10, width, 50, $game_variables[3].to_s, 1) #这里显示变量3
self.contents.draw_text(-170, -10, width, 50, $game_variables[4].to_s, 1) #这里显示变量4
self.contents.draw_text(-115, -10, width, 50, $game_variables[5].to_s, 1) #这里显示变量5
self.contents.draw_text(-55, -10, width, 50, $game_variables[6].to_s, 1) #这里显示变量6
self.contents.draw_text(-15, -10, width, 50, $game_variables[7].to_s, 1) #这里显示变量7
self.contents.draw_text(30, -10, width, 50, $game_variables[8].to_s, 1) #这里显示变量8
#无限循环自己喜欢添加
end
end
复制代码
怎么把这个窗口改成透明的,或者不要窗口。
作者:
RyanBern
时间:
2013-12-22 16:05
在initialize那段的refresh前面填写self.opacity = 0
作者:
562613736
时间:
2013-12-22 16:10
RyanBern 发表于 2013-12-22 16:05
在initialize那段的refresh前面填写self.opacity = 0
能直接帮我改下吗?
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1