O TEMA DO FÓRUM ESTÁ EM MANUTENÇÃO. FEEDBACKS AQUI: ACESSAR

Dod Simple Menu VX

Iniciado por LoboShow, 04/12/2012 às 17:50

Dod Simple Menu VX

Compativel com: RMVX
Compatibilidade : ?
Facilidade de uso: ?
Lag gerado: ?

[box class=titlebg]
Para que serve o script
[/box]
É o menu padrão do VX, só que editado.  :=|:

[box class=titlebg]
Script
[/box]
#########################
#Nome:Dod simple menu VX#
#########################

#########################
#Autor:dodoop############
#########################

############
#Versão:1.0#
############

############
#Descrisão:########################
#O menu padrão do RMVX modificado.#
###################################

##############
#Instrunções:################################################################
#1.Não é obrigatório mas eu recomendo substituiro Scene_Menu por este script#
#para evitar conflitos com outros scripts.######################################
#2.Se voce não queser que seja desenhado o gráfico do personagem no menu apague#
#a linha 171###################################################################
############


#############
# Scene_Menu#
#############

class Scene_Menu < Scene_Base
 
  def initialize(menu_index = 0)
    @menu_index = menu_index
  end
 
  def start
    super
    create_menu_background
    create_command_window
    @gold_window = Window_Gold.new(0, 360)
    @status_window = Window_MenuStatus.new(160, 0)
    @gold_window.opacity = 0
    @status_window.opacity = 0
  end
 
  def terminate
    super
    dispose_menu_background
    @command_window.dispose
    @gold_window.dispose
    @status_window.dispose
  end
 
  def update
    super
    update_menu_background
    @command_window.update
    @gold_window.update
    @status_window.update
    if @command_window.active
      update_command_selection
    elsif @status_window.active
      update_actor_selection
    end
  end
 
  def create_command_window
    s1 = Vocab::item
    s2 = Vocab::skill
    s3 = Vocab::equip
    s4 = Vocab::status
    s5 = Vocab::save
    s6 = Vocab::game_end
    @command_window = Window_Command.new(160, [s1, s2, s3, s4, s5, s6])
    @command_window.opacity = 0
    @command_window.index = @menu_index
    if $game_party.members.size == 0          # Se não houver membros na equipe
      @command_window.draw_item(0, false)     # Desabilita "Items"
      @command_window.draw_item(1, false)     # Desabilita "Habilidades"
      @command_window.draw_item(2, false)     # Desabilita "Equipamentos"
      @command_window.draw_item(3, false)     # Desabilita "Status"
    end
    if $game_system.save_disabled             # Se salvar for proibido
      @command_window.draw_item(4, false)     # Desabilita "Salvar"
    end
  end
 
  def update_command_selection
    if Input.trigger?(Input::B)
      Sound.play_cancel
      $scene = Scene_Map.new
    elsif Input.trigger?(Input::C)
      if $game_party.members.size == 0 and @command_window.index < 4
        Sound.play_buzzer
        return
      elsif $game_system.save_disabled and @command_window.index == 4
        Sound.play_buzzer
        return
      end
      Sound.play_decision
      case @command_window.index
      when 0      # Item
        $scene = Scene_Item.new
      when 1,2,3  # Habilidades, equipamento, status
        start_actor_selection
      when 4      # Salvar
        $scene = Scene_File.new(true, false, false)
      when 5      # Fim de jogo
        $scene = Scene_End.new
      end
    end
  end
 
  def start_actor_selection
    @command_window.active = false
    @status_window.active = true
    if $game_party.last_actor_index < @status_window.item_max
      @status_window.index = $game_party.last_actor_index
    else
      @status_window.index = 0
    end
  end
 
  def end_actor_selection
    @command_window.active = true
    @status_window.active = false
    @status_window.index = -1
  end
 
  def update_actor_selection
    if Input.trigger?(Input::B)
      Sound.play_cancel
      end_actor_selection
    elsif Input.trigger?(Input::C)
      $game_party.last_actor_index = @status_window.index
      Sound.play_decision
      case @command_window.index
      when 1  # Habilidades
        $scene = Scene_Skill.new(@status_window.index)
      when 2  # Equipamento
        $scene = Scene_Equip.new(@status_window.index)
      when 3  # Status
        $scene = Scene_Status.new(@status_window.index)
      end
    end
  end
end

###################
#Window_MenuStatus#
###################

class Window_MenuStatus < Window_Selectable
 
  def initialize(x, y)
    super(x, y, 384, 416)
    refresh
    self.active = false
    self.index = -1
  end
 
  def refresh
    self.contents.clear
    @item_max = $game_party.members.size
    for actor in $game_party.members
     
      x = 104
      y = actor.index * 96 + WLH / 2
      draw_actor_face(actor, 2, actor.index * 96 + 2, 92)
      draw_actor_graphic(actor, x - 90, y + 80)
      draw_actor_name(actor, x-30, y)
      draw_actor_class(actor, x-20, y+20)
      #draw_actor_class(actor, x-20 + 120, y)
      draw_actor_level(actor, x-60, y+30 + WLH * 1)
      draw_actor_state(actor, x, y + WLH * 2)
      draw_actor_hp(actor, x + 80, y + WLH * 1)
      draw_actor_mp(actor, x + 60, y + WLH * 2)
      #draw_actor_hp(actor, x + 120, y + WLH * 1)
      #draw_actor_mp(actor, x + 120, y + WLH * 2)
       
    end
  end
 
  def update_cursor
    if @index < 0               
      self.cursor_rect.empty
    elsif @index < @item_max   
      self.cursor_rect.set(0, @index * 96, contents.width, 96)
    elsif @index >= 100         
      self.cursor_rect.set(0, (@index - 100) * 96, contents.width, 96)
    else                       
      self.cursor_rect.set(0, 0, contents.width, @item_max * 96)
    end
  end
end


[box class=titlebg]
Imagens
[/box]

[box class=titlebg]
Créditos e Avisos
[/box]
Criador : dodoop 

Bem, prefiro o menu padrão do vx, a falta de qualquer efeito deixou bem feio e ruim de olhar durante o menu. Mas há quem queira, obrigado por compartilhar.
To Die Is To Find Out If Humanity Ever Conquers Death