[JavaScript] 纯文本查看 复制代码
BattleManager.endBattle = function(result) {
this._phase = 'battleEnd';
if (this._eventCallback) {
this._eventCallback(result);
}
var ids= []
$gameParty._actors.map(function(id) {
if ($gameActors.actor(id).isDead()){
ids.push(id)
}
});
for(var i=ids.length-1;i>=0;i--){
$gameParty.removeActor(ids[i])
}
if (result === 0) {
$gameSystem.onBattleWin();
} else if (this._escaped) {
$gameSystem.onBattleEscape();
}
};