Menu parecido com o SOTN para RPG Maker XP feito por Neto Rpg
Caracteristicas
Screens:
Compare:
Tutorial:
Dowload da Demo:
Dowload - Mediafire
Código:
Agradecimentos:
Neto RPG - Por criar o script;
Eu :cheers: (Luigi Perillo X) - Por disponibilizar o script.
Caracteristicas
- Contém o número de salas que você já passou e o número de inimigos que matou.
- Contém as opções "Relíquias" e "Familiares".
Screens:
Compare:
Tutorial:
- Cole o script acima do Main.
- A face que é usada no menu está na demonstração abaixo.
- Para definir o número de salas que você já passou, use a variável 1.
- Para definir o valor de inimigos mortos, use a variável 2.
- As opções "Relíquias" e "Familiares" estão desabilitadas, pois não foram criadas essas partes do script, elas estarão disponiveis apenas na próxima versão.
- Para habilitar as opções chame um script com o seguinte comando:
- Código:
$habilitar = true
Dowload da Demo:
Dowload - Mediafire
Código:
- Spoiler:
- Código:
#=============================================================================#
#-----------------------Menu Castlevania SotN---------------------------------#
#-----------------------------------------------------------------------------#
#--------------------------By: Neto Rpg---------------------------------------#
#=============================================================================#
class Scene_Menu
def initialize(menu_index = 0)
@menu_index = menu_index
end
def main
s1 = $data_system.words.item
s2 = $data_system.words.skill
s3 = $data_system.words.equip
s4 = "Relíquias"
s5 = "Familiares"
@command_window = Window_Command.new(160, [s1, s2, s3, s4, s5])
@command_window.index = @menu_index
@command_window.x = 640 - 400
@command_window.y = 156
@command_window.z = 200
@face = Sprite.new
@face.bitmap = RPG::Cache.picture("Face/Face")
@face.z = 100
@face.x = 20
@face.y = 20
if $habilitar == nil
@command_window.disable_item(3)
@command_window.disable_item(4)
end
@playtime_window = Window_PlayTime.new
@playtime_window.x = 300
@playtime_window.y = 400
@gold_window = Window_Gold.new
@gold_window.x = 0
@gold_window.y = 400
@status_window = Window_MenuStatus.new
@status_window.x = 0
@status_window.y = 0
@status2_window = Window_Status2.new($game_party.actors[0])
Graphics.transition
loop do
Graphics.update
Input.update
update
if $scene != self
break
end
end
Graphics.freeze
@status2_window.dispose
@command_window.dispose
@playtime_window.dispose
@gold_window.dispose
@status_window.dispose
@face.dispose
end
def update
@command_window.update
@playtime_window.update
@gold_window.update
@status_window.update
if @command_window.active
update_command
return
end
if @status_window.active
update_status
return
end
end
def update_command
if Input.trigger?(Input::B)
$game_system.se_play($data_system.cancel_se)
$scene = Scene_Map.new
return
end
if Input.trigger?(Input::C)
if $game_party.actors.size == 0 and @command_window.index < 4
$game_system.se_play($data_system.buzzer_se)
return
end
case @command_window.index
when 0 # Itens
$game_system.se_play($data_system.decision_se)
$scene = Scene_Item.new
when 1 # Habilidades
$game_system.se_play($data_system.decision_se)
@actor_index = 0
$scene = Scene_Skill.new
when 2 # Equipamentos
$game_system.se_play($data_system.decision_se)
$scene = Scene_Equip.new
when 3 # Familiares
when 4 # Sistema
end
return
end
end
end
#==============================================================================#
#--------------------------Window_MenuStatus-----------------------------------#
#==============================================================================#
class Window_MenuStatus < Window_Selectable#-Window_MenuStatus-#
def initialize
super(0, 0, 640, 480)
self.contents = Bitmap.new(width - 32, height - 32)
self.contents.font.name = $fontname
self.contents.font.size = $fontsize
self.z = 99
refresh
self.active = false
self.index = -1
end
def refresh
self.contents.clear
@item_max = $game_party.actors.size
for i in 0...$game_party.actors.size
x = 110
y = 0 * 116
self.contents.draw_text(380, 0, 100, 100, "Status", 2)
actor = $game_party.actors[0]
$salas = $game_variables[1]
$mortes = $game_variables[2]
self.contents.font.size = 40
self.contents.font.color = system_color
self.contents.draw_text(380, 80, 100, 100, "ATK", 2)
self.contents.draw_text(380, 120, 100, 100, "DEF", 2)
self.contents.font.size = $fontsize
self.contents.draw_text(380, 240, 100, 100, "SALAS", 2)
self.contents.draw_text(400, 260, 100, 100, "MORTES", 2)
self.contents.font.color = normal_color
self.contents.draw_text(460, 240 , 100, 100, $salas.to_s, 2)
self.contents.draw_text(460, 260 , 100, 100, $mortes.to_s, 2)
self.contents.draw_text(460, 80 , 100, 100, actor.atk.to_s, 2)
self.contents.draw_text(460, 120 , 100, 100, actor.pdef.to_s, 2)
self.contents.font.size = 26
draw_actor_name(actor, x + 144, y)
self.contents.font.size = $fontsize
draw_actor_level(actor, x + 318, y)
draw_actor_state(actor, x + 308, y + 64)
draw_actor_exp(actor, x - 90, y + 360)
draw_actor_maxexp(actor, x - 90, y + 380)
draw_actor_hp(actor, x + 32 , y + 32)
draw_actor_sp(actor, x + 32 , y + 64)
end
end
def update_cursor_rect
if @index < 0
self.cursor_rect.empty
else
self.cursor_rect.set(0, @index * 116, self.width - 32, 96)
end
end
end
#==============================================================================#
#------------------------------Window_Base-------------------------------------#
#==============================================================================#
class Window_Base
def draw_actor_maxexp(actor, x, y)
self.contents.font.color = system_color
self.contents.draw_text(x, y, 100, 32, "Próximo")
self.contents.font.color = normal_color
self.contents.draw_text(x + 72, y, 84, 32, actor.next_exp_s, 2)
end
def draw_actor_exp(actor, x, y)
self.contents.font.color = system_color
self.contents.draw_text(x, y, 64, 32, "EXP")
self.contents.font.color = normal_color
self.contents.draw_text(x + 72, y, 84, 32, actor.exp_s, 2)
end
def draw_actor_level(actor, x, y)
self.contents.font.color = system_color
self.contents.draw_text(x, y, 64, 32, "Level")
self.contents.font.color = normal_color
self.contents.draw_text(x + 48, y, 24, 32, actor.level.to_s, 2)
end
end
class Window_Status2 < Window_Base #-Janela de Atributos-#
def initialize(actor)
super(20, 152, 240, 192)
self.contents = Bitmap.new(width - 32, height - 32)
self.contents.font.name = $fontface
self.contents.font.size = $fontsize
@actor = actor
self.opacity = 0
refresh
end
def refresh
self.contents.clear
draw_actor_parameter(@actor, 0, 0, 0)
draw_actor_parameter(@actor, 0, 21, 1)
draw_actor_parameter(@actor, 0, 42, 2)
draw_actor_parameter(@actor, 0, 63, 5)
draw_actor_parameter(@actor, 0, 84, 6)
end
end
#==============================================================================#
#-----------------------------Window_PlayTime----------------------------------#
#==============================================================================#
class Window_PlayTime < Window_Base
def initialize
super(0, 0, 260, 64)
self.contents = Bitmap.new(width - 32, height - 32)
self.contents.font.name = $fontface
self.contents.font.size = $fontsize
self.opacity = 0
refresh
end
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.draw_text(4, 0, 120, 24, "Tempo")
@total_sec = Graphics.frame_count / Graphics.frame_rate
hour = @total_sec / 60 / 60
min = @total_sec / 60 % 60
sec = @total_sec % 60
text = sprintf("%02d:%02d:%02d", hour, min, sec)
self.contents.font.color = normal_color
self.contents.draw_text(64, 0, 120, 24, text, 2)
end
def update
super
if Graphics.frame_count / Graphics.frame_rate != @total_sec
refresh
end
end
end
#==============================================================================#
#-----------------------------Window_Gold--------------------------------------#
#==============================================================================#
class Window_Gold < Window_Base
def initialize
super(0, 0, 222, 64)
self.contents = Bitmap.new(width - 32, height - 32)
self.contents.font.name = $fontface
self.contents.font.size = $fontsize
self.opacity = 0
refresh
end
def refresh
self.contents.clear
self.contents.font.color = normal_color
self.contents.draw_text(+ 74, 0, 100, 32, $game_party.gold.to_s, 2)
self.contents.font.color = system_color
self.contents.draw_text(0, 0, 64, 32, "Ouro", 2)
end
end
Agradecimentos:
Neto RPG - Por criar o script;
Eu :cheers: (Luigi Perillo X) - Por disponibilizar o script.
Última edição por Luigi Perillo X em Dom Nov 14, 2010 12:34 pm, editado 3 vez(es)