赞 | 46 |
VIP | 271 |
好人卡 | 233 |
积分 | 94 |
经验 | 181865 |
最后登录 | 2024-9-17 |
在线时间 | 2748 小时 |
Lv4.逐梦者 「Pemercyia」 泱 银 Urhurrenna
- 梦石
- 0
- 星屑
- 9397
- 在线时间
- 2748 小时
- 注册时间
- 2008-9-5
- 帖子
- 3543
|
没理解错的话~大概是这样:
脚本:Scene_Battle
之一:- #--------------------------------------------------------------------------
- # ● 战斗开始
- #--------------------------------------------------------------------------
- def self.battle_start
- $game_system.battle_count += 1
- $game_party.on_battle_start
- $game_troop.on_battle_start
- $game_troop.enemy_names.each do |name|
- $game_message.add(sprintf(Vocab::Emerge, name))
- end
- $game_message.position = 1 #a
- if @preemptive
- $game_message.add(sprintf(Vocab::Preemptive, $game_party.name))
- elsif @surprise
- $game_message.add(sprintf(Vocab::Surprise, $game_party.name))
- end
- wait_for_message
- $game_message.position = 0 #a
- end
复制代码 之二:- #--------------------------------------------------------------------------
- # ● 胜利时的处理
- #--------------------------------------------------------------------------
- def self.process_victory
- play_battle_end_me
- replay_bgm_and_bgs
- $game_message.position = 1 #a
- $game_message.add(sprintf(Vocab::Victory, $game_party.name))
- display_exp
- gain_gold
- gain_drop_items
- gain_exp
- SceneManager.return
- battle_end(0)
- return true
- end
复制代码 之三:- #--------------------------------------------------------------------------
- # ● 撤退时的处理
- #--------------------------------------------------------------------------
- def self.process_escape
- $game_message.position = 1 #a
- $game_message.add(sprintf(Vocab::EscapeStart, $game_party.name))
- success = @preemptive ? true : (rand < @escape_ratio)
- Sound.play_escape
- if success
- process_abort
- else
- @escape_ratio += 0.1
- $game_message.add('\.' + Vocab::EscapeFailure)
- $game_party.clear_actions
- end
- wait_for_message
- return success
- end
复制代码 之四:- #--------------------------------------------------------------------------
- # ● 全灭时的处理
- #--------------------------------------------------------------------------
- def self.process_defeat
- $game_message.position = 1 #a
- $game_message.add(sprintf(Vocab::Defeat, $game_party.name))
- wait_for_message
- if @can_lose
- revive_battle_members
- replay_bgm_and_bgs
- SceneManager.return
- else
- SceneManager.goto(Scene_Gameover)
- end
- battle_end(2)
- return true
- end
复制代码 之五:- #--------------------------------------------------------------------------
- # ● 战斗结束
- # result : 结果(0:胜利 1:撤退 2:全灭)
- #--------------------------------------------------------------------------
- def self.battle_end(result)
- @phase = nil
- @event_proc.call(result) if @event_proc
- $game_party.on_battle_end
- $game_troop.on_battle_end
- SceneManager.exit if $BTEST
- $game_message.position = 0 #a
- end
复制代码 以上,所有带"#a"的句子加进去大概就好了~
PS:本来想直接在判定结果的那段加上位置修改的,但是不知道为什么,没起效……可能是打开姿势不对…… |
评分
-
查看全部评分
|