XP 스크립트

이건 비밀님이랑 KimTJ 님이 알려줄셔서 간신히 했음. 이 스크립트는 왼쪽 아래 구석에 경험치가 하얀글씨로 나올것임.

class Game_Actor < Game_Battler
  def exp_rate
    if @exp_list[@level+1] - @exp_list[@level] > 0
      return (@exp - @exp_list[@level]).to_f / (@exp_list[@level+1] - @exp_list[@level]).to_f
    else
      return 0
    end
  end
end
class Window_ExpRate < Window_Base
  def initialize
    super(178, 441, 100, 60) # <- location, size
    self.contents = Bitmap.new(width - 32, height - 32)
   
    self.contents.font = Font.new("Tahoma", 30) # <- font, size
    self.opacity = 0
self.back_opacity = 0
  end
  def refresh
    self.contents.clear
    self.contents.draw_text(0, 0, 100, 30, @show_text)
  end
  def actor
    $game_party.actors[0] # <- 파티 0번째
  end
  def update
    super
    text = sprintf("%d%", (actor.exp_rate * 100).to_i)
    if @show_text != text
      @show_text = text
      refresh
    end
  end
end
class Scene_Map
  alias update_before_map update
  def update
    update_before_map
    @window_exp = Window_ExpRate.new unless @window_exp
    @window_exp.update
    unless $scene.is_a?(Scene_Map)
      @window_exp.dispose
      @window_exp = nil
    end
  end
end

Who's 백호

?

이상혁입니다.

http://elab.kr

Comment '8'

List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
공지 스크립트 자료 게시물 작성시 주의사항 습작 2012.12.24 7314
28 메뉴 메뉴에 얼굴 그래픽 표시 4 file 백호 2009.02.21 3135
27 메뉴 메뉴에서 실제시간 보기 2 백호 2009.02.21 1130
26 메뉴 메뉴에서 커맨더실행하기 5 WMN 2008.04.06 1702
25 메뉴 메뉴화면 변경 스크립트 1 file 백호 2009.02.21 2801
24 메뉴 메뉴화면에 '해야 할 일' 알려주는 창 넣기 11 하진 2012.04.23 3302
23 메뉴 메이플스토리처럼 메뉴를^^ 57 file 딸기님 2010.07.13 7200
» 메뉴 비밀소년님의 필드에서 경치 % 로 나오는거 윈도우 없이 8 백호 2009.02.22 1807
21 메뉴 새로운 cms 4 file 백호 2009.02.22 2134
20 메뉴 새로운 메뉴 15 file 또라에몽 2010.07.17 5354
19 메뉴 새로운 메뉴 시스템 을 한글화 및 약간 개조 3 file 백호 2009.02.21 2229
18 메뉴 수정, 추가 링메뉴 10 file 백호 2009.02.22 2925
17 메뉴 스탯올리기 시스템 (액알가능) 27 file 백호 2009.02.22 3416
16 메뉴 스테이터스 일람 스크립트 file 백호 2009.02.21 1357
15 메뉴 스테이터스 화면 from Harts Horn 2 백호 2009.02.22 1598
14 메뉴 스테이터스 화면에 넥스트 표시 1 file 백호 2009.02.21 1775
13 메뉴 온라인메뉴처럼!! 메이플 메뉴처럼!! 변신~스크립트 33 WMN 2008.03.17 6846
12 메뉴 자세한 캐릭터 정보표시 스크립트 버전2 5 아방스 2009.01.12 2344
11 메뉴 자세항 개인 상태화면 8 아방스 2009.01.12 2382
10 메뉴 자작 메뉴 스크립트들(L's Simple CMS and menu scenes) (SDK 호환?) 10 Alkaid 2010.09.02 3495
9 메뉴 자작 커스텀 메뉴(데모 첨부) 3 백호 2009.02.22 2362
Board Pagination Prev 1 2 3 4 5 Next
/ 5