조회 수 337 추천 수 0 댓글 0
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
# 련격 Ver 1.01
# 배포원·서포트 URL
# http://members.jcom.home.ne.jp/cogwheel/

#==============================================================================
# ■ Scene_Battle (분할 정의 4)
#------------------------------------------------------------------------------
#  배틀 화면의 처리를 실시하는 클래스입니다.
#==============================================================================
# 애니메이션에 힘 0의 플래시가 존재했을 경우 ,
# 빨강:배율초록:+스킬·아이템 ID 로 데미지 계산을 실시한다.

class Scene_Battle
  #--------------------------------------------------------------------------
  # ● ATB 기초 셋업
  #--------------------------------------------------------------------------
  alias :atb_setup_straight :atb_setup
  def atb_setup
    atb_setup_straight
    for battler in $game_party.actors + $game_troop.enemies
      battler.total_damage = {}
    end
  end
  #--------------------------------------------------------------------------
  # ● 액션 갱신 (메인 국면)
  #--------------------------------------------------------------------------
  def action_phase(battler)
    while true
      # action 가 1 의 경우 , 버틀러가 행동중인지 어떤지 확인
      if @action == 1 and battler.phase < 3
        for target in battler.target
          speller = synthe? (target)
          if speller == nil
            # 타겟이 통상 행동중의 경우
            if @action_battlers.include? (target)
              if target.phase > 2
                return
              end
            end
          else
            # 타겟이 제휴 스킬 발동중의 경우
            for spell in speller
              if @action_battlers.include? (spell)
                if spell.phase > 2
                  return
               end
              end
            end
          end
        end
      end
      case battler.phase
      when 1
        update_phase4_step1(battler)
      when 2
        update_phase4_step2(battler)
      when 3
        update_phase4_step3(battler)
      when 4
        update_phase4_step4(battler)
      when 5
        update_phase4_step5(battler)
      when 6
        update_phase4_step6(battler)
      end
      # 웨이트가 들어갔을 경우
      if battler.wait > 0
        # 웨이트 카운트를 줄여 종료
        battler.wait -= 1
        break
      end
      # 행동 종료했을 경우 루프를 빠진다
      unless @action_battlers.include? (battler)
        break
      end
    end
  end
  #--------------------------------------------------------------------------
  # ● 프레임 갱신 (메인 국면 스텝 1 : 액션 준비)
  #--------------------------------------------------------------------------
  def update_phase4_step1(battler)
    # 벌써 전투로부터 떼어져 있는 경우
    if battler.index == nil
      @action_battlers.delete(battler)
      anime_wait_return
      battler.wait = 1
      return
    end
    speller = synthe? (battler)
    if speller == nil
      # 데미지식등 있고 안의 경우
      unless battler.damage.empty?  or @action > 2
        battler.wait = 1
        return
      end
      # 행동 가능한지 어떤지 판정
      unless battler.movable?
        battler.phase = 6
        return
      end
   else
      # 데미지식등 있고 안의 경우
      for spell in speller
        unless spell.damage.empty?  or @action > 2
          battler.wait = 1
          return
        end
        # 행동 가능한지 어떤지 판정
        unless spell.movable?
          battler.phase = 6
          return
        end
      end
    end
    # 스킬 사용시 , 영창 시간 설정
    # 강제 액션 또한 @force 가 2 시에는 스킬을 즉시 발동
    if battler.current_action.kind == 1 and
      (not battler.current_action.forcing or @force ! = 2)
      if battler.rtp == 0
        # 스킬 영창중이라면 , 해제
        skill_reset(battler)
        # 스킬 영창 시간 설정
        recite_time(battler)
        # 제휴기술 설정
        synthe_spell(battler)
        # 스킬을 영창 하는 경우
        if battler.rtp > 0
          # 강제 액션 또한 @force 가 1 시에는 제휴 스킬만 즉시 발동
          speller = synthe? (battler)
          if battler.current_action.forcing and @force > 0 and speller ! = nil
            for spell in speller
              spell.rt = spell.rtp
            end
          else
            battler.blink = true
            if battler.current_action.forcing
              $game_temp.forcing_battler = nil
              battler.current_action.forcing = false
            end
            @action_battlers.delete(battler)
            return
          end
        end
      end
    end
    # 엑터의 명 멸망 효과 OFF
    if battler ! = nil
      battler.blink = false
    end
    speller = synthe? (battler)
    if speller == nil
      @spell_p.delete(battler)
      @spell_e.delete(battler)
    else
      for spell in speller
        spell.blink = false
        @spell_p.delete(spell)
        @spell_e.delete(spell)
      end
    end
    # 스텝 2 에 이행
    battler.phase = 2
  end
  #--------------------------------------------------------------------------
  # ● 프레임 갱신 (메인 국면 스텝 2 : 액션 개시)
  #--------------------------------------------------------------------------
  def update_phase4_step2(battler)
    # 강제 액션이 아니면
    unless battler.current_action.forcing
      # 제약이 [적을 통상 공격하는] 인가 [아군을 통상 공격하는] 의 경우
      if battler.restriction == 2 or battler.restriction == 3
        # 액션에 공격을 설정
        battler.current_action.kind = 0
        battler.current_action.basic = 0
      end
    end
    # 액션의 종별보다 공격 애니메이션을 취득한다
    case battler.current_action.kind
    when 0 # 기본
      if battler.is_a? (Game_Actor)
        base_id = battler.weapon_id
      end
      anime_id = battler.animation2_id
      # 방어 등 특수 행동의 경우는 다음의 스텝에
      unless make_basic_action_preparation(battler)
        return
      end
      # 전투가 종료했을 경우는 행동을 캔슬
      if fin?
        battler.phase = 6
        return
      end
    when 1 # 스킬
      base_id = battler.current_action.skill_id
      anime_id = $data_skills[battler.current_action.skill_id]. animation2_id
      # 스킬을 사용할 수 없는 경우는 행동을 캔슬
      unless make_skill_action_preparation(battler)
        return
      end
      # 전투가 종료했을 경우는 행동을 캔슬
      if fin?  and $data_skills[anime_id]. scope == 1..2
        battler.phase = 6
        return
      end
    when 2 # 아이템
      base_id = battler.current_action.item_id
      anime_id = $data_items[battler.current_action.item_id]. animation2_id
      # 아이템을 사용할 수 없는 경우는 행동을 캔슬
      unless make_item_action_preparation(battler)
        return
      end
      # 전투가 종료했을 경우는 행동을 캔슬
      if fin?  and $data_items[anime_id]. scope == 1..2
        battler.phase = 6
        return
      end
    end
    # 애니메이션을 검색해 , 련격성을 변수 serial에 대입한다
    serial = []
    frame = 0
    if $data_animations[anime_id] ! = nil
      for animation in $data_animations[anime_id]. timings
        color = animation.flash_color
        # 애니메이션·플래시의 힘이 0의 경우
        if color.alpha == 0
          serial.push([color.red.to_i , color.green , animation.frame - frame])
          frame = animation.frame
        end
      end
      # 련격성이 없는 경우 단발 공격
      if serial.empty?
        serial = [[20, 100, $data_animations[anime_id]. frame_max - 5]]
      end
    else
      # 애니메이션이 존재하지 않는 경우
      serial = [[20, 100, 0]]
    end
    # 해시 total_damage 의 작성
    total_damage = {}
    for target in battler.target
      total_damage[target] = []
    end
    # 련격 회수분 데미지 계산을 실시한다
    for attack in serial
      # 액션의 종별로 분기
      case battler.current_action.kind
      when 0  # 기본
        if battler.is_a? (Game_Actor)
          # 버틀러가 엑터의 경우 , 공격시로 무기를 변경한다
          battler.change_weapon(base_id + attack[1] - 100)
        end
        make_basic_action_result(battler)
      when 1  # 스킬
        # 제휴 스킬을 생각해 스킬 ID의 변경은 내부 처리로 실시한다
        make_skill_action_result(battler , attack[1] - 100)
      when 2  # 아이템
        # 아이템 ID를 설정분 변화시킨다
        battler.current_action.item_id = base_id + attack[1] - 100
        make_item_action_result(battler)
      end
      # total_damage 에 데미지를 대입
      for target in battler.target
        # 데미지가 있는 경우 , 데미지를 X /20배가 된다.
        if target.damage[battler]. is_a? (Numeric)
          damage = target.damage[battler] * attack[0] / 20
        else
          damage = target.damage[battler]
        end
        # 회복 HP량이 있는 경우 , 회복 HP량을 X /20배가 된다.
        if target.recover_hp[battler]. is_a? (Numeric)
          recover_hp = target.recover_hp[battler] * attack[0] / 20
        end
        # 회복 SP량이 있는 경우 , 회복 SP량을 X /20배가 된다.
        if target.recover_sp[battler]. is_a? (Numeric)
          recover_sp = target.recover_sp[battler] * attack[0] / 20
        end
        critical = target.critical[battler]
        # total_damage = [데미지 , 위기 플래그 , 회복 HP량 , 회복 SP량 ,
        #                 스테이트 변화 , 스테이트 회복 , 대기 프레임 시간]
        total_damage[target]. push([damage , critical , recover_hp , recover_sp ,
          target.state_p[battler], target.state_m[battler], attack[2]])
      end
    end
    # 토탈 데미지를 , 버틀러의 인스턴스에 대입
    for target in battler.target
      target.total_damage[battler] = total_damage[target]
    end
    # 무기·스킬·아이템 ID를 통상에 되돌린다
    case battler.current_action.kind
    when 0  # 기본
      if battler.is_a? (Game_Actor)
        battler.change_weapon(base_id)
      end
    when 1  # 스킬
      battler.current_action.skill_id = base_id
    when 2  # 아이템
      battler.current_action.item_id = base_id
    end
    if battler.phase == 2
      # 스텝 3 에 이행
      battler.phase = 3
    end
  end
  #--------------------------------------------------------------------------
  # ● 기본 액션 준비
  #--------------------------------------------------------------------------
  def make_basic_action_preparation(battler)
    # 공격의 경우
    if battler.current_action.basic == 0
      # 애니메이션 ID 를 설정
      battler.anime1 = battler.animation1_id
      battler.anime2 = battler.animation2_id
      # 행동측 버틀러가 에너미의 경우
      if battler.is_a? (Game_Enemy)
        if battler.restriction == 3
          target = $game_troop.random_target_enemy
        elsif battler.restriction == 2
          target = $game_party.random_target_actor
        else
          index = battler.current_action.target_index
          target = $game_party.smooth_target_actor(index)
        end
      end
      # 행동측 버틀러가 엑터의 경우
      if battler.is_a? (Game_Actor)
        if battler.restriction == 3
          target = $game_party.random_target_actor
        elsif battler.restriction == 2
          target = $game_troop.random_target_enemy
        else
          index = battler.current_action.target_index
          target = $game_troop.smooth_target_enemy(index)
        end
      end
      # 대상측 버틀러의 배열을 설정
      battler.target = [target]
      return true
    end
    # 방어의 경우
    if battler.current_action.basic == 1
      # 스텝 3 에 이행
      battler.phase = 3
      return false
    end
    # 도망치는 것 경우
    if battler.is_a? (Game_Enemy) and battler.current_action.basic == 2
      # 도망친다
      battler.escape
      # 스텝 3 에 이행
      battler.phase = 3
      return false
    end
    # 굳이 하지 않는 것 경우
    if battler.current_action.basic == 3
      # 스텝 6 에 이행
      battler.phase = 6
      return false
    end
  end
  #--------------------------------------------------------------------------
  # ● 스킬 액션 준비
  #--------------------------------------------------------------------------
  def make_skill_action_preparation(battler)
    # 스킬을 취득
    @skill = $data_skills[battler.current_action.skill_id]
    # 제휴 스킬인지 어떤지 확인
    speller = synthe? (battler)
    # 강제 액션이 아니면
    unless battler.current_action.forcing
      # SP 끊어지고등으로 사용할 수 없게 되었을 경우
      if speller == nil
        unless battler.skill_can_use? (@skill.id)
          # 스텝 6 에 이행
          battler.phase = 6
         return false
        end
      end
    end
    # SP 소비
    temp = false
    if speller ! = nil
      for spell in speller
        if spell.current_action.spell_id == 0
          spell.sp -= @skill.sp_cost
        else
          spell.sp -= $data_skills[spell.current_action.spell_id]. sp_cost
        end
        # 스테이터스 윈도우를 리프레쉬
        status_refresh(spell)
      end
    else
      battler.sp -= @skill.sp_cost
      # 스테이터스 윈도우를 리프레쉬
      status_refresh(battler)
    end
    # 애니메이션 ID 를 설정
    battler.anime1 = @skill.animation1_id
    battler.anime2 = @skill.animation2_id
    # 코먼 이벤트 ID 를 설정
    battler.event = @skill.common_event_id
    # 대상측 버틀러를 설정
    set_target_battlers(@skill.scope , battler)
    return true
  end
  #--------------------------------------------------------------------------
  # ● 아이템 액션 준비
  #--------------------------------------------------------------------------
  def make_item_action_preparation(battler)
    # 아이템을 취득
    @item = $data_items[battler.current_action.item_id]
    # 아이템 끊어지고등으로 사용할 수 없게 되었을 경우
    unless $game_party.item_can_use? (@item.id)
      # 스텝 6 에 이행
      battler.phase = 6
      return false
    end
    # 소모품의 경우
    if @item.consumable
      # 사용한 아이템을 1 줄인다
      $game_party.lose_item(@item.id , 1)
    end
    # 애니메이션 ID 를 설정
    battler.anime1 = @item.animation1_id
    battler.anime2 = @item.animation2_id
    # 코먼 이벤트 ID 를 설정
    battler.event = @item.common_event_id
    # 대상을 결정
    index = battler.current_action.target_index
    target = $game_party.smooth_target_actor(index)
    # 대상측 버틀러를 설정
    set_target_battlers(@item.scope , battler)
    return true
  end
  #--------------------------------------------------------------------------
  # ● 기본 액션 결과 작성
  #--------------------------------------------------------------------------
  def make_basic_action_result(battler)
    # 통상 공격의 효과를 적용
    for target in battler.target
      target.attack_effect(battler)
    end
  end
  #--------------------------------------------------------------------------
  # ● 스킬 액션 결과 작성
  #--------------------------------------------------------------------------
  def make_skill_action_result(battler , plus_id)
    # 스킬을 취득
    @skill = $data_skills[battler.current_action.skill_id + plus_id]
    # 제휴 스킬인지 어떤지 확인
    speller = synthe? (battler)
    # 스킬의 효과를 적용
    for target in battler.target
      if speller ! = nil
        damage = 0
        effective = false
        state_p = []
        state_m = []
        for spell in speller
          if spell.current_action.spell_id ! = 0
            @skill = $data_skills[spell.current_action.spell_id + plus_id]
          end
          effective |= target.skill_effect(spell , @skill)
          if target.damage[spell]. class ! = String
            damage += target.damage[spell]
          elsif effective == true
            effect = target.damage[spell]
          end
          state_p += target.state_p[spell]
          state_m += target.state_m[spell]
          target.damage.delete(spell)
          target.state_p.delete(spell)
          target.state_m.delete(spell)
        end
        if damage ! = 0
          target.damage[battler] = damage
        elsif effective = true
          target.damage[battler] = effect
        end
        target.state_p[battler] = state_p
        target.state_m[battler] = state_m
      else
        target.skill_effect(battler , @skill)
      end
    end
  end
  #--------------------------------------------------------------------------
  # ● 아이템 액션 결과 작성
  #--------------------------------------------------------------------------
  def make_item_action_result(battler)
    # 아이템을 취득
    @item = $data_items[battler.current_action.item_id]
    # 아이템의 효과를 적용
    for target in battler.target
      target.item_effect(@item , battler)
    end
  end
  #--------------------------------------------------------------------------
  # ● 프레임 갱신 (메인 국면 스텝 4 : 대상측 애니메이션)
  #--------------------------------------------------------------------------
  def update_phase4_step4(battler)
    # 카메라 설정
    if battler.target[0]. is_a? (Game_Enemy) and battler.anime1 ! = 0
      camera_set(battler)
    end
    # 대상측 애니메이션
    for target in battler.target
      target.animation.push([battler.anime2 ,
                                          (target.damage[battler] ! = \"Miss\")])
      unless battler.anime2 == 0
        battler.wait = 2 * target.total_damage[battler][0][6] - 1 +
          Graphics.frame_count % 2
      end
    end
    # 스텝 5 에 이행
    battler.phase = 5
  end
  #--------------------------------------------------------------------------
  # ● 프레임 갱신 (메인 국면 스텝 5 : 데미지 표시)
  #--------------------------------------------------------------------------
  def update_phase4_step5(battler)
    next_step = true
    # 데미지 표시
    for target in battler.target
      # total_damage 보다 전 데미지를 산출
      total_damage = target.total_damage[battler]. shift
      target.damage[battler] = total_damage[0]
      target.critical[battler] = total_damage[1]
      target.recover_hp[battler] = total_damage[2]
      target.recover_sp[battler] = total_damage[3]
      target.state_p[battler] = total_damage[4]
      target.state_m[battler] = total_damage[5]
      # 데미지 표시 플래그를 ON
      target.damage_pop[battler] = true
      # 실제로 데미지를 준다
      target.damage_effect(battler , battler.current_action.kind)
      # 불필요한 해시를 삭제
      target.recover_hp.delete(battler)
      target.recover_sp.delete(battler)
      target.state_p.delete(battler)
      target.state_m.delete(battler)
      # 데미지를 모두 주고 잘랐을 경우
      if target.total_damage[battler]. empty?
        # 타겟에의 전 데미지를 삭제
        target.total_damage.delete(battler)
        # 지정 시간 웨이트 한다
        battler.wait = @damage_wait
      else
        # 지정 시간 웨이트 한다
        next_step = false
        battler.wait = 2 * target.total_damage[battler][0][6]
      end
      # 스테이터스 윈도우를 리프레쉬
      status_refresh(target)
    end
    if next_step
      # 스텝 6 에 이행
      battler.phase = 6
    end
  end
  #--------------------------------------------------------------------------
  # ● 프레임 갱신 (메인 국면 스텝 6 : 리프레쉬)
  #--------------------------------------------------------------------------
  def update_phase4_step6(battler)
    # 카메라를 되돌린다
    if battler.target[0]. is_a? (Game_Enemy) and @camera == battler
      @spriteset.screen_target(0, 0, 1)
    end
    # 스킬 러닝
    if battler.target[0]. is_a? (Game_Actor) and battler.current_action.kind == 1
      for target in battler.target
        skill_learning(target , target.class_id ,
                        battler.current_action.skill_id)
      end
    end
    # 액션 강제 대상의 버틀러를 클리어
    if battler.current_action.forcing == true and
        battler.current_action.force_kind == 0 and
        battler.current_action.force_basic == 0 and
        battler.current_action.force_skill_id == 0
      $game_temp.forcing_battler = nil
      battler.current_action.forcing = false
    end
    refresh_phase(battler)
    speller = synthe? (battler)
    if speller ! = nil
      for spell in speller
        if spell ! = battler
          refresh_phase(spell)
        end
      end
      synthe_delete(speller)
    end
    # 코먼 이벤트 ID 가 유효의 경우
    if battler.event > 0
      # 이벤트를 셋업
      common_event = $data_common_events[battler.event]
      $game_system.battle_interpreter.setup(common_event.list , 0)
    end
    act = 0
    for actor in $game_party.actors + $game_troop.enemies
      if actor.movable?
        act += 1
      end
    end
    if @turn_cnt >= act and act > 0
      @turn_cnt %= act
      $game_temp.battle_turn += 1
      # 배틀 이벤트의 전 페이지를 검색
      for index in 0...$data_troops[@troop_id]. pages.size
        # 이벤트 페이지를 취득
        page = $data_troops[@troop_id]. pages[index]
        # 이 페이지의 스팬이 [턴] 의 경우
        if page.span == 1
          # 실행이 끝난 플래그를 클리어
          $game_temp.battle_event_flags[index] = false
        end
      end
    end
    battler.phase = 1
    @action_battlers.delete(battler)
  end
end
#==============================================================================
# ■ Game_Battler (분할 정의 1)
#------------------------------------------------------------------------------
#  버틀러를 취급하는 클래스입니다. 이 클래스는 Game_Actor 클래스와 Game_Enemy 곳간
# 스의 슈퍼 클래스로서 사용됩니다.
#==============================================================================

class Game_Battler
  #--------------------------------------------------------------------------
  # ● 공개 인스턴스 변수 추가
  #--------------------------------------------------------------------------
  attr_accessor :total_damage              # 총 데미지
  #--------------------------------------------------------------------------
  # ● 오브젝트 초기화
  #--------------------------------------------------------------------------
  alias :initialize_straight :initialize
  def initialize
    initialize_straight
    @total_damage = {}
  end
  #--------------------------------------------------------------------------
  # ● 존재 판정
  #--------------------------------------------------------------------------
  def exist?
    return (not @hidden and (@hp > 0 or @immortal or not @total_damage.empty? ) )
  end
  #--------------------------------------------------------------------------
  # ● 잔 HP 예측
  #--------------------------------------------------------------------------
  def rest_hp
    # rest_hp 에 현HP를 대입
    rest_hp = @hp
    # 버틀러가 받는 전 데미지를 rest _hp에 반영시킨다
    for total in @total_damage
      for pre_damage in total[1]
        if pre_damage[0]. is_a? (Numeric)
          rest_hp -= pre_damage[0]
        end
        if pre_damage[2]. is_a? (Numeric)
          rest_hp += pre_damage[2]
        end
      end
    end
    return rest_hp
  end
end

#==============================================================================
# ■ Game_Actor
#------------------------------------------------------------------------------
#  엑터를 취급하는 클래스입니다. 이 클래스는 Game_Actors 클래스 ($game_actors)
# 의 내부에서 사용되어 Game_Party 클래스 ($game_party) 로부터도 참조됩니다.
#==============================================================================

class Game_Actor < Game_Battler
  #--------------------------------------------------------------------------
  # ● 공개 인스턴스 변수
  #--------------------------------------------------------------------------
  def change_weapon(id)
    @weapon_id = id
  end
end

#==============================================================================
# ■ Sprite_Battler
#------------------------------------------------------------------------------
#  버틀러 표시용의 스프라이트입니다. Game_Battler 클래스의 인스턴스를 감시해 ,
# 스프라이트 상태를 자동적으로 변화시킵니다.
#==============================================================================

class Sprite_Battler < RPG::Sprite
  #--------------------------------------------------------------------------
  # ● 프레임 갱신
  #--------------------------------------------------------------------------
  def update
    super
    # 버틀러가 nil 의 경우
    if @battler == nil
      self.bitmap = nil
      loop_animation(nil)
      return
    end
    # 파일명이나 색상이 현재의 것과 다른 경우
    if @battler.battler_name ! = @battler_name or
       @battler.battler_hue ! = @battler_hue
      # 비트 맵을 취득 , 설정
      @battler_name = @battler.battler_name
      @battler_hue = @battler.battler_hue
      self.bitmap = RPG::Cache.battler(@battler_name , @battler_hue)
      @width = bitmap.width
      @height = bitmap.height
      self.ox = @width / 2
      self.oy = @height
      if @battler.is_a? (Game_Enemy)
        @battler.height = @height
      end
      # 전투 불능 또는 숨고 상태라면 불투명도를 0 으로 한다
      if @battler.dead?  or @battler.hidden
        self.opacity = 0
      end
    end
    # 애니메이션 ID 가 현재의 것과 다른 경우
    if @battler.state_animation_id ! = @state_animation_id
      @state_animation_id = @battler.state_animation_id
      loop_animation($data_animations[@state_animation_id])
    end
    # 표시되어야 할 엑터의 경우
    if @battler.is_a? (Game_Actor) and @battler_visible
      # 메인 국면이 아닐 때는 불투명도를 약간 내린다
      if $game_temp.battle_main_phase
        self.opacity += 3 if self.opacity < 255
      else
        self.opacity -= 3 if self.opacity > 207
      end
    end
    # 명 멸망
    if @battler.blink
      blink_on
    else
      blink_off
    end
    # 불가시의 경우
    unless @battler_visible
      # 출현
      if not @battler.hidden and not @battler.dead?  and
         (@battler.damage.size < 2 or @battler.damage_pop.size < 2)
        appear
        @battler_visible = true
      end
    end
    # 데미지
    for battler in @battler.damage_pop
      if battler[0]. class == Array
        if battler[0][1] >= 0
          $scene.skill_se
        else
          $scene.levelup_se
        end
        damage(@battler.damage[battler[0]], false , 2)
      else
        damage(@battler.damage[battler[0]], @battler.critical[battler[0]])
      end
      if @battler.damage_sp.include? (battler[0])
        damage(@battler.damage_sp[battler[0]],
                @battler.critical[battler[0]], 1)
        @battler.damage_sp.delete(battler[0])
      end
      @battler.damage_pop.delete(battler[0])
      @battler.damage.delete(battler[0])
      @battler.critical.delete(battler[0])
    end
    # 가시의 경우
    if @battler_visible
      # 도주
      if @battler.hidden
        $game_system.se_play($data_system.escape_se)
        escape
        @battler_visible = false
      end
      # 흰색 플래시
      if @battler.white_flash
        whiten
        @battler.white_flash = false
      end
      # 애니메이션
      unless @battler.animation.empty?
        for animation in @battler.animation.reverse
          animation($data_animations[animation[0]], animation[1])
          @battler.animation.delete(animation)
        end
      end
      # 코라프스
      if @battler.total_damage.empty?  and @battler.dead?
        if $scene.dead_ok? (@battler)
          if @battler.is_a? (Game_Enemy)
            $game_system.se_play($data_system.enemy_collapse_se)
          else
            $game_system.se_play($data_system.actor_collapse_se)
          end
          collapse
          @battler_visible = false
        end
      end
    end
    # 스프라이트의 좌표를 설정
    self.x = @battler.screen_x
    self.y = @battler.screen_y
    self.z = @battler.screen_z
    if @battler.is_a? (Game_Enemy)
      self.zoom_x = @battler.real_zoom * @battler.zoom
      self.zoom_y = @battler.real_zoom * @battler.zoom
    end
  end
end


이게 스크립트인데.. 보니까 3개로 나눠져 있는 것 같애요..

스크립트 많이 사용해보지도 않았는데.. 이거.. 어떻게 사용하나요 ;ㅁ;....?

메인 위에 삽입해서 사용하나요?
?

List of Articles
번호 제목 글쓴이 날짜 조회 수
8827 쯔꾸르 mv 게임을 apk 파일로 변환했는데... 1 박하맛 2023.01.14 1332
8826 쯔꾸르 젖소이야기 결혼 방법좀 알려주세요... 2 백지씨 2021.12.20 2627
8825 apk포팅 승인 어케 하나요? game메이커xp 2021.11.29 1258
8824 Yanfly님의 Action Sequence Pack 질문드립니다 Neuromancer 2021.07.15 1542
8823 싸게 MV 를 먼저? 아니면 돈을 더 들어서라도 MZ? 2 Xatra 2021.07.06 1753
8822 RMMV - 스탯창과 대화창 변견 관련 질문입니다. (초보입니다 도움좀 주세요 ㅜㅜ) 2 scribble 2021.01.22 1553
8821 아오오니를 하는 사람인데요 질문 두가지가 있어요 1 오니개무서워 2021.01.16 1635
8820 재밌는게임 land_tnt 2020.12.07 1455
8819 c언어 질문 세종기항19 2020.11.10 1685
8818 코딩 질문 1 세종기항19 2020.11.08 1541
8817 혹시나 물어보는데 드래곤규 2020.11.07 1402
8816 오픈보 게임 더블드래곤 리로디드 얼티네이트에 대해 궁금 이부닝 2020.09.09 1224
8815 상태이상 확률 결정 스트레이보우 2020.09.02 1007
8814 다음 인디사이드 제작대회는 언제쯤 열릴까요? WOONAALAA 2020.05.23 963
8813 xp로 제작된 어플 실행자체가 안된다는 분이 있습니다.(제생각엔 apk로 변환하는 과정에서 버전자체가 낮은 것 같습니다) 1 라엔 2020.05.04 1416
8812 apk 포팅하는데 게임 이름이 필요합니다 뜨는데 1 kashu 2020.05.03 1350
8811 쯔꾸르VX Ace렉먹음 도와주세요... 랖랖 2020.03.22 1780
8810 안녕하세요 1 청월령 2020.02.14 834
8809 포팅 중 '게임 이름이 필요합니다' 오류 2 아이비스 2020.02.11 817
8808 RPGMV 거리 추적 1 정욱 2020.01.19 932
Board Pagination Prev 1 2 3 4 5 6 7 8 9 10 ... 442 Next
/ 442


[개인정보취급방침] | [이용약관] | [제휴문의] | [후원창구] | [인디사이드연혁]

Copyright © 1999 - 2016 INdiSide.com/(주)씨엘쓰리디 All Rights Reserved.
인디사이드 운영자 : 천무(이지선) | kernys(김원배) | 사신지(김병국)