XP 스크립트

뭔 이상한 말이 잔뜩 써있네;;

 

 

 

 

 

 

 

 

 

# 寃덇쾫寃?XRXS20. ?湲욊링堉??묎툊洹산튆湲ㅺ툊 ver.1.5 寃덇쾫寃?
# by 沅멸톭, ?롫맧 ?る콠

#==============================================================================
# 嫄?湲뉕툣??洹쎄툤?洹쎄튆湲?
#==============================================================================
module XRXS20
  # 湲귢렌源쏄륵湲귥겇洹??묎땅洹?
  WINDOW_FRAME = true
  #
  # 湲꿸툍源쏄르
  #
  FONT_NAME  = "굴림"
  FONT_COLOR = Color.new(255, 255, 0, 255)
  FONT_SIZE  = 18
  #
  # [??묐쟾??
  #
  TIME_FADEIN  =  8 # 湲꿸툋?湲ㅺ렘源?
  TIME_STOP    = 64 # ??묐캙?
  TIME_FADEOUT = 24 # 湲꿸툋?湲ㅺ렉湲귢르
end
  #--------------------------------------------------------------------------
  # 湲↔툕湲싰르由?
  #--------------------------------------------------------------------------
class Window_Map_Name < Window_Base
  def text_model(text)
    return "" + text + "  "
  end
end
#
#[??]
# ?湲욊링堉밴떻癒⑸쾯沅멸릭源뤾툎湲ㅺ콓.嫄먭텞沅뉕래沅?湲욊링堉밴랭??묎땁洹뤾때洹り컘
#
#==============================================================================
# 嫄?Window_Map_Name_Space
#==============================================================================
class Window_Map_Name_Space < Window_Base
  #--------------------------------------------------------------------------
  # 嫄?湲녾립湲숆툋湲뤾르猷딅뵔??
  #--------------------------------------------------------------------------
  def initialize(x, y, w, h)
    super(x-16, y-16, w+32, h+32)
    self.contents = Bitmap.new(w, h)
    self.opacity = 0
    @align = 2
  end
  #--------------------------------------------------------------------------
  # 嫄?湲꿸툍源쏄르
  #--------------------------------------------------------------------------
  def font
    return self.contents.font
  end
  #--------------------------------------------------------------------------
  # 嫄?鍮믩읅洹⑸짆沅?
  #--------------------------------------------------------------------------
  def draw_text(text)
    self.contents.clear
    return if text.nil?
    #r = self.contents.rect
    #self.contents.draw_text(r, text, 1)
    x = 4
    y = 0
    width = self.contents.width
    text_color = self.contents.font.color.dup
    self.contents.font.color = Color.new(  0,  0,  0, 192)
    self.contents.draw_text(x+2, y+2, width, 32, text, @align)
    self.contents.font.color = Color.new( 64, 64, 64, 192)
    self.contents.draw_text(x-1, y-1, width, 32, text, @align)
    self.contents.draw_text(x+1, y-1, width, 32, text, @align)
    self.contents.draw_text(x-1, y+1, width, 32, text, @align)
    self.contents.draw_text(x+1, y+1, width, 32, text, @align)
    self.contents.font.color = text_color
    self.contents.draw_text(x,   y,   width, 32, text, @align)
    self.visible = true
  end
end
#==============================================================================
# 嫄?Window_Map_Name
#------------------------------------------------------------------------------
# ??湲욊링堉밴랭??묎땅洹↔툊洹산튆湲ㅺ툊沅녠땅媛?
#==============================================================================
class Window_Map_Name < Window_Base
  #--------------------------------------------------------------------------
  # 嫄??븍몠洹쎄튆湲?源쏄툣鍮얜╋
  #--------------------------------------------------------------------------
  attr_accessor :text
  #--------------------------------------------------------------------------
  # 嫄?湲녾립湲숆툋湲뤾르猷딅뵔
  #--------------------------------------------------------------------------
  def initialize
    super(152, 8, 480, 40)
    self.opacity = 0
    self.visible = false
    @space = Window_Map_Name_Space.new(self.x, self.y+4, self.width, self.height-8)
    @space.font.name  = XRXS20::FONT_NAME
    @space.font.color = XRXS20::FONT_COLOR
    @space.font.size  = XRXS20::FONT_SIZE
    @space.font.bold  = true
    # 猷딅뵔??
    @fadein_time    = 0
    @showing_time   = 0
    @fadeouut_time  = 0
  end
  #--------------------------------------------------------------------------
  # 嫄?湲↔툕湲싰르癒좊?
  #     text  : 湲귢렌源쏄륵湲귢떳??묎땅洹〓퉺?살€?
  #--------------------------------------------------------------------------
  def set_text(text)
    if text.nil? or text.empty? or text =~ /^./
      @showing_time = -1
      @text = ""
      self.contents_opacity = 0
      self.visible = false
      @space.visible = false
    else
      # 癒좊?
      @text = text_model(text)
      # ?濡?
      @fadein_time    = XRXS20::TIME_FADEIN
      @fadein_amount  = (255.0 / XRXS20::TIME_FADEIN).ceil
      self.width = @space.contents.text_size(@text).width + 24
      @x_indent = 632 - self.width
      self.x = @x_indent - @fadein_time
      @space.draw_text(@text)
      self.visible = XRXS20::WINDOW_FRAME
    end
  end
  #--------------------------------------------------------------------------
  # 嫄??띕볐
  #--------------------------------------------------------------------------
  def dispose
    @space.dispose
    super
  end
  #--------------------------------------------------------------------------
  # 嫄?湲꿸퉺???쏅Ⅷ
  #--------------------------------------------------------------------------
  def update
    #return if @showing_time < 0
    #
    # 湲꿸툋?湲ㅺ렘源?
    #
    if @fadein_time > 0
      @fadein_time -= 1
      @space.contents_opacity += @fadein_amount
      self.opacity = [self.opacity + @fadein_amount*5/8, 160].min
      self.x = @x_indent - @fadein_time
      @space.x = self.x - (512-self.width)
      if @fadein_time == 0
        @showing_time = XRXS20::TIME_STOP
      end
    #
    # 誘낅쪈???
    #
    elsif @showing_time > 0
      @showing_time -= 1
      if @showing_time == 0
        @fadeouut_time  = XRXS20::TIME_FADEOUT
        @fadeout_amount = (255.0 / XRXS20::TIME_FADEOUT).ceil
      end
    #
    # 湲꿸툋?湲ㅺ렉湲귢르
    #
    elsif @fadeouut_time > 0
      @fadeouut_time -= 1
      self.opacity -= @fadeout_amount * 5/8
      @space.contents_opacity -= @fadeout_amount
      self.x = (@x_indent + XRXS20::TIME_FADEOUT) - @fadeouut_time
      @space.x = self.x - (512-self.width)
      if @fadeouut_time == 0
        self.visible = false
        @space.visible = false
      end
    end
  end
end
#==============================================================================
# 嫄?Scene_Map
#==============================================================================
class Scene_Map
  #--------------------------------------------------------------------------
  # 嫄??湲욊링堉밸즸?뽯뤈
  #--------------------------------------------------------------------------
  def initialize_map_name_window(text = nil)
    if @map_name_window.nil?
      @map_name_window = Window_Map_Name.new
      @map_name_window.text = text if not text.nil?
    end
  end
  #--------------------------------------------------------------------------
  # 嫄?湲쎄렘源쏅즷肉?
  #--------------------------------------------------------------------------
  alias xrxs20_main main
  def main
    # 萸ㅻ섰湲귢렌源쏄륵湲귢랭?용쭫
    initialize_map_name_window
    # 戮j땅
    xrxs20_main
    # 萸ㅻ섰湲귢렌源쏄륵湲귢랭?띕볐
    @map_name_window.dispose
  end
  #--------------------------------------------------------------------------
  # 嫄?湲꿸퉺???쏅Ⅷ
  #--------------------------------------------------------------------------
  alias xrxs20_update update
  def update
    # 萸ㅻ섰湲귢렌源쏄륵湲귢떻?쏅Ⅷ
    @map_name_window.update
    # ?곴톪戮j땅
    xrxs20_update
  end
  #--------------------------------------------------------------------------
  # 嫄?湲듦퉺洹쎄퉪?沅삳ㅎ猷뗫뙴踰?
  #--------------------------------------------------------------------------
  alias xrxs20_transfer_player transfer_player
  def transfer_player
    # ?곴톪戮j땅
    xrxs20_transfer_player
    # 萸ㅻ섰湲귢렌源쏄륵湲귢떻?쏅Ⅷ
    @map_name_window.set_text($game_map.name)
  end
end
#==============================================================================
# 嫄?Game_Map
#==============================================================================
class Game_Map
  #--------------------------------------------------------------------------
  # 嫄??湲욊링堉밴랭濡?꺅
  #--------------------------------------------------------------------------
  def name
    $map_infos = load_data("Data/MapInfos.rxdata") if $map_infos.nil?
    $map_infos[@map_id].name
  end
end


 

Who's 캉쿤

?

배고파요ㅠㅜ

전 댓글을 먹고 살아요ㅠㅜ

댓글 하나만요ㅠㅜ

Comment '6'

List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
공지 스크립트 자료 게시물 작성시 주의사항 습작 2012.12.24 6153
34 HUD 맵이름 스크립트 1 file 긔염둥이♥ 2012.05.19 2913
33 HUD 맵 이름 표시와 미니맵을 같이하자 8 file 뮤리온。 2011.10.08 4191
32 HUD 맵 이름 표시 스크립트 수정하기 (계속 뜨게 하기, 위치 바꾸기 등) 3 뮤리온。 2011.10.08 2886
» HUD 맵이름표시 6 캉쿤 2011.09.14 2381
30 HUD 맵 이름을 표시해주는 스크립트입니다. 25 임희성 2011.02.12 2936
29 HUD 시트르산의 나침반 스크립트 19 file 시트르산 2011.01.23 3195
28 HUD 주인공,NPC이름 머리 나타내기 49 file 송긔 2010.11.28 6059
27 HUD [게이지바]3.0버젼「현재시간, 플레이시간, 걸음수, 윈도우 이동 추가」(HelloCoa2Ver3.0) 63 file 코아 코스튬 2010.10.30 4921
26 HUD [게이지바]2.0버젼「체력,마나,경험치,직업,캐릭터,레벨,돈,맵이름」(HelloCoa2Ver2.0) 67 file 코아 코스튬 2010.10.23 5550
25 HUD MOG_Active_Hud 3 file Bera 2010.09.11 2468
24 HUD MOG_C_HUD. 6 file Bera 2010.09.11 2329
23 HUD HUD Menu 2.0 by Raziel 3 Alkaid 2010.09.07 2031
22 HUD 강화 나침반 스크립트 (원본 by 허걱) 16 file JACKY 2010.08.16 3105
21 HUD 캐릭터 아래 SP,HP표시해주는 스크립트 33 file 김!제스! 2010.08.04 4269
20 HUD 맵이름스크립트 52 file 이안 2010.01.17 3552
19 HUD 이름띄우기스크립트 - [ID홍길동] 이 아닌 [홍길동]으로 표기하기 27 블루레스 2009.11.06 4054
18 HUD [VX 가능] 이벤트 이름 띄우기 41 file 독도2005 2009.08.22 3902
17 HUD [맵이동시 맵이름을 표시] 심플한 디자인 36 file 제로스S2 2009.08.05 5000
16 HUD 머리위에 직업명을 표시해줍니다... 9 file 제로스S2 2009.08.03 2465
15 HUD HUD Menu 1.2 by Raziel 6 file 백호 2009.02.22 2390
Board Pagination Prev 1 2 Next
/ 2