Jump to content
New account registrations are disabed. This website is now an archive. Read more here.
Nisage

[Solved] Forest of Silence Scrpit

Recommended Posts

In the Anime called Magic Knight Rayearth, there is a forest that makes everyone unable to cast any kind of magic, or skills. When they made the Magic Knight Rayearth game, they made the Forest of Silence based like the one in the Anime, but you can't access your items at all. Can't access the item window in a battle, or after a battle (there were places to heal luckly). I'm hoping someone can make a "Forest of Silence" scrpit, please. Thank you.

Share this post


Link to post
Share on other sites

Yay, thank you. Also, while I remember this..... For those that have played my ROA game before, sorry it's taking so long to add the newest version of it to Unlimited :( I'm hoping to add the newest version soon, I just need to make a few more adjustments here and there.

Share this post


Link to post
Share on other sites

Alright Nisage its all finished

It seems like the spoiler didnt work but there's 2 scripts you have to replace.

 

Replace Scene_Battle with this

[spoiler=Scene_Battle]

#==============================================================================
# ■ Scene_Battle
#------------------------------------------------------------------------------
#  バトル画面の処理を行うクラスです。
#==============================================================================

class Scene_Battle < Scene_Base
 #--------------------------------------------------------------------------
 # ● 開始処理
 #--------------------------------------------------------------------------
 def start
super
$game_temp.in_battle = true
@spriteset = Spriteset_Battle.new
@message_window = Window_BattleMessage.new
@action_battlers = []
create_info_viewport
 end
 #--------------------------------------------------------------------------
 # ● 開始後処理
 #--------------------------------------------------------------------------
 def post_start
super
process_battle_start
 end
 #--------------------------------------------------------------------------
 # ● 終了処理
 #--------------------------------------------------------------------------
 def terminate
super
dispose_info_viewport
@message_window.dispose
@spriteset.dispose
unless $scene.is_a?(Scene_Gameover)
  $scene = nil if $BTEST
end
 end
 #--------------------------------------------------------------------------
 # ● 基本更新処理
 #	 main : メインの update メソッドからの呼び出し
 #--------------------------------------------------------------------------
 def update_basic(main = false)
Graphics.update unless main	 # ゲーム画面を更新
Input.update unless main		# 入力情報を更新
$game_system.update			 # タイマーを更新
$game_troop.update			  # 敵グループを更新
@spriteset.update			   # スプライトセットを更新
@message_window.update		  # メッセージウィンドウを更新
 end
 #--------------------------------------------------------------------------
 # ● 一定時間ウェイト
 #	 duration : ウェイト時間 (フレーム数)
 #	 no_fast  : 早送り無効
 #	シーンクラスの update 処理の中でウェイトをかけるためのメソッド。
 #	update は 1 フレームに 1 回呼ばれるのが原則だが、戦闘中は処理の流れを
 #	把握しにくくなるため、例外的にこのメソッドを使用する。
 #--------------------------------------------------------------------------
 def wait(duration, no_fast = false)
for i in 0...duration
  update_basic
  break if not no_fast and i >= duration / 2 and show_fast?
end
 end
 #--------------------------------------------------------------------------
 # ● メッセージ表示が終わるまでウェイト
 #--------------------------------------------------------------------------
 def wait_for_message
@message_window.update
while $game_message.visible
  update_basic
end
 end
 #--------------------------------------------------------------------------
 # ● アニメーション表示が終わるまでウェイト
 #--------------------------------------------------------------------------
 def wait_for_animation
while @spriteset.animation?
  update_basic
end
 end
 #--------------------------------------------------------------------------
 # ● 早送り判定
 #--------------------------------------------------------------------------
 def show_fast?
return (Input.press?(Input::A) or Input.press?(Input::C))
 end
 #--------------------------------------------------------------------------
 # ● フレーム更新
 #--------------------------------------------------------------------------
 def update
super
update_basic(true)
update_info_viewport				  # 情報表示ビューポートを更新
if $game_message.visible
  @info_viewport.visible = false
  @message_window.visible = true
end
unless $game_message.visible		  # メッセージ表示中以外
  return if judge_win_loss			# 勝敗判定
  update_scene_change
  if @target_enemy_window != nil
	update_target_enemy_selection	 # 対象敵キャラ選択
  elsif @target_actor_window != nil
	update_target_actor_selection	 # 対象アクター選択
  elsif @skill_window != nil
	update_skill_selection			# スキル選択
  elsif @item_window != nil
	update_item_selection			 # アイテム選択
  elsif @party_command_window.active
	update_party_command_selection	# パーティコマンド選択
  elsif @actor_command_window.active
	update_actor_command_selection	# アクターコマンド選択
  else
	process_battle_event			  # バトルイベントの処理
	process_action					# 戦闘行動
	process_battle_event			  # バトルイベントの処理
  end
end
 end
 #--------------------------------------------------------------------------
 # ● 情報表示ビューポートの作成
 #--------------------------------------------------------------------------
 def create_info_viewport
@info_viewport = Viewport.new(0, 288, 544, 128)
@info_viewport.z = 100
@status_window = Window_BattleStatus.new
@party_command_window = Window_PartyCommand.new
@actor_command_window = Window_ActorCommand.new
@status_window.viewport = @info_viewport
@party_command_window.viewport = @info_viewport
@actor_command_window.viewport = @info_viewport
@status_window.x = 128
@actor_command_window.x = 544
@info_viewport.visible = false
 end
 #--------------------------------------------------------------------------
 # ● 情報表示ビューポートの解放
 #--------------------------------------------------------------------------
 def dispose_info_viewport
@status_window.dispose
@party_command_window.dispose
@actor_command_window.dispose
@info_viewport.dispose
 end
 #--------------------------------------------------------------------------
 # ● 情報表示ビューポートの更新
 #--------------------------------------------------------------------------
 def update_info_viewport
@party_command_window.update
@actor_command_window.update
@status_window.update
if @party_command_window.active and @info_viewport.ox > 0
  @info_viewport.ox -= 16
elsif @actor_command_window.active and @info_viewport.ox < 128
  @info_viewport.ox += 16
end
 end
 #--------------------------------------------------------------------------
 # ● バトルイベントの処理
 #--------------------------------------------------------------------------
 def process_battle_event
loop do
  return if judge_win_loss
  return if $game_temp.next_scene != nil
  $game_troop.interpreter.update
  $game_troop.setup_battle_event
  wait_for_message
  process_action if $game_troop.forcing_battler != nil
  return unless $game_troop.interpreter.running?
  update_basic
end
 end
 #--------------------------------------------------------------------------
 # ● 勝敗判定
 #--------------------------------------------------------------------------
 def judge_win_loss
if $game_temp.in_battle
  if $game_party.all_dead?
	process_defeat
	return true
  elsif $game_troop.all_dead?
	process_victory
	return true
  else
	return false
  end
else
  return true
end
 end
 #--------------------------------------------------------------------------
 # ● 戦闘終了
 #	 result : 結果 (0:勝利 1:逃走 2:敗北)
 #--------------------------------------------------------------------------
 def battle_end(result)
if result == 2 and not $game_troop.can_lose
  call_gameover
else
  $game_party.clear_actions
  $game_party.remove_states_battle
  $game_troop.clear
  if $game_temp.battle_proc != nil
	$game_temp.battle_proc.call(result)
	$game_temp.battle_proc = nil
  end
  unless $BTEST
	$game_temp.map_bgm.play
	$game_temp.map_bgs.play
  end
  $scene = Scene_Map.new
  @message_window.clear
  Graphics.fadeout(30)
end
$game_temp.in_battle = false
 end
 #--------------------------------------------------------------------------
 # ● 次のアクターのコマンド入力へ
 #--------------------------------------------------------------------------
 def next_actor
loop do
  if @actor_index == $game_party.members.size-1
	start_main
	return
  end
  @status_window.index = @actor_index += 1
  @active_battler = $game_party.members[@actor_index]
  if @active_battler.auto_battle
	@active_battler.make_action
	next
  end
  break if @active_battler.inputable?
end
start_actor_command_selection
 end
 #--------------------------------------------------------------------------
 # ● 前のアクターのコマンド入力へ
 #--------------------------------------------------------------------------
 def prior_actor
loop do
  if @actor_index == 0
	start_party_command_selection
	return
  end
  @status_window.index = @actor_index -= 1
  @active_battler = $game_party.members[@actor_index]
  next if @active_battler.auto_battle
  break if @active_battler.inputable?
end
start_actor_command_selection
 end
 #--------------------------------------------------------------------------
 # ● パーティコマンド選択の開始
 #--------------------------------------------------------------------------
 def start_party_command_selection
if $game_temp.in_battle
  @status_window.refresh
  @status_window.index = @actor_index = -1
  @active_battler = nil
  @info_viewport.visible = true
  @message_window.visible = false
  @party_command_window.active = true
  @party_command_window.index = 0
  @actor_command_window.active = false
  $game_party.clear_actions
  if $game_troop.surprise or not $game_party.inputable?
	start_main
  end
end
 end
 #--------------------------------------------------------------------------
 # ● パーティコマンド選択の更新
 #--------------------------------------------------------------------------
 def update_party_command_selection
if Input.trigger?(Input::C)
  case @party_command_window.index
  when 0  # 戦う
	Sound.play_decision
	@status_window.index = @actor_index = -1
	next_actor
  when 1  # 逃げる
	if $game_troop.can_escape == false
	  Sound.play_buzzer
	  return
	end
	Sound.play_decision
	process_escape
  end
end
 end
 #--------------------------------------------------------------------------
 # ● アクターコマンド選択の開始
 #--------------------------------------------------------------------------
 def start_actor_command_selection
@party_command_window.active = false
@actor_command_window.setup(@active_battler)
@actor_command_window.active = true
@actor_command_window.index = 0
 end
 #--------------------------------------------------------------------------
 # ● アクターコマンド選択の更新
 #--------------------------------------------------------------------------
 def update_actor_command_selection
if Input.trigger?(Input::B)
  Sound.play_cancel
  prior_actor
elsif Input.trigger?(Input::C)
  case @actor_command_window.index
  when 0  # 攻撃
	Sound.play_decision
	@active_battler.action.set_attack
	start_target_enemy_selection
  when 1  # スキル
	if $game_switches[$forest] == true
	  Sound.play_buzzer
	  else
	Sound.play_decision
	start_skill_selection
	end
  when 2  # 防御
	Sound.play_decision
	@active_battler.action.set_guard
	next_actor
  when 3  # アイテム
	if $game_switches[$forest] == true
	  Sound.play_buzzer
	  else
	Sound.play_decision
	start_item_selection
	end
  end
end
 end
 #--------------------------------------------------------------------------
 # ● 対象敵キャラ選択の開始
 #--------------------------------------------------------------------------
 def start_target_enemy_selection
@target_enemy_window = Window_TargetEnemy.new
@target_enemy_window.y = @info_viewport.rect.y
@info_viewport.rect.x += @target_enemy_window.width
@info_viewport.ox += @target_enemy_window.width
@actor_command_window.active = false
 end
 #--------------------------------------------------------------------------
 # ● 対象敵キャラ選択の終了
 #--------------------------------------------------------------------------
 def end_target_enemy_selection
@info_viewport.rect.x -= @target_enemy_window.width
@info_viewport.ox -= @target_enemy_window.width
@target_enemy_window.dispose
@target_enemy_window = nil
if @actor_command_window.index == 0
  @actor_command_window.active = true
end
 end
 #--------------------------------------------------------------------------
 # ● 対象敵キャラ選択の更新
 #--------------------------------------------------------------------------
 def update_target_enemy_selection
@target_enemy_window.update
if Input.trigger?(Input::B)
  Sound.play_cancel
  end_target_enemy_selection
elsif Input.trigger?(Input::C)
  Sound.play_decision
  @active_battler.action.target_index = @target_enemy_window.enemy.index
  end_target_enemy_selection
  end_skill_selection
  end_item_selection
  next_actor
end
 end
 #--------------------------------------------------------------------------
 # ● 対象アクター対象選択の開始
 #--------------------------------------------------------------------------
 def start_target_actor_selection
@target_actor_window = Window_BattleStatus.new
@target_actor_window.index = 0
@target_actor_window.active = true
@target_actor_window.y = @info_viewport.rect.y
@info_viewport.rect.x += @target_actor_window.width
@info_viewport.ox += @target_actor_window.width
@actor_command_window.active = false
 end
 #--------------------------------------------------------------------------
 # ● 対象アクター選択の終了
 #--------------------------------------------------------------------------
 def end_target_actor_selection
@info_viewport.rect.x -= @target_actor_window.width
@info_viewport.ox -= @target_actor_window.width
@target_actor_window.dispose
@target_actor_window = nil
 end
 #--------------------------------------------------------------------------
 # ● 対象アクター選択の更新
 #--------------------------------------------------------------------------
 def update_target_actor_selection
@target_actor_window.update
if Input.trigger?(Input::B)
  Sound.play_cancel
  end_target_actor_selection
elsif Input.trigger?(Input::C)
  Sound.play_decision
  @active_battler.action.target_index = @target_actor_window.index
  end_target_actor_selection
  end_skill_selection
  end_item_selection
  next_actor
end
 end
 #--------------------------------------------------------------------------
 # ● スキル選択の開始
 #--------------------------------------------------------------------------
 def start_skill_selection
@help_window = Window_Help.new
@skill_window = Window_Skill.new(0, 56, 544, 232, @active_battler)
@skill_window.help_window = @help_window
@actor_command_window.active = false
 end
 #--------------------------------------------------------------------------
 # ● スキル選択の終了
 #--------------------------------------------------------------------------
 def end_skill_selection
if @skill_window != nil
  @skill_window.dispose
  @skill_window = nil
  @help_window.dispose
  @help_window = nil
end
@actor_command_window.active = true
 end
 #--------------------------------------------------------------------------
 # ● スキル選択の更新
 #--------------------------------------------------------------------------
 def update_skill_selection
@skill_window.active = true
@skill_window.update
@help_window.update
if Input.trigger?(Input::B)
  Sound.play_cancel
  end_skill_selection
elsif Input.trigger?(Input::C)
  @skill = @skill_window.skill
  if @skill != nil
	@active_battler.last_skill_id = @skill.id
  end
  if @active_battler.skill_can_use?(@skill)
	Sound.play_decision
	determine_skill
  else
	Sound.play_buzzer
  end
end
 end
 #--------------------------------------------------------------------------
 # ● スキルの決定
 #--------------------------------------------------------------------------
 def determine_skill
@active_battler.action.set_skill(@skill.id)
@skill_window.active = false
if @skill.need_selection?
  if @skill.for_opponent?
	start_target_enemy_selection
  else
	start_target_actor_selection
  end
else
  end_skill_selection
  next_actor
end
 end
 #--------------------------------------------------------------------------
 # ● アイテム選択の開始
 #--------------------------------------------------------------------------
 def start_item_selection
@help_window = Window_Help.new
@item_window = Window_Item.new(0, 56, 544, 232)
@item_window.help_window = @help_window
@actor_command_window.active = false
 end
 #--------------------------------------------------------------------------
 # ● アイテム選択の終了
 #--------------------------------------------------------------------------
 def end_item_selection
if @item_window != nil
  @item_window.dispose
  @item_window = nil
  @help_window.dispose
  @help_window = nil
end
@actor_command_window.active = true
 end
 #--------------------------------------------------------------------------
 # ● アイテム選択の更新
 #--------------------------------------------------------------------------
 def update_item_selection
@item_window.active = true
@item_window.update
@help_window.update
if Input.trigger?(Input::B)
  Sound.play_cancel
  end_item_selection
elsif Input.trigger?(Input::C)
  @item = @item_window.item
  if @item != nil
	$game_party.last_item_id = @item.id
  end
  if $game_party.item_can_use?(@item)
	Sound.play_decision
	determine_item
  else
	Sound.play_buzzer
  end
end
 end
 #--------------------------------------------------------------------------
 # ● アイテムの決定
 #--------------------------------------------------------------------------
 def determine_item
@active_battler.action.set_item(@item.id)
@item_window.active = false
if @item.need_selection?
  if @item.for_opponent?
	start_target_enemy_selection
  else
	start_target_actor_selection
  end
else
  end_item_selection
  next_actor
end
 end
 #--------------------------------------------------------------------------
 # ● 戦闘開始の処理
 #--------------------------------------------------------------------------
 def process_battle_start
@message_window.clear
wait(10)
for name in $game_troop.enemy_names
  text = sprintf(Vocab::Emerge, name)
  $game_message.texts.push(text)
end
if $game_troop.preemptive
  text = sprintf(Vocab::Preemptive, $game_party.name)
  $game_message.texts.push(text)
elsif $game_troop.surprise
  text = sprintf(Vocab::Surprise, $game_party.name)
  $game_message.texts.push(text)
end
wait_for_message
@message_window.clear
make_escape_ratio
process_battle_event
start_party_command_selection
 end
 #--------------------------------------------------------------------------
 # ● 逃走成功率の作成
 #--------------------------------------------------------------------------
 def make_escape_ratio
actors_agi = $game_party.average_agi
enemies_agi = $game_troop.average_agi
@escape_ratio = 150 - 100 * enemies_agi / actors_agi
 end
 #--------------------------------------------------------------------------
 # ● 逃走の処理
 #--------------------------------------------------------------------------
 def process_escape
@info_viewport.visible = false
@message_window.visible = true
text = sprintf(Vocab::EscapeStart, $game_party.name)
$game_message.texts.push(text)
if $game_troop.preemptive
  success = true
else
  success = (rand(100) < @escape_ratio)
end
Sound.play_escape
if success
  wait_for_message
  battle_end(1)
else
  @escape_ratio += 10
  $game_message.texts.push('\.' + Vocab::EscapeFailure)
  wait_for_message
  $game_party.clear_actions
  start_main
end
 end
 #--------------------------------------------------------------------------
 # ● 勝利の処理
 #--------------------------------------------------------------------------
 def process_victory
@info_viewport.visible = false
@message_window.visible = true
RPG::BGM.stop
$game_system.battle_end_me.play
unless $BTEST
  $game_temp.map_bgm.play
  $game_temp.map_bgs.play
end
display_exp_and_gold
display_drop_items
display_level_up
battle_end(0)
 end
 #--------------------------------------------------------------------------
 # ● 獲得した経験値とお金の表示
 #--------------------------------------------------------------------------
 def display_exp_and_gold
exp = $game_troop.exp_total
gold = $game_troop.gold_total
$game_party.gain_gold(gold)
text = sprintf(Vocab::Victory, $game_party.name)
$game_message.texts.push('\|\|' + text)
if exp > 0
  text = sprintf(Vocab::ObtainExp, exp)
  $game_message.texts.push('\|' + text)
end
if gold > 0
  text = sprintf(Vocab::ObtainGold, gold, Vocab::gold)
  $game_message.texts.push('\.' + text)
end
wait_for_message
 end
 #--------------------------------------------------------------------------
 # ● 獲得したドロップアイテムの表示
 #--------------------------------------------------------------------------
 def display_drop_items
drop_items = $game_troop.make_drop_items
for item in drop_items
  $game_party.gain_item(item, 1)
  text = sprintf(Vocab::ObtainItem, item.name)
  $game_message.texts.push(text)
end
wait_for_message
 end
 #--------------------------------------------------------------------------
 # ● レベルアップの表示
 #--------------------------------------------------------------------------
 def display_level_up
exp = $game_troop.exp_total
for actor in $game_party.existing_members
  last_level = actor.level
  last_skills = actor.skills
  actor.gain_exp(exp, true)
end
wait_for_message
 end
 #--------------------------------------------------------------------------
 # ● 敗北の処理
 #--------------------------------------------------------------------------
 def process_defeat
@info_viewport.visible = false
@message_window.visible = true
text = sprintf(Vocab::Defeat, $game_party.name)
$game_message.texts.push(text)
wait_for_message
battle_end(2)
 end
 #--------------------------------------------------------------------------
 # ● 画面切り替えの実行
 #--------------------------------------------------------------------------
 def update_scene_change
case $game_temp.next_scene
when "map"
  call_map
when "gameover"
  call_gameover
when "title"
  call_title
else
  $game_temp.next_scene = nil
end
 end
 #--------------------------------------------------------------------------
 # ● マップ画面への切り替え
 #--------------------------------------------------------------------------
 def call_map
$game_temp.next_scene = nil
battle_end(1)
 end
 #--------------------------------------------------------------------------
 # ● ゲームオーバー画面への切り替え
 #--------------------------------------------------------------------------
 def call_gameover
$game_temp.next_scene = nil
$scene = Scene_Gameover.new
@message_window.clear
 end
 #--------------------------------------------------------------------------
 # ● タイトル画面への切り替え
 #--------------------------------------------------------------------------
 def call_title
$game_temp.next_scene = nil
$scene = Scene_Title.new
@message_window.clear
Graphics.fadeout(60)
 end
 #--------------------------------------------------------------------------
 # ● 戦闘処理の実行開始
 #--------------------------------------------------------------------------
 def start_main
$game_troop.increase_turn
@info_viewport.visible = false
@info_viewport.ox = 0
@message_window.visible = true
@party_command_window.active = false
@actor_command_window.active = false
@status_window.index = @actor_index = -1
@active_battler = nil
@message_window.clear
$game_troop.make_actions
make_action_orders
wait(20)
 end
 #--------------------------------------------------------------------------
 # ● 行動順序作成
 #--------------------------------------------------------------------------
 def make_action_orders
@action_battlers = []
unless $game_troop.surprise
  @action_battlers += $game_party.members
end
unless $game_troop.preemptive
  @action_battlers += $game_troop.members
end
for battler in @action_battlers
  battler.action.make_speed
end
@action_battlers.sort! do |a,b|
  b.action.speed - a.action.speed
end
 end
 #--------------------------------------------------------------------------
 # ● 戦闘行動の処理
 #--------------------------------------------------------------------------
 def process_action
return if judge_win_loss
return if $game_temp.next_scene != nil
set_next_active_battler
if @active_battler == nil
  turn_end
  return
end
return if @active_battler.dead?
@message_window.clear
wait(5)
@active_battler.white_flash = true
unless @active_battler.action.forcing
  @active_battler.action.prepare
end
if @active_battler.action.valid?
  execute_action
end
unless @active_battler.action.forcing
  @message_window.clear
  remove_states_auto
  display_current_state
end
@active_battler.white_flash = false
@message_window.clear
 end
 #--------------------------------------------------------------------------
 # ● 戦闘行動の実行
 #--------------------------------------------------------------------------
 def execute_action
case @active_battler.action.kind
when 0  # 基本
  case @active_battler.action.basic
  when 0  # 攻撃
	execute_action_attack
  when 1  # 防御
	execute_action_guard
  when 2  # 逃走
	execute_action_escape
  when 3  # 待機
	execute_action_wait
  end
when 1  # スキル
  execute_action_skill
when 2  # アイテム
  execute_action_item
end
 end
 #--------------------------------------------------------------------------
 # ● ターン終了
 #--------------------------------------------------------------------------
 def turn_end
$game_troop.turn_ending = true
$game_party.slip_damage_effect
$game_troop.slip_damage_effect
$game_party.do_auto_recovery
$game_troop.preemptive = false
$game_troop.surprise = false
process_battle_event
$game_troop.turn_ending = false
start_party_command_selection
 end
 #--------------------------------------------------------------------------
 # ● 次に行動するべきバトラーの設定
 #	イベントコマンドで [戦闘行動の強制] が行われているときはそのバトラー
 #	を設定して、リストから削除する。それ以外はリストの先頭から取得する。
 #	現在パーティにいないアクターを取得した場合 (index が nil, バトルイベ
 #	ントでの離脱直後などに発生) は、それをスキップする。
 #--------------------------------------------------------------------------
 def set_next_active_battler
loop do
  if $game_troop.forcing_battler != nil
	@active_battler = $game_troop.forcing_battler
	@action_battlers.delete(@active_battler)
	$game_troop.forcing_battler = nil
  else
	@active_battler = @action_battlers.shift
  end
  return if @active_battler == nil
  return if @active_battler.index != nil
end
 end
 #--------------------------------------------------------------------------
 # ● ステート自然解除
 #--------------------------------------------------------------------------
 def remove_states_auto
last_st = @active_battler.states
@active_battler.remove_states_auto
if @active_battler.states != last_st
  wait(5)
  display_state_changes(@active_battler)
  wait(30)
  @message_window.clear
end
 end
 #--------------------------------------------------------------------------
 # ● 現在のステートの表示
 #--------------------------------------------------------------------------
 def display_current_state
state_text = @active_battler.most_important_state_text
unless state_text.empty?
  wait(5)
  text = @active_battler.name + state_text
  @message_window.add_instant_text(text)
  wait(45)
  @message_window.clear
end
 end
 #--------------------------------------------------------------------------
 # ● 戦闘行動の実行 : 攻撃
 #--------------------------------------------------------------------------
 def execute_action_attack
text = sprintf(Vocab::DoAttack, @active_battler.name)
@message_window.add_instant_text(text)
targets = @active_battler.action.make_targets
display_attack_animation(targets)
wait(20)
for target in targets
  target.attack_effect(@active_battler)
  display_action_effects(target)
end
 end
 #--------------------------------------------------------------------------
 # ● 戦闘行動の実行 : 防御
 #--------------------------------------------------------------------------
 def execute_action_guard
text = sprintf(Vocab::DoGuard, @active_battler.name)
@message_window.add_instant_text(text)
wait(45)
 end
 #--------------------------------------------------------------------------
 # ● 戦闘行動の実行 : 逃走
 #--------------------------------------------------------------------------
 def execute_action_escape
text = sprintf(Vocab::DoEscape, @active_battler.name)
@message_window.add_instant_text(text)
@active_battler.escape
Sound.play_escape
wait(45)
 end
 #--------------------------------------------------------------------------
 # ● 戦闘行動の実行 : 待機
 #--------------------------------------------------------------------------
 def execute_action_wait
text = sprintf(Vocab::DoWait, @active_battler.name)
@message_window.add_instant_text(text)
wait(45)
 end
 #--------------------------------------------------------------------------
 # ● 戦闘行動の実行 : スキル
 #--------------------------------------------------------------------------
 def execute_action_skill
skill = @active_battler.action.skill
text = @active_battler.name + skill.message1
@message_window.add_instant_text(text)
unless skill.message2.empty?
  wait(10)
  @message_window.add_instant_text(skill.message2)
end
targets = @active_battler.action.make_targets
display_animation(targets, skill.animation_id)
@active_battler.mp -= @active_battler.calc_mp_cost(skill)
$game_temp.common_event_id = skill.common_event_id
for target in targets
  target.skill_effect(@active_battler, skill)
  display_action_effects(target, skill)
end
 end
 #--------------------------------------------------------------------------
 # ● 戦闘行動の実行 : アイテム
 #--------------------------------------------------------------------------
 def execute_action_item
item = @active_battler.action.item
text = sprintf(Vocab::UseItem, @active_battler.name, item.name)
@message_window.add_instant_text(text)
targets = @active_battler.action.make_targets
display_animation(targets, item.animation_id)
$game_party.consume_item(item)
$game_temp.common_event_id = item.common_event_id
for target in targets
  target.item_effect(@active_battler, item)
  display_action_effects(target, item)
end
 end
 #--------------------------------------------------------------------------
 # ● アニメーションの表示
 #	 targets	  : 対象者の配列
 #	 animation_id : アニメーション ID (-1: 通常攻撃と同じ)
 #--------------------------------------------------------------------------
 def display_animation(targets, animation_id)
if animation_id < 0
  display_attack_animation(targets)
else
  display_normal_animation(targets, animation_id)
end
wait(20)
wait_for_animation
 end
 #--------------------------------------------------------------------------
 # ● 攻撃アニメーションの表示
 #	 targets : 対象者の配列
 #	敵キャラの場合は [敵の通常攻撃] 効果音を演奏して一瞬待つ。
 #	アクターの場合は二刀流を考慮 (左手武器は反転して表示) 。
 #--------------------------------------------------------------------------
 def display_attack_animation(targets)
if @active_battler.is_a?(Game_Enemy)
  Sound.play_enemy_attack
  wait(15, true)
else
  aid1 = @active_battler.atk_animation_id
  aid2 = @active_battler.atk_animation_id2
  display_normal_animation(targets, aid1, false)
  display_normal_animation(targets, aid2, true)
end
wait_for_animation
 end
 #--------------------------------------------------------------------------
 # ● 通常アニメーションの表示
 #	 targets	  : 対象者の配列
 #	 animation_id : アニメーション ID
 #	 mirror	   : 左右反転
 #--------------------------------------------------------------------------
 def display_normal_animation(targets, animation_id, mirror = false)
animation = $data_animations[animation_id]
if animation != nil
  to_screen = (animation.position == 3)	   # 位置が「画面」か?
  for target in targets.uniq
	target.animation_id = animation_id
	target.animation_mirror = mirror
	wait(20, true) unless to_screen		   # 単体用ならウェイト
  end
  wait(20, true) if to_screen				 # 全体用ならウェイト
end
 end
 #--------------------------------------------------------------------------
 # ● 行動結果の表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_action_effects(target, obj = nil)
unless target.skipped
  line_number = @message_window.line_number
  wait(5)
  display_critical(target, obj)
  display_damage(target, obj)
  display_state_changes(target, obj)
  if line_number == @message_window.line_number
	display_failure(target, obj) unless target.states_active?
  end
  if line_number != @message_window.line_number
	wait(30)
  end
  @message_window.back_to(line_number)
end
 end
 #--------------------------------------------------------------------------
 # ● クリティカルヒットの表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_critical(target, obj = nil)
if target.critical
  if target.actor?
	text = Vocab::CriticalToActor
  else
	text = Vocab::CriticalToEnemy
  end
  @message_window.add_instant_text(text)
  wait(20)
end
 end
 #--------------------------------------------------------------------------
 # ● ダメージの表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_damage(target, obj = nil)
if target.missed
  display_miss(target, obj)
elsif target.evaded
  display_evasion(target, obj)
else
  display_hp_damage(target, obj)
  display_mp_damage(target, obj)
end
 end
 #--------------------------------------------------------------------------
 # ● ミスの表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_miss(target, obj = nil)
if obj == nil or obj.physical_attack
  if target.actor?
	text = sprintf(Vocab::ActorNoHit, target.name)
  else
	text = sprintf(Vocab::EnemyNoHit, target.name)
  end
  Sound.play_miss
else
  text = sprintf(Vocab::ActionFailure, target.name)
end
@message_window.add_instant_text(text)
wait(30)
 end
 #--------------------------------------------------------------------------
 # ● 回避の表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_evasion(target, obj = nil)
if target.actor?
  text = sprintf(Vocab::ActorEvasion, target.name)
else
  text = sprintf(Vocab::EnemyEvasion, target.name)
end
Sound.play_evasion
@message_window.add_instant_text(text)
wait(30)
 end
 #--------------------------------------------------------------------------
 # ● HP ダメージ表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_hp_damage(target, obj = nil)
if target.hp_damage == 0				# ノーダメージ
  return if obj != nil and obj.damage_to_mp
  return if obj != nil and obj.base_damage == 0
  fmt = target.actor? ? Vocab::ActorNoDamage : Vocab::EnemyNoDamage
  text = sprintf(fmt, target.name)
elsif target.absorbed				   # 吸収
  fmt = target.actor? ? Vocab::ActorDrain : Vocab::EnemyDrain
  text = sprintf(fmt, target.name, target.hp_damage, Vocab::hp)
elsif target.hp_damage > 0			  # ダメージ
  if target.actor?
	text = sprintf(Vocab::ActorDamage, target.name, target.hp_damage)
	Sound.play_actor_damage
	$game_troop.screen.start_shake(5, 5, 10)
  else
	text = sprintf(Vocab::EnemyDamage, target.name, target.hp_damage)
	Sound.play_enemy_damage
	target.blink = true
  end
else									# 回復
  fmt = target.actor? ? Vocab::ActorRecovery : Vocab::EnemyRecovery
  text = sprintf(fmt, target.name, -target.hp_damage, Vocab::hp)
  Sound.play_recovery
end
@message_window.add_instant_text(text)
wait(30)
 end
 #--------------------------------------------------------------------------
 # ● MP ダメージ表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_mp_damage(target, obj = nil)
return if target.dead?
return if target.mp_damage == 0
if target.absorbed					  # 吸収
  fmt = target.actor? ? Vocab::ActorDrain : Vocab::EnemyDrain
  text = sprintf(fmt, target.name, target.mp_damage, Vocab::mp)
elsif target.mp_damage > 0			  # ダメージ
  fmt = target.actor? ? Vocab::ActorLoss : Vocab::EnemyLoss
  text = sprintf(fmt, target.name, target.mp_damage, Vocab::mp)
else									# 回復
  fmt = target.actor? ? Vocab::ActorRecovery : Vocab::EnemyRecovery
  text = sprintf(fmt, target.name, -target.mp_damage, Vocab::mp)
  Sound.play_recovery
end
@message_window.add_instant_text(text)
wait(30)
 end
 #--------------------------------------------------------------------------
 # ● ステート変化の表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_state_changes(target, obj = nil)
return if target.missed or target.evaded
return unless target.states_active?
if @message_window.line_number < 4
  @message_window.add_instant_text("")
end
display_added_states(target, obj)
display_removed_states(target, obj)
display_remained_states(target, obj)
if @message_window.last_instant_text.empty?
  @message_window.back_one
else
  wait(10)
end
 end
 #--------------------------------------------------------------------------
 # ● 付加されたステートの表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_added_states(target, obj = nil)
for state in target.added_states
  if target.actor?
	next if state.message1.empty?
	text = target.name + state.message1
  else
	next if state.message2.empty?
	text = target.name + state.message2
  end
  if state.id == 1					  # 戦闘不能
	target.perform_collapse
  end
  @message_window.replace_instant_text(text)
  wait(20)
end
 end
 #--------------------------------------------------------------------------
 # ● 解除されたステートの表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_removed_states(target, obj = nil)
for state in target.removed_states
  next if state.message4.empty?
  text = target.name + state.message4
  @message_window.replace_instant_text(text)
  wait(20)
end
 end
 #--------------------------------------------------------------------------
 # ● 変化しなかったステートの表示
 #	 target : 対象者
 #	 obj	: スキルまたはアイテム
 #	すでに眠っている相手をさらに眠らせようとした場合など。
 #--------------------------------------------------------------------------
 def display_remained_states(target, obj = nil)
for state in target.remained_states
  next if state.message3.empty?
  text = target.name + state.message3
  @message_window.replace_instant_text(text)
  wait(20)
end
 end
 #--------------------------------------------------------------------------
 # ● 失敗の表示
 #	 target : 対象者 (アクター)
 #	 obj	: スキルまたはアイテム
 #--------------------------------------------------------------------------
 def display_failure(target, obj)
text = sprintf(Vocab::ActionFailure, target.name)
@message_window.add_instant_text(text)
wait(20)
 end
end

 

 

Replace XP Style Battle - Main with this one.

Note: Look at the top part of the script to change the Switch used.

[spoiler=XP Style Battle - Main]

# Added by Polraudio
# Replace the number below with the switch number you wish to use.
# When this switch is on it will disable items and skills.
$forest = 1

#==============================================================================
# ★RGSS2 
# STR11c_XP風バトル#メイン v1.8 08/01/27
# サポート:http://otsu.cool.ne.jp/strcatyou/
# ・本格的にバトルレイアウトを2000+XP化。
#  とにかく色々変化します。
# ・ターゲット指定用のカーソルグラフィックを
#  Systemにインポートしておく必要があります。
#   規格は   幅 = 一コマの幅*アニメ数
#      高さ = 一コマの高さ*3
#  一列目にアクターコマンド時のカーソル、
#  ニ列目にアクター選択時のカーソル、
#  三列目にエネミー選択時のカーソル
#
# ・コマンドにオートを追加。
# ・STR11aとSTR11bとSTR11dをセットでどうぞ。
#
#------------------------------------------------------------------------------
#
# 更新履歴
# ◇1.7→1.8
# パーティーコマンドのオプションを追加
# ◇1.6→1.7
# オートボタンと決定/キャンセルボタンを同タイミングで押すとバグるのを修正
# オートボタンを無効に出来ないバグを修正
# 死ぬほど見難かった設定箇所を整理
# いろいろ
# ◇1.5→1.6
# アクター指定時のウィンドウの挙動をエネミー指定時の物と同じにした
# ターゲットの名前表示欄(Window_Help)にステートアイコンを表示できるようになった
# ◇今までの主な修正・変更点
# STR11e_バトルステータス++に対応
# ステータス座標の位置変更
# レベルダウンしてもレベルアップポップがでるバグを修正
# 戦闘中にメンバーの入れ替えが出来ないバグを修正
# 戦闘不能キャラにカーソルを当てるとキャラが起き上がるバグ修正
#
#==============================================================================
# ■ STRRGSS2(設定箇所)
#==============================================================================
module STRRGSS2
 # レベルアップ時のSE ("ファイル名", ボリューム, ピッチ)
 LEVELUP_SE = RPG::SE.new("Flash2", 80, 100)
 LEVELUP_T  = "¡Sube de Nivel!" # レベルアップポップの文字列
 #
 TR_STATE_W = 144		 # ターゲット名前表示欄のステート横幅
 SHAKE	  = true		# 被ダメージ時のシェイクを止める
 #
 ST_SX	  = -20		 # ステータスのX座標修正
 ST_SY	  = -98		 # ステータスのY座標修正
 ST_WIDTH   = 80		  # ステータス横幅
 ST_NAME	= true		# ステータスに名前を表示する
 #
 ACOMMAND_W = true		# アクターコマンドを横並びに変更
 PCOMMAND_W = true		# パーティコマンドを横並びに変更
 PCOMMAND_R = [0,0,544,1] # パーティコマンド[X座標, Y座標, 幅, 文字揃え]
 #
 AUTOC	  = true		# オートコマンド追加
 C_AUTO	 = true		# アクター別コマンド入力中に指定ボタンでオート
 V_AUTO	 = "Auto"	# オートコマンドの名称
 C_AUTO_KEY = Input::A	# オートボタン C、B以外
end
class Sprite_BattleCursor < Sprite
 CURSOR	 = "Cursor"	# カーソルグラフィックのファイル名
 WAIT	   = 4		   # カーソルアニメスピード 値が小さいほど早い
 SPEED	  = 4		   # カーソル移動スピード  値が小さいほど早い
 CW		 = 32		  # 1コマの幅
 CH		 = 32		  # 1コマの高さ
end
class Window_BattleStatus < Window_Selectable
 # バトルステータス座標
 def set_xy
@x = []
@y = []
for i in 0...$game_party.members.size
  w = 544 / $game_party.members.size
  x = (544 / 2) - (($game_party.members.size - 1) * (w / 2))
  x += (i * w)
  @x[i] = x + STRRGSS2::ST_SX
  @y[i] = 416 + STRRGSS2::ST_SY
end
 end
end
#==============================================================================
# ■ Sprite_BattleCursor
#==============================================================================
class Sprite_BattleCursor < Sprite
 #--------------------------------------------------------------------------
 # ● 公開インスタンス変数
 #--------------------------------------------------------------------------
 attr_accessor :xx
 attr_accessor :yy
 attr_accessor :type
 #--------------------------------------------------------------------------
 # ● オブジェクト初期化
 #--------------------------------------------------------------------------
 def initialize(viewport)
super(viewport)
self.bitmap = Cache.system(CURSOR)
self.src_rect.set(0, 0, CW, CH)
self.ox = CW / 2
self.oy = CH / 2
@wait = WAIT
self.x = 544 / 2
self.y = 416
self.z += 25
@xx = self.x
@yy = self.y
@type = 0
 end
 #--------------------------------------------------------------------------
 # ● 解放
 #--------------------------------------------------------------------------
 def dispose
if self.bitmap != nil
  self.bitmap.dispose
end
super
 end
 #--------------------------------------------------------------------------
 # ● フレーム更新
 #--------------------------------------------------------------------------
 def update
super
s = (SPEED - 1)
self.x = ((self.x * s) + @xx) / SPEED
self.y = ((self.y * s) + @yy) / SPEED
@wait -= 1
return if @wait > 0
@wait = WAIT
self.src_rect.x += CW
self.src_rect.x = 0 if (self.bitmap.width <= self.src_rect.x)
self.src_rect.y = CH * @type
 end
end
#==============================================================================
# ■ Sprite_Battler
#==============================================================================
class Sprite_Battler < Sprite_Base
 alias update_str11c update
 def update
update_str11c
if (@battler != nil and @battler.cursor_flash and
	not @battler.dead? and @effect_duration <= 0)
  @battler.white_flash = true 
end
 end
end
#==============================================================================
# ■ Spriteset_Battle
#==============================================================================
class Spriteset_Battle
 #--------------------------------------------------------------------------
 # ★ エイリアス
 #--------------------------------------------------------------------------
 alias update_viewports_str11c update_viewports
 def update_viewports
update_viewports_str11c
@viewport1.ox = 0 if STRRGSS2::SHAKE
 end
end
#==============================================================================
# ■ Game_Battler
#==============================================================================
class Game_Battler
 #--------------------------------------------------------------------------
 # ● 公開インスタンス変数
 #--------------------------------------------------------------------------
 attr_accessor :cursor_flash
 #--------------------------------------------------------------------------
 # ★ エイリアス
 #--------------------------------------------------------------------------
 alias clear_sprite_effects_str11 clear_sprite_effects
 def clear_sprite_effects
clear_sprite_effects_str11
@cursor_flash = false
 end
end
#==============================================================================
# ■ Window_PartyCommand
#==============================================================================
class Window_PartyCommand < Window_Command
 #--------------------------------------------------------------------------
 # ★ 再定義
 #--------------------------------------------------------------------------
 def initialize
s1 = Vocab::fight
s2 = Vocab::escape
w = STRRGSS2::PCOMMAND_R[2]
cl = 1
if STRRGSS2::PCOMMAND_W
  cl = 2
  cl += 1 if STRRGSS2::AUTOC
end
if STRRGSS2::AUTOC
  super(w, [s1, STRRGSS2::V_AUTO, s2], cl, 0)
  draw_item(0, true)
  draw_item(1, true)
  draw_item(2, $game_troop.can_escape)
else
  super(w, [s1, s2], cl, 0)
  draw_item(0, true)
  draw_item(1, $game_troop.can_escape)
end
self.x = STRRGSS2::PCOMMAND_R[0]
self.y = STRRGSS2::PCOMMAND_R[1]
self.active = false
 end
 #--------------------------------------------------------------------------
 # ● 項目の描画
 #	 index   : 項目番号
 #	 enabled : 有効フラグ。false のとき半透明で描画
 #--------------------------------------------------------------------------
 def draw_item(index, enabled = true)
rect = item_rect(index)
rect.x += 4
rect.width -= 8
self.contents.clear_rect(rect)
self.contents.font.color = normal_color
self.contents.font.color.alpha = enabled ? 255 : 128
self.contents.draw_text(rect, @commands[index], STRRGSS2::PCOMMAND_R[3])
 end
 def update
super
self.visible = self.active
 end
end
#==============================================================================
# ■ Window_ActorCommand
#==============================================================================
class Window_ActorCommand < Window_Command
 #--------------------------------------------------------------------------
 # ★ 再定義
 #--------------------------------------------------------------------------
 def initialize
if STRRGSS2::ACOMMAND_W
  super(400, [], 4, 1, 4)
  @my = 160 + 32
else
  super(128, [], 1, 4)
  @my = 160 + 96
end
self.active = false
 end
 def setup(actor)
s1 = Vocab::attack
if $game_switches[$forest] == true
  s2 = "Disabled!"
  else
s2 = Vocab::skill
 end
s3 = Vocab::guard
if $game_switches[$forest] == true
  s4 = "Disabled!"
  else
s4 = Vocab::item
end

if actor.class.skill_name_valid	 # スキルのコマンド名が有効?
  s2 = actor.class.skill_name	   # コマンド名を置き換える
end
@commands = [s1, s2, s3, s4]
@item_max = 4
refresh
self.index = 0
self.x = actor.screen_x - (self.width / 2)
self.x = 4 if self.x <= 4
self.x = 540 - self.width if (self.x + self.width) >= 540
self.y = actor.screen_y - @my
 end
 def update
super
self.visible = self.active
 end
 def draw_item(index, enabled = true)
rect = item_rect(index)
rect.x += 4
rect.width -= 8
self.contents.clear_rect(rect)
self.contents.font.color = normal_color
self.contents.font.color.alpha = enabled ? 255 : 128
a = 0
a = 1 if STRRGSS2::ACOMMAND_W
self.contents.draw_text(rect, @commands[index], a)
 end
end
#==============================================================================
# ■ Window_BattleStatus
#==============================================================================
class Window_BattleStatus < Window_Selectable
 #--------------------------------------------------------------------------
 # ★ エイリアス
 #--------------------------------------------------------------------------
 alias initialize_str11c initialize
 def initialize(f = false)
@f = f
@lvuppop = []
set_xy
@s_sprite = []
@s_party = []
@s_lv = []
@opacity = 0
initialize_str11c
self.contents.dispose
self.contents = Bitmap.new(STRRGSS2::ST_WIDTH, height - 32)
self.back_opacity = 0
self.opacity = 0
@column_max = $game_party.actors.size
 end
 #--------------------------------------------------------------------------
 # ● リフレッシュ
 #--------------------------------------------------------------------------
 def refresh
self.contents.clear
@item_max = $game_party.members.size
for i in 0...@item_max
  draw_item(i)
end
update
 end
 #--------------------------------------------------------------------------
 # ● 名前の描画
 #--------------------------------------------------------------------------
 def draw_actor_name(actor, x, y)
self.contents.font.color = hp_color(actor)
self.contents.draw_text(x, y, STRRGSS2::ST_WIDTH, WLH, actor.name)
 end
 #--------------------------------------------------------------------------
 # ★ 再定義
 #--------------------------------------------------------------------------
 def draw_item(index)
return unless @f
rect = item_rect(index)
rect.x = 0
rect.y = 0
rect.width -= 8
self.contents.clear_rect(rect)
self.contents.font.color = normal_color
actor = $game_party.members[index]
draw_actor_name(actor, rect.x, rect.y + 72 - 24 - 40) if STRRGSS2::ST_NAME
w = STRRGSS2::ST_WIDTH
draw_actor_state(actor, rect.x, rect.y + 72, w)
draw_actor_hp(actor, rect.x, rect.y + 72 - 24 - 20, w)
draw_actor_mp(actor, rect.x, rect.y + 72 - 24, w)
#
@s_sprite[index] = Sprite.new if @s_sprite[index] == nil
@s_sprite[index].bitmap = self.contents.clone
@s_sprite[index].x = @x[index] + 4
@s_sprite[index].y = @y[index]
@s_sprite[index].opacity = @opacity
@s_lv[index] = actor.level
@s_party[index] = [actor.name, actor.hp, actor.maxhp, actor.mp, actor.maxmp, actor.states]
#
self.contents.clear
 end
 def update
super
return unless @f
for i in 0...@s_sprite.size
  @s_sprite[i].opacity = @opacity
end
@opacity += 8
for i in 0...@s_sprite.size
  a = $game_party.members[i]
  m = @s_party[i]
  if (a.level > @s_lv[i])
	STRRGSS2::LEVELUP_SE.play
	tx = STRRGSS2::LEVELUP_T
	@lvuppop.push(Sprite_PopUpText.new(a.screen_x,a.screen_y + 32,[tx], 0, 36))
	@s_lv[i] = a.level
  end
  if (a.name != m[0]) or (a.hp != m[1]) or (a.mp != m[3]) or
	(a.states != m[5]) or (a.maxhp != m[2]) or (a.maxmp != m[4])
	@s_sprite[i].bitmap.dispose
	draw_item(i)
  end
end
 end
 def dispose	   
super
return unless @f
for i in 0...@lvuppop.size
  @lvuppop[i].dispose if @lvuppop[i] != nil
end
@lvuppop = nil
for i in 0...@s_sprite.size
  @s_sprite[i].bitmap.dispose
  @s_sprite[i].dispose
end
 end
 def item_rect(index)
rect = Rect.new(0, 0, 0, 0)
return rect
 end
end
#==============================================================================
# ■ Window_TargetEnemy
#==============================================================================
class Window_TargetEnemy < Window_Command
 #--------------------------------------------------------------------------
 # ★ 再定義
 #--------------------------------------------------------------------------
 def initialize
commands = []
@enemies = []
for enemy in $game_troop.members
  next unless enemy.exist?
  commands.push(enemy.name)
  @enemies.push(enemy)
end
super(416, commands, 8, 1)
self.z = -100
self.back_opacity = 0
self.opacity = 0
self.contents_opacity = 0
 end
end
if STRRGSS2::AUTOC
#==============================================================================
# ■ Scene_Battle
#==============================================================================
class Scene_Battle < Scene_Base
 #--------------------------------------------------------------------------
 # ★ エイリアス
 #--------------------------------------------------------------------------
 alias update_actor_command_selection_str07_11 update_actor_command_selection
 def update_actor_command_selection
update_actor_command_selection_str07_11
if not Input.trigger?(Input::C) and not Input.trigger?(Input::B) and
   Input.trigger?(STRRGSS2::C_AUTO_KEY) and STRRGSS2::C_AUTO
  Sound.play_decision
  @active_battler.make_action if @active_battler != nil
  next_actor
end
 end
 #--------------------------------------------------------------------------
 # ★ 再定義
 #--------------------------------------------------------------------------
 def next_actor
loop do
  if @actor_index == $game_party.members.size-1
	start_main
	return
  end
  @status_window.index = @actor_index += 1
  @active_battler = $game_party.members[@actor_index]
  if @active_battler.auto_battle or @autobattle
	@active_battler.make_action
	next
  end
  break if @active_battler.inputable?
end
start_actor_command_selection
 end
 def update_party_command_selection
if Input.trigger?(Input::C)
  case @party_command_window.index
  when 0  # 戦う
	Sound.play_decision
	@status_window.index = @actor_index = -1
	@autobattle = false
	next_actor
  when 1  # オート
	Sound.play_decision
	@status_window.index = @actor_index = -1
	@autobattle = true
	next_actor
  when 2  # 逃げる
	if $game_troop.can_escape == false
	  Sound.play_buzzer
	  return
	end
	Sound.play_decision
	process_escape
  end
end
 end
end
#
end
#==============================================================================
# ■ Scene_Battle
#==============================================================================
class Scene_Battle < Scene_Base
 #--------------------------------------------------------------------------
 # ★ エイリアス(v1.4修正箇所)
 #--------------------------------------------------------------------------
 alias start_str11c start
 def start
update_strbtflash
# 配列記憶
@str_member = $game_party.members.clone
@trid = -1
start_str11c
 end
 alias process_battle_event_str11c process_battle_event
 def process_battle_event
process_battle_event_str11c
# パーティメンバーに変更があった場合、
# ステータス・バトラーを作り直し
if @str_member != $game_party.members
  @str_member = $game_party.members.clone
  @spriteset.dispose_actors
  @spriteset.create_actors
  @status_window.dispose
  @status_window = Window_BattleStatus.new(true)
  @status_window.x = 0
  @status_window.y = 416 - 128
end
 end
 alias process_escape_str11c process_escape
 def process_escape
@party_command_window.visible = false
process_escape_str11c
 end
 alias update_party_command_selection_str11c update_party_command_selection
 def update_party_command_selection
update_strbtflash
update_party_command_selection_str11c
 end
 #--------------------------------------------------------------------------
 # ● フレーム更新
 #--------------------------------------------------------------------------
 alias update_str11 update
 def update
if @status_window.index != -1
  update_strbtflash
  m = $game_party.actors
  a = $game_actors[m[@status_window.index]]
  a.cursor_flash = true
end
if @target_enemy_window != nil
  update_strbtflash
  m = @target_enemy_window.enemy
  a = $game_troop.members[m.index]
  a.cursor_flash = true
  @cursor.type = 2
  @cursor.xx = a.screen_x
  @cursor.yy = a.screen_y
  @cursor.update
  @cursor.visible = true
  text = a.name
  if @trid != a.index
	@trid = a.index
	@en_help_window.set_text(text, 1)
	x = @en_help_window.width - 32 - STRRGSS2::TR_STATE_W
	@en_help_window.draw_actor_state(a, x, 0, STRRGSS2::TR_STATE_W)
  end
elsif @target_actor_window != nil
  update_strbtflash
  m = $game_party.actors
  a = $game_actors[m[@target_actor_window.index]]
  a.cursor_flash = true
  @cursor.type = 1
  @cursor.xx = a.screen_x
  @cursor.yy = a.screen_y - 16
  @cursor.update
  @cursor.visible = true
  text = a.name
  if @trid != a.id
	@trid = a.id
	@en_help_window.set_text(text, 1)
	x = @en_help_window.width - 32 - STRRGSS2::TR_STATE_W
	@en_help_window.draw_actor_state(a, x, 0, STRRGSS2::TR_STATE_W)
  end
elsif @status_window.index != -1
  m = $game_party.actors
  a = $game_actors[m[@status_window.index]]
  @cursor.type = 0
  @cursor.xx = a.screen_x
  @cursor.yy = a.screen_y - 8
  @cursor.update
  @cursor.visible = true
else
  @cursor.type = -1
  @cursor.xx = 544 / 2
  @cursor.yy = 416 / 2
  @cursor.visible = false
end
update_str11
 end
 def update_strbtflash
for i in 0...$game_party.members.size
  $game_party.members[i].cursor_flash = false
end
for i in 0...$game_troop.members.size
  $game_troop.members[i].cursor_flash = false
end
 end
 alias update_basic_str11c update_basic
 def update_basic(m = false)
update_basic_str11c(m)
@status_window.update
 end
 #--------------------------------------------------------------------------
 # ● 情報表示ビューポートの作成
 #--------------------------------------------------------------------------
 def create_info_viewport
# 何も無い
@info_viewport = Viewport.new(0, 0, 32, 32)
@info_viewport.z = 100
# ステータス
@status_window = Window_BattleStatus.new(true)
@status_window.x = 0
@status_window.y = 416 - 128
# パーティコマンド
@party_command_window = Window_PartyCommand.new
@party_command_window.visible = false
# アクターコマンド
@actor_command_window = Window_ActorCommand.new
@actor_command_window.x = 544 - 128
@actor_command_window.visible = false
# カーソル
@cursor = Sprite_BattleCursor.new(nil)
@cursor.visible = false
# 
@info_viewport.visible = false
 end
 #--------------------------------------------------------------------------
 # ● 情報表示ビューポートの更新
 #--------------------------------------------------------------------------
 def update_info_viewport
@party_command_window.update
@actor_command_window.update
 end
 #--------------------------------------------------------------------------
 # ● 対象敵キャラ選択の開始
 #--------------------------------------------------------------------------
 alias start_target_enemy_selection_str11 start_target_enemy_selection
 def start_target_enemy_selection
strtrhelp_start
start_target_enemy_selection_str11
 end
 #--------------------------------------------------------------------------
 # ● 対象敵キャラ選択の終了
 #--------------------------------------------------------------------------
 alias end_target_enemy_selection_str11 end_target_enemy_selection
 def end_target_enemy_selection
for i in 0...$game_troop.members.size
  $game_troop.members[i].cursor_flash = false
end
strtrhelp_end
end_target_enemy_selection_str11
 end
 #--------------------------------------------------------------------------
 # ● 対象アクター対象選択の開始
 #--------------------------------------------------------------------------
 alias start_target_actor_selection_str11 start_target_actor_selection
 def start_target_actor_selection
strtrhelp_start
start_target_actor_selection_str11
 end
 #--------------------------------------------------------------------------
 # ● 対象アクター選択の終了
 #--------------------------------------------------------------------------
 alias end_target_actor_selection_str11 end_target_actor_selection
 def end_target_actor_selection
for i in 0...$game_party.members.size
  $game_party.members[i].cursor_flash = false
end
strtrhelp_end
end_target_actor_selection_str11
 end
 #--------------------------------------------------------------------------
 # ★ 追加
 #--------------------------------------------------------------------------
 def strtrhelp_start
@trid = -1
@en_help_window = Window_Help.new
@help_window.visible = false if @help_window != nil
@skill_window.visible = false if @skill_window != nil
 end
 def strtrhelp_end
@trid = -1
@en_help_window.dispose
@help_window.visible = true if @help_window != nil
@skill_window.visible = true if @skill_window != nil
 end
end

 

Share this post


Link to post
Share on other sites

Thank you (I wonder why the spoiler won't work?). I'm going to test it out now to see if it'll have a problem with any of the other scripts. Cool, you change the Skill and Item names to Disabled! No problems with any of the scripts. Question, I'm planning on having some classes have, instead of skills, have a different "Command Name". Like Magic for Magicians, Ninjutsu for Ninjas, etc... But when I change the Command Name, it doesn't change to Disable! when I turn the switch on that'll change them to Disabled!. Any idea why it won't do that?

Share this post


Link to post
Share on other sites

Here, try this:

class Window_ActorCommand < Window_Command
 alias leon_noitem_winac_setup setup

 def setup(actor)
leon_noitem_winac_setup(actor)
if $game_switches[1] == true
  s1 = Vocab::attack
  s3 = Vocab::guard
  s2 = "Disabled!"
  s4 = "Disabled!"
  @commands = [s1, s2, s3, s4]
  self.draw_item(1, false)
  self.draw_item(3, false)
end
 end
end


class Scene_Battle
 def update_actor_command_selection
if Input.trigger?(Input::B)
  Sound.play_cancel
  prior_actor
elsif Input.trigger?(Input::C)
  case @actor_command_window.index
  when 0  # Attack
	Sound.play_decision
	@active_battler.action.set_attack
	start_target_enemy_selection
  when 1  # Skill
	if $game_switches[1] == true
	  Sound.play_buzzer
	  return
	end
	Sound.play_decision
	start_skill_selection
  when 2  # Guard
	Sound.play_decision
	@active_battler.action.set_guard
	next_actor
  when 3  # Item
	if $game_switches[1] == true
	  Sound.play_buzzer
	  return
	end
	Sound.play_decision
	start_item_selection
  end
end
 end
end


class Scene_Menu
 alias leon_noitem_scenemenu_ccw create_command_window

 def create_command_window
leon_noitem_scenemenu_ccw
if $game_switches[1] == true
  s1 = "Disabled!"
  s2 = Vocab::skill
  s3 = Vocab::equip
  s4 = Vocab::status
  s5 = Vocab::save
  s6 = Vocab::game_end
  @command_window = Window_Command.new(160, [s1, s2, s3, s4, s5, s6])
  @command_window.draw_item(0, false)
end
 end

 def update_command_selection
if Input.trigger?(Input::B)
  Sound.play_cancel
  $scene = Scene_Map.new
elsif Input.trigger?(Input::C)
  if $game_party.members.size == 0 and @command_window.index < 4
	Sound.play_buzzer
	return
  elsif $game_system.save_disabled and @command_window.index == 4
	Sound.play_buzzer
	return
  end
  if $game_switches[1] == true and @command_window.index == 0
	Sound.play_buzzer
	return
  end
  Sound.play_decision
  case @command_window.index
  when 0	  # Item
	$scene = Scene_Item.new
  when 1,2,3  # Skill, equipment, status
	start_actor_selection
  when 4	  # Save
	$scene = Scene_File.new(true, false, false)
  when 5	  # End Game
	$scene = Scene_End.new
  end
end
 end

end

Share this post


Link to post
Share on other sites

It works, it even makes the disable words those dim gray colors. Thank you Leon and Polraudio.

 

Edit: Now all that's left is to make the forest field :P

Share this post


Link to post
Share on other sites

@nis: Don't mention it.

 

@pol: If you ever want to learn more advanced tricks, just ask. i know a lot of neat stuff.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...