Project1
标题:
如何改变菜单命令窗口的透明度
[打印本页]
作者:
2578699
时间:
2010-11-15 12:53
标题:
如何改变菜单命令窗口的透明度
我想把菜单命令窗口变成透明的。
未命名.jpg
(17.27 KB, 下载次数: 4)
下载附件
保存到相册
2010-11-15 12:53 上传
请帮帮忙......
作者:
沙之爱罗
时间:
2010-11-15 12:56
半透明菜单脚本
module Opacity_Menu
def create_screen
@screen = Spriteset_Map.new
end
def dispose_screen
@screen.dispose
end
end
class Window_Base < Window
def initialize(x, y, width, height)
super()
@windowskin_name = $game_system.windowskin_name
self.windowskin = RPG::Cache.windowskin(@windowskin_name)
self.x = x
self.y = y
self.width = width
self.height = height
self.z = 100
if $scene.is_a?(Scene_Menu) or
$scene.is_a?(Scene_Item) or
$scene.is_a?(Scene_Skill) or
$scene.is_a?(Scene_Equip) or
$scene.is_a?(Scene_Status) or
$scene.is_a?(Scene_Save) or
$scene.is_a?(Scene_End) or
$scene.is_a?(Scene_Shop)
self.back_opacity = 160
end
end
end
class Scene_Menu
include Opacity_Menu
alias main_old main
def main
create_screen
main_old
dispose_screen
end
end
class Scene_Item
include Opacity_Menu
alias main_old main
def main
create_screen
main_old
dispose_screen
end
end
class Scene_Skill
include Opacity_Menu
alias main_old main
def main
create_screen
main_old
dispose_screen
end
end
class Scene_Equip
include Opacity_Menu
alias main_old main
def main
create_screen
main_old
dispose_screen
end
end
class Scene_Status
include Opacity_Menu
alias main_old main
def main
create_screen
main_old
dispose_screen
end
end
class Scene_Save
include Opacity_Menu
alias main_old main
def main
create_screen
main_old
dispose_screen
end
end
class Scene_End
include Opacity_Menu
alias main_old main
def main
create_screen
main_old
dispose_screen
end
end
class Scene_Shop
include Opacity_Menu
alias main_old main
def main
create_screen
main_old
dispose_screen
end
end
复制代码
作者:
Wind2010
时间:
2010-11-15 12:58
@command_window.opacity = 150#菜单透明度
复制代码
直接把这个复制到Scene_Menu里……
作者:
2578699
时间:
2010-11-16 12:52
谢谢
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1