#==============================================================================
# Window Map Name+
# by Enterbrain
# edited by LUSHI
# Date 04/04/2012
#------------------------------------------------------------------------------
# **WHAT IT DOES**
# This edit is simple I'm no pro but wanted my have my one image in the
# background of the map name so I edited Window_MapName.
# This adds a background image to the map name and moves it to the right of the
# screen.
#------------------------------------------------------------------------------
# **WHERE THINGS GO**
# place this scrip ether in the materials section or overright Window_MapName
# with this one. If using the map name fix By Crazyninjaguy place this above it.
#
# Must have "Map_Name_Back.png" in Graphics/System folder
#
# thats it run your game.
#
#------------------------------------------------------------------------------
# **HOW TO EDIT**
# To change the locaton of the name change the values of lines,
#
# 49
# 122
# 123
#
# to change the name of the png file find line,
#
# 120
#
# and edit as you need.
#
# **THE END**
# Thats all there is. I hope That helps.
#------------------------------------------------------------------------------
# This window displays the map name.
#==============================================================================
class Window_MapName < Window_Base
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize
super(0, 0, window_width, fitting_height(1))
self.opacity = 0
self.contents_opacity = 0
self.x = 152
@map_name_back = Sprite.new
@show_count = 0
refresh
end
#--------------------------------------------------------------------------
# * Get Window Width
#--------------------------------------------------------------------------
def window_width
return 240
end
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update
super
if @show_count > 0 && $game_map.name_display
update_fadein
@show_count -= 1
else
update_fadeout
end
end
#--------------------------------------------------------------------------
# * Update Fadein
#--------------------------------------------------------------------------
def update_fadein
self.contents_opacity += 16
@map_name_back.opacity += 16
end
#--------------------------------------------------------------------------
# * Update Fadeout
#--------------------------------------------------------------------------
def update_fadeout
self.contents_opacity -= 16
@map_name_back.opacity -= 16
end
#--------------------------------------------------------------------------
# * Open Window
#--------------------------------------------------------------------------
def open
refresh
@show_count = 150
self.contents_opacity = 0
self
end
#--------------------------------------------------------------------------
# * Close Window
#--------------------------------------------------------------------------
def close
@show_count = 0
self
end
#--------------------------------------------------------------------------
# * Refresh
#--------------------------------------------------------------------------
def refresh
contents.clear
unless $game_map.display_name.empty?
draw_background(contents.rect)
draw_text(contents.rect, $game_map.display_name, 1)
end
end
#--------------------------------------------------------------------------
# * Draw Background
#--------------------------------------------------------------------------
def draw_background(rect)
temp_rect = rect.clone
temp_rect.width /= 2
contents.gradient_fill_rect(temp_rect, back_color2, back_color1)
@map_name_back = Sprite.new
@map_name_back.bitmap = Cache.system("Map_Name_BackGr.png")
@map_name_back.z = 0
@map_name_back.x = 185
@map_name_back.y = 7
@map_name_back.opacity = 0
temp_rect.x = temp_rect.width
contents.gradient_fill_rect(temp_rect, back_color1, back_color2)
end
#--------------------------------------------------------------------------
# * Get Background Color 1
#--------------------------------------------------------------------------
def back_color1
Color.new(0, 0, 0, 0)
end
#--------------------------------------------------------------------------
# * Get Background Color 2
#--------------------------------------------------------------------------
def back_color2
Color.new(0, 0, 0, 0)
end
end
Comments
http://atelier-rgss.com/RGSS/Menu/ACE_Menu10.html
THAM GIA GROUP CỦA TTC TRÊN FACEBOOK
Hoặc Click zô đây: https://www.google.com.vn/search?q=Window+Map+Name+&oq=Window+Map+Name+&aqs=chrome..69i57.509j0j4&sourceid=chrome&es_sm=122&ie=UTF-8#q=window+map+name+for+rpg+maker+vx+ace&safe=active&spell=1
http://taotrochoi.com/showthread.php?tid=978
Không đẹp lắm nhưng cũng tạm ngó được.
:duanghich:
hiện tên map khi teleport ra chỗ khác ^_^
mình có script của RPGXP nè ai lấy ko mình share?
David chuyển qua ace đi hợp tác làm game cùng mình :D
có lẽ cả đời mình chỉ làm XP thôi =))
có nhiều tài nguyên ở XP rồi nên chuyển qua VX cũng khó
chỉ cần Viết tên map vào Map name trong Properties thôi
Thêm 1 graphic nền vào Graphics\System nữa
Link: http://www.rpgmakervxace.net/topic/2433-window-mapname-edit-with-image-fixed/
Mò mãi mới ra đc cái link :v
This is result! Có chỉnh sửa :P
Kiểu như vậy nè:
Script trên ko có xài lệnh call để switch đc
@Dark Sky
@Nagi