XP 스크립트

설정해둔 전투음악 중 임의의 곡을 전투시 연주하는 스크립트입니다.  전투음악은 스크립트에서 미리 설정해 둘 수도 있고 이벤트 명령->스크립트에서 추가하거나 삭제할 수 있습니다.


class Game_Party
  attr_accessor  :music
  alias pre_music_initialize initialize
  def initialize
    pre_music_initialize
    @music = []
  end
end

class Scene_Map
  def call_battle
    # Clear battle calling flag
    $game_temp.battle_calling = false
    # Clear menu calling flag
    $game_temp.menu_calling = false
    $game_temp.menu_beep = false
    # Make encounter count
    $game_player.make_encounter_count
    # Memorize map BGM and stop BGM
    $game_temp.map_bgm = $game_system.playing_bgm
    $game_system.bgm_stop
    # Play battle start SE
    $game_system.se_play($data_system.battle_start_se)
    # Play battle BGM
    file = $game_party.music[rand($game_party.music.size)]
    audio_file = RPG::AudioFile.new(file)
    $game_system.bgm_play(audio_file)
    # Straighten player position
    $game_player.straighten
    # Switch to battle screen
    $scene = Scene_Battle.new
  end
end


전투음악 기본설정은
@music = [파일명1, 파일명2, ......파일명n]
으로 할 수 있고, 게임 중에서 추가/삭제하는 것은:
$game_party.music.push("MusicName") <- 사용할 전투음악 추가 (확장자 생략)
$game_party.music.delete("MusicName") <- 전투음악 삭제 (확장자 생략)

Who's 백호

?

이상혁입니다.

http://elab.kr


List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
공지 스크립트 자료 게시물 작성시 주의사항 습작 2012.12.24 6153
74 전투 Stealing/Mugging/Scanning 6.0 Final by Trickster (SDK호환) file 백호 2009.02.22 885
73 전투 SG_Attack Break by sandgolem (SDK호환) 백호 2009.02.22 813
72 전투 [신기술 체험]액션배틀1탄 6 file 백호 2009.02.22 2766
» 전투 랜덤 전투음악 by Fomar0153@rmxp.org 1 백호 2009.02.22 1008
70 전투 중복일지도 모르는 ATB 전투 11 file 백호 2009.02.22 4057
69 전투 Active Time Battle 2.57 by パラ犬 6 file 백호 2009.02.22 2371
68 전투 [신기술 체험] Tactical Battle System 9 file 백호 2009.02.22 2034
67 전투 Battle Report 1.6 by Raziel@rmxp.org 1 file 백호 2009.02.22 1672
66 전투 Prize Point System 2.0 by Dark Ruby@rmxp.org 3 file 백호 2009.02.22 1742
65 전투 매턴 자동 회복이나 도트힐 3 file 백호 2009.02.22 1351
64 전투 S.G DamageShield Script 백호 2009.02.22 935
63 전투 방어시에 속성 저항,스테이트무시 스크립트 1 백호 2009.02.22 1017
62 전투 적의 여러차례 행동 스크립트 1 백호 2009.02.22 1321
61 전투 KGC_Active Count Battle (7/30일자) 7 file 백호 2009.02.22 1846
60 전투 SG_Batte Retry ver.4 by sandgolem 2 백호 2009.02.22 1457
59 전투 [신기술 체험] SRPG-Test 13 file 백호 2009.02.22 3537
58 전투 KGC_SeparationCommand file 백호 2009.02.22 1708
57 전투 KGC_BonusGauge (보너스게이지) 3 file 백호 2009.02.22 2762
56 전투 KGC_SPdeath (SP전투불능) file 백호 2009.02.22 1527
55 전투 KGC_SPdamage (SP데미지) 3 file 백호 2009.02.22 1628
Board Pagination Prev 1 2 3 4 5 6 7 8 9 Next
/ 9