[Script] [ACE] [VXA yêu cầu] Script Map Title

Focker_cFocker_c Posts: 1,577Registered
Ai share cho cái script hiện tên map khi bước vào map với.
«1

Comments

  • KangKang Posts: 453Registered
    Kang dùng cái này:
    #==============================================================================
    # 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
    
    Nhớ Edit cái Graphic Cònig
    Hoặc Click zô đây: https://www.google.com.vn/search?q=Window+Map+Name+&amp;oq=Window+Map+Name+&amp;aqs=chrome..69i57.509j0j4&amp;sourceid=chrome&amp;es_sm=122&amp;ie=UTF-8#q=window+map+name+for+rpg+maker+vx+ace&amp;safe=active&amp;spell=1
  • NagiNagi Posts: 589Registered
    http://taotrochoi.com/showthread.php?tid=46
    http://taotrochoi.com/showthread.php?tid=978
    Không đẹp lắm nhưng cũng tạm ngó được.
    :duanghich:
  • David ChaseDavid Chase Posts: 1,766Registered
    cái này gọi là location script?
    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?
  • KangKang Posts: 453Registered
    lạy hồ pác David, thời này ít ng xài XP lắp, em khuyên pác nên chuyển qua xài VXA luôn cho đồng bộ =]]
  • kumuzukumuzu Posts: 669Registered
    cái này gọi là location script?
    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
  • David ChaseDavid Chase Posts: 1,766Registered
    kumuzu wrote:
    cái này gọi là location script?
    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ó
  • Focker_cFocker_c Posts: 1,577Registered
    Cái của Kang thì call ra như nào đây ?
  • KangKang Posts: 453Registered
    chả cần call, nó là mặc định rồi
    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
  • dsiver144dsiver144 Posts: 1,064Registered
    Kang wrote:
    chả cần call, nó là mặc định rồi
    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
    ReK5zFD.png
  • NagiNagi Posts: 589Registered
    Dark Sky wrote:
    This is result! Có chỉnh sửa :P
    ReK5zFD.png
    Nền hơi xấu, trong suốt hoặc bán trong suốt có khi đẹp hơn...
    Kiểu như vậy nè:
    8XAVx.png
  • dsiver144dsiver144 Posts: 1,064Registered
    Ồ, tks đã góp ý :D
  • Focker_cFocker_c Posts: 1,577Registered
    Thực sự là có một số map ko muốn hiện tên khi trans qua thì phải làm thế nào ?
    Script trên ko có xài lệnh call để switch đc :(
    @Dark Sky
    @Nagi
  • NagiNagi Posts: 589Registered
    Focker_c wrote:
    Thực sự là có một số map ko muốn hiện tên khi trans qua thì phải làm thế nào ?
    Script trên ko có xài lệnh call để switch đc :(
    @Dark Sky
    @Nagi
    Đừng đặt display name cho nó.
  • Focker_cFocker_c Posts: 1,577Registered
    Fix lại theo kiểu call switch dùm đc ko ? Để làm một cái mẫu nhìn vào đấy mò
Sign In or Register to comment.