자유게시판

#==================================================
# ** Stamina
# By onidsouza
# Version 1.2
# 02/26/09
#-------------------------------------------------
module OniStamina

 Initial = 100 # Initial stamina value
 
  EvolutionRate = 1.3 #Float value representing the level up evolution rate.
                      # Leave 1.0 for none
 
  InitialRecoverFrames = 15 # Recover Frames Rate
 
  RecoverEvolutionRate = 3 #Float value representing the level up recover time
                             # evolution rate. Leave 1.0 for none.
 
  ActorMember = 0# Number from 0 to 3, representing the actor in the party.

end

class Game_Actor
 
  alias onistamina_init initialize
  alias onistamina_lvlup level_up
 
  attr_reader :stamina
  attr_accessor :maxsta
  attr_reader :recover
 
  def initialize(actor_id)
    onistamina_init(actor_id)
    @stamina = OniStamina::Initial
    @maxsta = @stamina
    @recover = OniStamina::InitialRecoverFrames
  end
 
  def level_up
    @maxsta = @maxsta * OniStamina::EvolutionRate
    @recover = @recover / OniStamina::RecoverEvolutionRate
    @maxsta = @maxsta.to_i
    @recover = @recover.to_i
    onistamina_lvlup
  end
 
  def stamina_text
    (@stamina).to_s + '/' + (@maxsta).to_s
  end
 
  def lose_sta(x)
    if ((@stamina - x) >= 0)
    @stamina = @stamina - x
    else
    @stamina = 0
    end
  end
 
  def gain_sta(x)
    if ((@stamina + x) <= @maxsta)
    @stamina = @stamina + x
    end
  end
 
end

class Window_Stamina < Window_Base
 
  def initialize(x, y, wid, hei)
    super(x, y, wid, hei)
    @stamina = $game_party.members[OniStamina::ActorMember].stamina
    @maxsta = $game_party.members[OniStamina::ActorMember].stamina
    self.opacity = 0
  end
 
  def refresh
    self.contents.clear
    draw_stamina(0, 0)
  end
 
  def draw_stamina(x, y, width = 100)
    wd = width * $game_party.members[OniStamina::ActorMember].stamina / $game_party.members[OniStamina::ActorMember].maxsta
    self.contents.fill_rect(x, y, width, 10, Color.new(0, 0, 0))
    self.contents.fill_rect(x, y, wd, 10, Color.new(255, 255, 119))
    text_wid = contents.text_size($game_party.members[OniStamina::ActorMember].stamina_text).width
    self.contents.draw_text(x + 0, y + 15, text_wid, 20, $game_party.members[OniStamina::ActorMember].stamina_text)
  end
 
end

class Scene_Map
 
  alias onista_start start
  alias onista_terminate terminate
  alias onista_update update
  attr_reader :winsta
 
  def start
    onista_start
    @waiting_sta = 0
    @winsta = Window_Stamina.new(-10, 1, 150, 80)
  end
 
  def terminate
    onista_terminate
    @winsta.dispose
  end
 
  def update
    onista_update
    if $game_player.moving? and $game_player.dash?
      $game_party.members[OniStamina::ActorMember].lose_sta(1)
    end
    if $game_system.waiting_sta == $game_party.members[OniStamina::ActorMember].recover
      $game_party.members[OniStamina::ActorMember].gain_sta(1)
    end
    @winsta.refresh
  end
 
end

class Game_Player < Game_Character
 
  alias sta_dash? dash?
 
  def dash?
    return false if $game_party.members[OniStamina::ActorMember].stamina == 0
    sta_dash?
  end
 
end

class Game_System
 
  attr_reader :waiting_sta
 
  alias onista_update update
  alias onista_initialize initialize
 
  def initialize
    @waiting_sta = 0
    onista_initialize
  end
 
  def update
    @waiting_sta = @waiting_sta + 1
    @waiting_sta = 0 if @waiting_sta > $game_party.members[OniStamina::ActorMember].recover
    onista_update
  end
end

TAG •

Who's 라이네크

?

작품연대기

XP - 아인 스토리 (만들다가 어려워서 포기)

VX - 타르타로스 -운명의검- (모든것을 쏟아부엇지만 아버님이 삭제하셔서 멸망)

2003 - 타르타로스 -운명의검- Again (다시 2003으로 도전하지만 몇달만에 컴터를다시키니 자료증발)

XP - 엘티어즈 ~고대의병기~ (현재만드는중 이건 완성한다 ... 젠장..)

 

으으 자료복구할방법은 업는겝니까 ㅠㅠ

지금만드는건 완성시킨다 젠장

Comment '2'
  • profile
    시옷전사 2009.09.29 19:11
    질문을 좀 자세히 해주셧으면 하는 소박한 소망이 있습니다.
  • ?
    TOFUMAN 2009.09.30 00:29

    윈도우를 뜨게 만들지 않는 방법 말씀 하시는 거죠? 그럴거면 간단하게 draw_stamina 펑션 부분을 지워주면 되구요. 그 펑션을 이용하는 (그냥 간단하게 말해 ctrl + f로 draw_stamina)모든 곳을 찾아내서 draw_stamina를 지워보세요. 아마 될 듯?


  1. 아방스 게시물 · 댓글 작성 규칙 (최근 수정일 2015.11.25)

    Date2012.07.17 Category공지 By완폐남™ Views41177
    read more
  2. !

    Date2010.02.27 Category잡담 By§포뇨§ Views382
    Read More
  3. !!

    Date2011.10.21 Category잡담 By은색바람 Views1111
    Read More
  4. !!

    Date2016.03.05 Category가입 By엡스타인 Views96
    Read More
  5. !!!

    Date2010.04.18 Category잡담 By포뇨 Views453
    Read More
  6. !~엘카르디아 축전~!

    Date2010.11.04 Category잡담 By봉시기 Views507
    Read More
  7. " 간보지마세요 제가 음식입니까? "

    Date2014.01.31 Category막장 ByJACKY Views467
    Read More
  8. "ICON2008" (국제콘텐츠개발자컨퍼런스) Mgame의 "풍림화산" 제작진과 무라타렌지 등 국내외 유명 콘텐츠 개발자가 9월에 부산에 옵니다^^

    Date2008.07.24 Bymi41 Views1411
    Read More
  9. "Mania의 (10년째) 게임제작 인생 연표" * 스크롤 압박 주의

    Date2010.09.09 Category잡담 ByDirector Views3524
    Read More
  10. "N"자가 또 사라졌네..

    Date2011.02.13 Category잡담 By나방's Views512
    Read More
  11. "ㅆ" 이거 스태미나 감추려면 어찌;;

    Date2009.09.29 By라이네크 Views875
    Read More
  12. "게임을 빼느니 차라리 마약을 빼겠다"

    Date2014.02.17 Category잡담 ByOmegaroid Views924
    Read More
  13. "게임의 플롯은 과대평가되고 있다"?

    Date2014.03.19 Category잡담 ByOmegaroid Views784
    Read More
  14. "게임중독법, 난 찬성일세"…12만명 서명

    Date2014.02.09 Category막장 By파치리스 Views629
    Read More
  15. "떽" 은 아직 살아 움직이고 있다!

    Date2013.05.03 Category잡담 ByTheEK Views1029
    Read More
  16. "몽니 나를 떠나가던" 방송3사 및 케이블 방송불가 판정!! 뮤비 확인!!

    Date2010.06.22 Category잡담 By화양연화 Views772
    Read More
  17. "배포"가 아방스 홈피에 온이유!

    Date2008.03.02 Category잡담 By배포 Views1029
    Read More
  18. "여기 재밌는 겜은 뭐가 있나요?"

    Date2014.01.27 Category잡담 Bysudoxe Views544
    Read More
  19. "오덕후" 라는 이슈에 대해서 다시 한 번 정리 해드립니다.

    Date2012.07.04 Category잡담 ByTheEK Views963
    Read More
  20. "우리가 왜 자네를 뽑았는지 아나?"

    Date2013.05.31 By파치리스 Views1294
    Read More
  21. "제생일을맞춰보세요" 이벤트결과

    Date2010.04.16 Category잡담 By포효 Views464
    Read More
목록
Board Pagination Prev 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 ... 755 Next
/ 755