Olá preciso de ajuda, conheço bem pouco de linguagem e queria fazer uma pequena modificação no plugin do MOG BattleCry, sempre que há uma vitória o plugin seleciona a voz de dois personagens, dependendo da fala acaba que fica dificil a compreenção, fucei a torto e arrodo mas nao encontrei a linha no plugin q define a quantidade de atores q vão falar após a vitoria. Quem manjar e puder dar um help ficaria agradecido :3
//=============================================================================
// MOG_BattleCry.js
//=============================================================================
/*:
* @plugindesc (v1.3) Adiciona vozes na batalha.
* @author Moghunter
*
* @param Volume
* @desc Definição do volume.
* @default 120
*
* @help
* =============================================================================
* +++ MOG - Battle Cry (v1.3) +++
* By Moghunter
* https://atelierrgss.wordpress.com/
* =============================================================================
* Adiciona vozes na batalha (ação, dano, vitória,etc...)
* Para definir as vozes é necessário editar o plugin manualmente.
* A edição do plugin deve ser feita a partir da linha 70.
*
* =============================================================================
* HISTÓRICO
* =============================================================================
* (v1.3) Compatibilidade com MOG Battle Result.
* (v1.2) Compatibilidade com MOG Battle Transitions.
* (v1.1) Corrigido o bug de não mover o personagem na hora da ação.
*/
//=============================================================================
// ** PLUGIN PARAMETERS
//=============================================================================
// Não modifique essa parte.
// ☢CAUTION!!☢ Don't Touch.^_^ ----------------------------------------
var Imported = Imported || {};
Imported.MOG_BattleCry = true;
var Moghunter = Moghunter || {};
Moghunter.parameters = PluginManager.parameters('MOG_BattleCry');
Moghunter.v_volume = Number(Moghunter.parameters['Volume'] || 100);
Moghunter.v_actor_start = [];
Moghunter.v_actor_turn = [];
Moghunter.v_actor_default_action = [];
Moghunter.v_actor_skill = [];
Moghunter.v_actor_item = [];
Moghunter.v_actor_damage = [];
Moghunter.v_actor_evaded = [];
Moghunter.v_actor_dead = [];
Moghunter.v_actor_recover = [];
Moghunter.v_actor_counter = [];
Moghunter.v_actor_reflection = [];
Moghunter.v_actor_victory = [];
Moghunter.v_actor_levelup = [];
Moghunter.v_actor_escape = [];
Moghunter.v_enemy_default_action = [];
Moghunter.v_enemy_damage = [];
Moghunter.v_enemy_evaded = [];
Moghunter.v_enemy_counter = [];
Moghunter.v_enemy_reflection = [];
Moghunter.v_enemy_dead = [];
Moghunter.v_enemy_recover = [];
Moghunter.v_enemy_skill = [];
// ☢CAUTION!!☢ Don't Touch.^_^ ----------------------------------------
// SETUP ----------------------------------------------------------------
// Exemplo de configuração geral, o modo de configurar é igual para todas
// ações.
//
// Moghunter.v_actor_start[A] = [B,B,B,B...]
//
// A - Actor ID
// B - File Name
//
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
// ACTOR - BATTLE START
// -----------------------------------------------------------------------
Moghunter.v_actor_start[1] = ["Naruto a gente da conta [vocals]","naruto vou improvisar e vai dar certo","narutooq ta acontecendo aqui","naruto ja podemos começar","naruto (4)","naruto (9)","naruto (33)","naruto (46)","naruto (56)"];
Moghunter.v_actor_start[2] = ["naruto (25)"];
Moghunter.v_actor_start[3] = ["sasuke to de bom humor [vocals]","sasuke isso é uma bobeira","sasuke quero q lute agora","sasuke quero q lute comigo","sasuke vamos começar logo [vocals]","sasuke vou pegar pesado agora"];
Moghunter.v_actor_start[4] = ["Sakura cantarolando","Sakura eu acho q nos temos companhia [vocals]","Sakura O q realmente vcs querem","Sakura o que sao eles","Sakura oq querem aqui [vocals]","Sakura time 7 foi convocado vamos la [vocals]"];
// -----------------------------------------------------------------------
// ACTOR - BATTLE TURN
// -----------------------------------------------------------------------
Moghunter.v_actor_turn[1] = ["naruto (2)","naruto (3)","naruto (6)","naruto (9)","naruto (15)","naruto (25)","naruto (41)","naruto (51)","naruto (55)","naruto (56)"];
Moghunter.v_actor_turn[2] = ["naruto (25)"];
Moghunter.v_actor_turn[3] = ["sasuke entaao nossa luta continua [vocals]","sasuke eu disse que nao haveria mais conversa","sasuke isso é uma bobeira","sasuke o que é q vc quer [vocals]","sasuke precisamos fazer isso [vocals]","sasuke vamos começar logo [vocals]","sasuke vou pegar pesado agora"];
Moghunter.v_actor_turn[4] = ["sakura Com certeza","sakura entendido","sakura Espera um pouco","Sakura O q realmente vcs querem","Sakura o que sao eles","Sakura OQ esta acontecendo","Sakura oq querem aqui [vocals]","Sakura Parece que vamos conseguir","sakura preciso proteger esses dois [vocals]","Sakura Tem razão"];
Moghunter.v_actor_turn[0] = ["P1_Turn_01","P1_Turn_02"];
// -----------------------------------------------------------------------
// ACTOR - DEFAULT ACTION (Skill/ITEM)
// -----------------------------------------------------------------------
Moghunter.v_actor_default_action[1] = ["naruto (14)","naruto (15)","naruto (17)","naruto (16)","naruto (25)","naruto (26)","naruto (47)","naruto (55)","naruto (59)","naruto (67)","naruto (35)","naruto nem a pau"];
Moghunter.v_actor_default_action[2] = ["naruto (34)","naruto (25)","naruto (26)","naruto (37)","naruto (38)","naruto (36)"];
Moghunter.v_actor_default_action[3] = ["sasuke chega","sasuke cala a boca2 [vocals]","SASUKE gemido5","sasuke grunhido","sasuke gemido2 [vocals]"];
Moghunter.v_actor_default_action[4] = ["Sakura hey","Sakura grito [vocals]","Sakura ah vc! [vocals]","Sakura grito 3 [vocals]","Sakura vai nessa","Sakura vc quer brincar [vocals]","Sakura grito [vocals]"];
// -----------------------------------------------------------------------
// ACTOR - SKILL
// -----------------------------------------------------------------------
// Moghunter.v_actor_skill[A] = {B:[C,C,C,C,...] }
//
// A - Actor ID
// B - Skill ID
// C - File Name
// -----------------------------------------------------------------------
Moghunter.v_actor_skill[0] = {
3:["P1_Action_04","P1_Action_05","P1_Action_06"], //
8:["P1_Action_04","P1_Action_05","P1_Action_06"], //
9:["P1_Action_04","P1_Action_05","P1_Action_06"] //
};
Moghunter.v_actor_skill[0] = {
};
Moghunter.v_actor_skill[0] = {
10:["V_ACT2_SKILL_1"],
11:["V_ACT2_SKILL_9"],
15:["V_ACT2_SKILL_8"]
};
Moghunter.v_actor_skill[0] = {
23:["V_ACT3_SKILL_3","V_ACT3_SKILL_9"],
24:["V_ACT3_SKILL_3","V_ACT3_SKILL_9"],
25:["V_ACT3_SKILL_3","V_ACT3_SKILL_9"],
26:["V_ACT3_SKILL_3","V_ACT3_SKILL_9"]
};
// -----------------------------------------------------------------------
// ACTOR - DAMAGE
// -----------------------------------------------------------------------
Moghunter.v_actor_damage[1] = ["naruto (7)","naruto (8)","naruto (18)","naruto (21)","naruto (23)","naruto (26)","naruto (29)"];
Moghunter.v_actor_damage[2] = ["naruto (25)","naruto (26)"];
Moghunter.v_actor_damage[3] = ["sasuke gemido [vocals]","SASUKE gemido","sasuke gemido2 [vocals]","SASUKE gemido4","SASUKE gemido5","SASUKE gemido6","SASUKE gemido23","sasuke gemidos [vocals]","sasuke grunhido","sasukegemido3 [vocals]"];
Moghunter.v_actor_damage[4] = ["Sakura GEmido [vocals]","Sakura gemido 1","Sakura gemido","Sakura gemido3","Sakura gemidos2 [vocals]","Sakura gemidos3 [vocals]"];
Moghunter.v_actor_damage[0] = ["P1_Damage_01","P1_Damage_02"];
// -----------------------------------------------------------------------
// ACTOR - RECOVER
// -----------------------------------------------------------------------
Moghunter.v_actor_recover[1] = ["naruto (2)","naruto (3)","naruto (13)","naruto (31)","naruto (45)","naruto (52)","naruto (71)","naruto a gente da conta","naruto super legal hein [vocals]","naruto to de volta ao jogo","narutooq ta acontecendo aqui"];
Moghunter.v_actor_recover[2] = ["naruto (21)","naruto (25)"];
Moghunter.v_actor_recover[3] = ["sasuke vamos começar logo [vocals]","sasuke precisamos fazer isso [vocals]","sasuke eu nao vou perder de jeito nenhum [vocals]","sasuke chega","sasuke vou pegar pesado agora"];
Moghunter.v_actor_recover[4] = ["sakura pessoal [vocals]","sakura preciso proteger esses dois [vocals]","sakura rindo 2 [vocals]","Sakura sim obrigada [vocals]","Sakura vai nessa","sakura entendido"];
Moghunter.v_actor_recover[0] = ["P1_Recover_01","P1_Recover_02"];
// -----------------------------------------------------------------------
// ACTOR - DEAD
// -----------------------------------------------------------------------
Moghunter.v_actor_dead[1] = ["naruto (60)","naruto (20)","naruto (19)","naruto (60)","naruto (5)"];
Moghunter.v_actor_dead[2] = ["naruto (22)"];
Moghunter.v_actor_dead[3] = ["sasuke gemido [vocals]","SASUKE gemido","sasuke gemido2 [vocals]","SASUKE gemido4","SASUKE gemido5","SASUKE gemido6","SASUKE gemido23","sasuke gemidos [vocals]","sasuke grunhido","sasukegemido3 [vocals]"];
Moghunter.v_actor_dead[4] = ["Sakura GEmido [vocals]","Sakura gemido 1","Sakura gemido","Sakura gemido3","Sakura gemidos2 [vocals]","Sakura gemidos3 [vocals]"];
Moghunter.v_actor_dead[0] = ["P1_Dead_01"];
// -----------------------------------------------------------------------
// ACTOR - VICTORY
// -----------------------------------------------------------------------
Moghunter.v_actor_victory[1] = ["naruto (64)","naruto (10)","naruto (45)","naruto (73)","naruto (71)","naruto Um super ninja prox hokage"];
Moghunter.v_actor_victory[2] = ["naruto (19)","naruto (13)"];
Moghunter.v_actor_victory[3] = ["sasuke estamos no fim","sasuke nós ja terminamos a missao de hj eu to indo embora","sasuke vou restabelecer meu clan [vocals]"];
Moghunter.v_actor_victory[4] = ["sakuraE me tornei um pouco mais forte","Sakura time 7 foi convocado vamos la [vocals]","sakura rindo 2 [vocals]","Sakura nunca mais vou perder para vc [vocals]","Sakura eu consegui [vocals]","SAkura A pessoa que eu gosto é [vocals]"];
// -----------------------------------------------------------------------
// ACTOR - LEVEL UP
// -----------------------------------------------------------------------
Moghunter.v_actor_levelup[1] = ["naruto (64)","naruto (10)","naruto (45)","naruto (73)","naruto (71)","naruto Um super ninja prox hokage"];
Moghunter.v_actor_levelup[2] = ["naruto (19)"];
Moghunter.v_actor_levelup[3] = ["sasuke estamos no fim","sasuke nós ja terminamos a missao de hj eu to indo embora","sasuke vou restabelecer meu clan [vocals]"];
Moghunter.v_actor_levelup[4] = ["sakuraE me tornei um pouco mais forte","Sakura time 7 foi convocado vamos la [vocals]","sakura rindo 2 [vocals]","Sakura nunca mais vou perder para vc [vocals]","Sakura eu consegui [vocals]","SAkura A pessoa que eu gosto é [vocals]"];
// ACTOR - ESCAPE
// -----------------------------------------------------------------------
Moghunter.v_actor_escape[1] = ["naruto (74)","naruto (53)","naruto (52)","naruto (43)","naruto (28)","naruto (29)"];
Moghunter.v_actor_escape[2] = ["naruto (19)"];
Moghunter.v_actor_escape[3] = ["sasuke to fora disso"];
Moghunter.v_actor_escape[4] = ["sakura Profavor deixa a gente ir [vocals]"];
// -----------------------------------------------------------------------
// ACTOR - EVADED & MISS
// -----------------------------------------------------------------------
Moghunter.v_actor_evaded[1] = ["naruto (53)","naruto (47)","naruto (45)"];
Moghunter.v_actor_evaded[2] = ["naruto (45)"];
Moghunter.v_actor_evaded[3] = ["sasuke isso é uma bobeira","sasuke eu nao vou perder de jeito nenhum [vocals]","sasuke chega"];
Moghunter.v_actor_evaded[4] = ["Sakura vc quer brincar [vocals]","Sakura para com isso","Sakura idiota"];
// -----------------------------------------------------------------------
// ACTOR - COUNTER
// -----------------------------------------------------------------------
// ENEMY - DEFAULT ACTION
// -----------------------------------------------------------------------
Moghunter.v_enemy_default_action[900] = ["P1_Action_01","P1_Action_02","P1_Action_03"];
Moghunter.v_enemy_default_action[901] = ["P2_Action_01","P2_Action_02","P2_Action_03"];
// -----------------------------------------------------------------------
// ENEMY - SKILL
// -----------------------------------------------------------------------
Moghunter.v_enemy_skill[7] = {
34:["Cel_Attack_02","Cel_Attack_08"],
35:["Cel_Attack_01"],
36:["Cel_Attack_03"],
39:["Cel_Attack_04"]
};
Moghunter.v_enemy_skill[901] = {1:["P2_Action_04","P2_Action_05","P2_Action_06"]};
// -----------------------------------------------------------------------
// ENEMY - DAMAGE
// -----------------------------------------------------------------------
Moghunter.v_enemy_damage[7] = ["Cel_Damage1","Cel_Damage2"];
Moghunter.v_enemy_damage[901] = ["P2_Damage_01","P2_Damage_02","P2_Damage_03"];
// -----------------------------------------------------------------------
// ENEMY - EVADED & MISS
// -----------------------------------------------------------------------
Moghunter.v_enemy_evaded[900] = ["P1_Evade_01"];
Moghunter.v_enemy_evaded[901] = ["P1_Evade_01"];
// -----------------------------------------------------------------------
// ENEMY - COUNTER
// -----------------------------------------------------------------------
Moghunter.v_enemy_counter[900] = ["P1_Counter_01"];
Moghunter.v_enemy_counter[901] = ["P2_Counter_01"];
// -----------------------------------------------------------------------
// ENEMY - REFLECTION
// -----------------------------------------------------------------------
Moghunter.v_enemy_reflection[900] = ["P1_Reflection_01"];
Moghunter.v_enemy_reflection[901] = ["P2_Reflection_01"];
// -----------------------------------------------------------------------
// ENEMY - RECOVER
// -----------------------------------------------------------------------
Moghunter.v_enemy_recover[900] = ["P1_Recover_01","P1_Recover_02"];
Moghunter.v_enemy_recover[901] = ["P2_Recover_01","P2_Recover_02"];
// -----------------------------------------------------------------------
// ENEMY - DEAD
// -----------------------------------------------------------------------
Moghunter.v_enemy_dead[900] = ["P1_Dead_01","P1_Dead_02"];
Moghunter.v_enemy_dead[901] = ["P2_Dead_01"];
//=============================================================================
// ** Sound Manager
//=============================================================================
//==============================
// * select Voice
//==============================
SoundManager.selectVoice = function(voices){
if (!voices) {return};
if (voices.length === 0) {return};
var voiceIndex = Math.randomInt(voices.length);
var fileName = voices[voiceIndex];
this.playVoice(fileName);
};
//==============================
// * Play Voice
//==============================
SoundManager.playVoice = function(fileName){
var se = {};
se.name = fileName;
se.pitch = 100;
se.volume = Moghunter.v_volume;
AudioManager.playSe(se);
};
//=============================================================================
// ** BattleManager
//=============================================================================
//================================
// ** Random Actor
//================================
BattleManager.randomActor = function() {
var actorIndex = Math.randomInt($gameParty.aliveMembers().length);
return $gameParty.aliveMembers()[actorIndex];
};
//==================================
// ** Start Battle
//==================================
var _alias_mog_bmngr_startBattle = BattleManager.startBattle;
BattleManager.startBattle = function() {
_alias_mog_bmngr_startBattle.call(this);
if (!Imported.MOG_BattleTransitions ||
(Imported.MOG_BattleTransitions && $gameSystem._treType[1] === -1)) {
var actor = this.randomActor();
if (actor) {SoundManager.selectVoice(actor._v_start)};
};
};
//==================================
// ** Process Victory
//==================================
var _alias_mog_bcry_processVictory = BattleManager.processVictory;
BattleManager.processVictory = function() {
var actor = this.randomActor();
if (actor) {SoundManager.selectVoice(actor._v_victory)};
_alias_mog_bcry_processVictory.call(this);
};
//==================================
// ** Process Escape
//==================================
var _alias_mog_bcry_processEscape = BattleManager.processEscape;
BattleManager.processEscape = function() {
var actor = this.randomActor();
if (actor) {SoundManager.selectVoice(actor._v_escape)};
_alias_mog_bcry_processEscape.call(this);
};
//=============================================================================
// ** Game Battler
//=============================================================================
//==============================
// * InitMembers
//==============================
var _alias_mog_batcry_gbattler_initMembers = Game_Battler.prototype.initMembers;
Game_Battler.prototype.initMembers = function() {
_alias_mog_batcry_gbattler_initMembers.call(this);
this.battleCrySetup();
};
//==============================
// * Battle Cry Setup
//==============================
Game_Battler.prototype.battleCrySetup = function() {
this._v_start = [];
this._v_turn = [];
this._v_default_action = [];
this._v_damage = [];
this._v_evaded = [];
this._v_counter = [];
this._v_reflection = [];
this._v_dead = [];
this._v_recover = [];
this._v_escape = [];
this._v_victory = [];
this._v_levelup = [];
};
//==============================
// * Battle Cry Setup Actor
//==============================
Game_Battler.prototype.battleCrySetupActor = function() {
if (Moghunter.v_actor_start[this._actorId]) {this._v_start = Moghunter.v_actor_start[this._actorId]};
if (Moghunter.v_actor_turn[this._actorId]) {this._v_turn = Moghunter.v_actor_turn[this._actorId]};
if (Moghunter.v_actor_default_action[this._actorId]) {
this._v_default_action = Moghunter.v_actor_default_action[this._actorId]};
if (Moghunter.v_actor_damage[this._actorId]) {this._v_damage = Moghunter.v_actor_damage[this._actorId]};
if (Moghunter.v_actor_evaded[this._actorId]) {this._v_evaded = Moghunter.v_actor_evaded[this._actorId]};
if (Moghunter.v_actor_counter[this._actorId]) {this._v_counter = Moghunter.v_actor_counter[this._actorId]};
if (Moghunter.v_actor_reflection[this._actorId]) {this._v_reflection = Moghunter.v_actor_reflection[this._actorId]};
if (Moghunter.v_actor_dead[this._actorId]) {this._v_dead = Moghunter.v_actor_dead[this._actorId]};
if (Moghunter.v_actor_recover[this._actorId]) {this._v_recover = Moghunter.v_actor_recover[this._actorId]};
if (Moghunter.v_actor_escape[this._actorId]) {this._v_escape = Moghunter.v_actor_escape[this._actorId]};
if (Moghunter.v_actor_victory[this._actorId]) {this._v_victory = Moghunter.v_actor_victory[this._actorId]};
if (Moghunter.v_actor_levelup[this._actorId]) {this._v_levelup = Moghunter.v_actor_levelup[this._actorId]};
};
//==============================
// * Battle Cry Setup Enemy
//==============================
Game_Battler.prototype.battleCrySetupEnemy = function() {
if (Moghunter.v_enemy_default_action[this._enemyId]) {
this._v_default_action = Moghunter.v_enemy_default_action[this._enemyId]};
if (Moghunter.v_enemy_damage[this._enemyId]) {this._v_damage = Moghunter.v_enemy_damage[this._enemyId]};
if (Moghunter.v_enemy_evaded[this._enemyId]) {this._v_evaded = Moghunter.v_enemy_evaded[this._enemyId]};
if (Moghunter.v_enemy_counter[this._enemyId]) {this._v_counter = Moghunter.v_enemy_counter[this._enemyId]};
if (Moghunter.v_enemy_reflection[this._enemyId]) {this._v_reflection = Moghunter.v_enemy_reflection[this._enemyId]};
if (Moghunter.v_enemy_dead[this._enemyId]) {this._v_dead = Moghunter.v_enemy_dead[this._enemyId]};
if (Moghunter.v_enemy_recover[this._enemyId]) {this._v_recover = Moghunter.v_enemy_recover[this._enemyId]};
};
//===============================
// ** PerfotmAction
//===============================
var _alias_mog_bcry_performActionStart = Game_Battler.prototype.performActionStart;
Game_Battler.prototype.performActionStart = function(action) {
if (action) {this.playVoiceAction(action)};
_alias_mog_bcry_performActionStart.call(this, action);
};
//===============================
// ** play Voice Action
//===============================
Game_Battler.prototype.playVoiceAction = function(action) {
var actionID = action.item().id
if (this.isActor()) {
if (action.isSkill() && Moghunter.v_actor_skill[this._actorId] &&
Moghunter.v_actor_skill[this._actorId][actionID]) {
SoundManager.selectVoice(Moghunter.v_actor_skill[this._actorId][actionID]);
return;
} else if (action.isItem() && Moghunter.v_actor_item[this._actorId] &&
Moghunter.v_actor_item[this._actorId][actionID]) {
SoundManager.selectVoice(Moghunter.v_actor_item[this._actorId][actionID]);
return;
};
} else if (this.isEnemy()) {
if (Moghunter.v_enemy_skill[this._enemyId] && Moghunter.v_enemy_skill[this._enemyId][actionID]) {
SoundManager.selectVoice(Moghunter.v_enemy_skill[this._enemyId][actionID]);
return;
};
};
SoundManager.selectVoice(this._v_default_action);
};
//==============================
// ** perform Counter
//==============================
var _mog_btcry_gbat_performCounter = Game_Battler.prototype.performCounter;
Game_Battler.prototype.performCounter = function() {
_mog_btcry_gbat_performCounter.call(this);
SoundManager.selectVoice(this._v_counter);
};
//==============================
// ** perform Reflection
//==============================
var _mog_btcry_gbat_performReflection = Game_Battler.prototype.performReflection;
Game_Battler.prototype.performReflection = function() {
_mog_btcry_gbat_performReflection.call(this);
SoundManager.selectVoice(this._v_reflection);
};
//=============================================================================
// ** Game Actor
//=============================================================================
//==============================
// * Setup
//==============================
var _mog_bcry_gact_setup = Game_Actor.prototype.setup;
Game_Actor.prototype.setup = function(actorId) {
_mog_bcry_gact_setup.call(this,actorId);
this.battleCrySetupActor();
};
//=============================================================================
// ** Game Enemy
//=============================================================================
//==============================
// * Setup
//==============================
var _mog_bcry_gemy_setup = Game_Enemy.prototype.setup;
Game_Enemy.prototype.setup = function(enemyId, x, y) {
_mog_bcry_gemy_setup.call(this,enemyId, x, y);
this.battleCrySetupEnemy();
};
//=============================================================================
// ** Scene Battle
//=============================================================================
//==============================
// * select Voice
//==============================
var _alias_mog_bcry_scbat_start = Scene_Battle.prototype.start;
Scene_Battle.prototype.start = function() {
_alias_mog_bcry_scbat_start.call(this);
this._actorvoice = null;
};
//==============================
// * Update Battle Process
//==============================
var _alias_mog_bcry_updateBattleProcess = Scene_Battle.prototype.updateBattleProcess;
Scene_Battle.prototype.updateBattleProcess = function() {
if (this._actorvoice != BattleManager.actor()) {this.playActorTurn()};
_alias_mog_bcry_updateBattleProcess.call(this);
};
//==============================
// * Play Actor Turn
//==============================
Scene_Battle.prototype.playActorTurn = function() {
this._actorvoice = BattleManager.actor();
if (this._actorvoice) {AudioManager.stopSe();
SoundManager.selectVoice(this._actorvoice._v_turn)};
};
//=============================================================================
// ** Game Action
//=============================================================================
//==============================
// * Apply
//==============================
var _alias_mog_bcry_gaction_apply = Game_Action.prototype.apply;
Game_Action.prototype.apply = function(target) {
var old_hp = target.hp
_alias_mog_bcry_gaction_apply.call(this,target);
if (old_hp != target.hp || this.item().damage.type === 3) {this.playVoiceHP(old_hp,target.hp,target)};
if (target.result().missed || target.result().evaded) {SoundManager.selectVoice(target._v_evaded)};
};
//==============================
// * Play Voice HP
//==============================
Game_Action.prototype.playVoiceHP = function(old_hp,now_hp,target) {
if (target.isDead()) {
SoundManager.selectVoice(target._v_dead);
} else if (old_hp < now_hp || this.item().damage.type === 3) {
SoundManager.selectVoice(target._v_recover);
} else if (old_hp > now_hp) {
SoundManager.selectVoice(target._v_damage);
};
};
//==============================
// * Item Effect Recover HP
//==============================
var _alias_mog_btcry_gact_itemEffectRecoverHp = Game_Action.prototype.itemEffectRecoverHp;
Game_Action.prototype.itemEffectRecoverHp = function(target, effect) {
var old_hp = target.hp;
_alias_mog_btcry_gact_itemEffectRecoverHp.call(this,target, effect)
if (old_hp <= target.hp) {SoundManager.selectVoice(target._v_recover)};
};
// MOG_BattleCry.js
//=============================================================================
/*:
* @plugindesc (v1.3) Adiciona vozes na batalha.
* @author Moghunter
*
* @param Volume
* @desc Definição do volume.
* @default 120
*
* @help
* =============================================================================
* +++ MOG - Battle Cry (v1.3) +++
* By Moghunter
* https://atelierrgss.wordpress.com/
* =============================================================================
* Adiciona vozes na batalha (ação, dano, vitória,etc...)
* Para definir as vozes é necessário editar o plugin manualmente.
* A edição do plugin deve ser feita a partir da linha 70.
*
* =============================================================================
* HISTÓRICO
* =============================================================================
* (v1.3) Compatibilidade com MOG Battle Result.
* (v1.2) Compatibilidade com MOG Battle Transitions.
* (v1.1) Corrigido o bug de não mover o personagem na hora da ação.
*/
//=============================================================================
// ** PLUGIN PARAMETERS
//=============================================================================
// Não modifique essa parte.
// ☢CAUTION!!☢ Don't Touch.^_^ ----------------------------------------
var Imported = Imported || {};
Imported.MOG_BattleCry = true;
var Moghunter = Moghunter || {};
Moghunter.parameters = PluginManager.parameters('MOG_BattleCry');
Moghunter.v_volume = Number(Moghunter.parameters['Volume'] || 100);
Moghunter.v_actor_start = [];
Moghunter.v_actor_turn = [];
Moghunter.v_actor_default_action = [];
Moghunter.v_actor_skill = [];
Moghunter.v_actor_item = [];
Moghunter.v_actor_damage = [];
Moghunter.v_actor_evaded = [];
Moghunter.v_actor_dead = [];
Moghunter.v_actor_recover = [];
Moghunter.v_actor_counter = [];
Moghunter.v_actor_reflection = [];
Moghunter.v_actor_victory = [];
Moghunter.v_actor_levelup = [];
Moghunter.v_actor_escape = [];
Moghunter.v_enemy_default_action = [];
Moghunter.v_enemy_damage = [];
Moghunter.v_enemy_evaded = [];
Moghunter.v_enemy_counter = [];
Moghunter.v_enemy_reflection = [];
Moghunter.v_enemy_dead = [];
Moghunter.v_enemy_recover = [];
Moghunter.v_enemy_skill = [];
// ☢CAUTION!!☢ Don't Touch.^_^ ----------------------------------------
// SETUP ----------------------------------------------------------------
// Exemplo de configuração geral, o modo de configurar é igual para todas
// ações.
//
// Moghunter.v_actor_start[A] = [B,B,B,B...]
//
// A - Actor ID
// B - File Name
//
// -----------------------------------------------------------------------
// -----------------------------------------------------------------------
// ACTOR - BATTLE START
// -----------------------------------------------------------------------
Moghunter.v_actor_start[1] = ["Naruto a gente da conta [vocals]","naruto vou improvisar e vai dar certo","narutooq ta acontecendo aqui","naruto ja podemos começar","naruto (4)","naruto (9)","naruto (33)","naruto (46)","naruto (56)"];
Moghunter.v_actor_start[2] = ["naruto (25)"];
Moghunter.v_actor_start[3] = ["sasuke to de bom humor [vocals]","sasuke isso é uma bobeira","sasuke quero q lute agora","sasuke quero q lute comigo","sasuke vamos começar logo [vocals]","sasuke vou pegar pesado agora"];
Moghunter.v_actor_start[4] = ["Sakura cantarolando","Sakura eu acho q nos temos companhia [vocals]","Sakura O q realmente vcs querem","Sakura o que sao eles","Sakura oq querem aqui [vocals]","Sakura time 7 foi convocado vamos la [vocals]"];
// -----------------------------------------------------------------------
// ACTOR - BATTLE TURN
// -----------------------------------------------------------------------
Moghunter.v_actor_turn[1] = ["naruto (2)","naruto (3)","naruto (6)","naruto (9)","naruto (15)","naruto (25)","naruto (41)","naruto (51)","naruto (55)","naruto (56)"];
Moghunter.v_actor_turn[2] = ["naruto (25)"];
Moghunter.v_actor_turn[3] = ["sasuke entaao nossa luta continua [vocals]","sasuke eu disse que nao haveria mais conversa","sasuke isso é uma bobeira","sasuke o que é q vc quer [vocals]","sasuke precisamos fazer isso [vocals]","sasuke vamos começar logo [vocals]","sasuke vou pegar pesado agora"];
Moghunter.v_actor_turn[4] = ["sakura Com certeza","sakura entendido","sakura Espera um pouco","Sakura O q realmente vcs querem","Sakura o que sao eles","Sakura OQ esta acontecendo","Sakura oq querem aqui [vocals]","Sakura Parece que vamos conseguir","sakura preciso proteger esses dois [vocals]","Sakura Tem razão"];
Moghunter.v_actor_turn[0] = ["P1_Turn_01","P1_Turn_02"];
// -----------------------------------------------------------------------
// ACTOR - DEFAULT ACTION (Skill/ITEM)
// -----------------------------------------------------------------------
Moghunter.v_actor_default_action[1] = ["naruto (14)","naruto (15)","naruto (17)","naruto (16)","naruto (25)","naruto (26)","naruto (47)","naruto (55)","naruto (59)","naruto (67)","naruto (35)","naruto nem a pau"];
Moghunter.v_actor_default_action[2] = ["naruto (34)","naruto (25)","naruto (26)","naruto (37)","naruto (38)","naruto (36)"];
Moghunter.v_actor_default_action[3] = ["sasuke chega","sasuke cala a boca2 [vocals]","SASUKE gemido5","sasuke grunhido","sasuke gemido2 [vocals]"];
Moghunter.v_actor_default_action[4] = ["Sakura hey","Sakura grito [vocals]","Sakura ah vc! [vocals]","Sakura grito 3 [vocals]","Sakura vai nessa","Sakura vc quer brincar [vocals]","Sakura grito [vocals]"];
// -----------------------------------------------------------------------
// ACTOR - SKILL
// -----------------------------------------------------------------------
// Moghunter.v_actor_skill[A] = {B:[C,C,C,C,...] }
//
// A - Actor ID
// B - Skill ID
// C - File Name
// -----------------------------------------------------------------------
Moghunter.v_actor_skill[0] = {
3:["P1_Action_04","P1_Action_05","P1_Action_06"], //
8:["P1_Action_04","P1_Action_05","P1_Action_06"], //
9:["P1_Action_04","P1_Action_05","P1_Action_06"] //
};
Moghunter.v_actor_skill[0] = {
};
Moghunter.v_actor_skill[0] = {
10:["V_ACT2_SKILL_1"],
11:["V_ACT2_SKILL_9"],
15:["V_ACT2_SKILL_8"]
};
Moghunter.v_actor_skill[0] = {
23:["V_ACT3_SKILL_3","V_ACT3_SKILL_9"],
24:["V_ACT3_SKILL_3","V_ACT3_SKILL_9"],
25:["V_ACT3_SKILL_3","V_ACT3_SKILL_9"],
26:["V_ACT3_SKILL_3","V_ACT3_SKILL_9"]
};
// -----------------------------------------------------------------------
// ACTOR - DAMAGE
// -----------------------------------------------------------------------
Moghunter.v_actor_damage[1] = ["naruto (7)","naruto (8)","naruto (18)","naruto (21)","naruto (23)","naruto (26)","naruto (29)"];
Moghunter.v_actor_damage[2] = ["naruto (25)","naruto (26)"];
Moghunter.v_actor_damage[3] = ["sasuke gemido [vocals]","SASUKE gemido","sasuke gemido2 [vocals]","SASUKE gemido4","SASUKE gemido5","SASUKE gemido6","SASUKE gemido23","sasuke gemidos [vocals]","sasuke grunhido","sasukegemido3 [vocals]"];
Moghunter.v_actor_damage[4] = ["Sakura GEmido [vocals]","Sakura gemido 1","Sakura gemido","Sakura gemido3","Sakura gemidos2 [vocals]","Sakura gemidos3 [vocals]"];
Moghunter.v_actor_damage[0] = ["P1_Damage_01","P1_Damage_02"];
// -----------------------------------------------------------------------
// ACTOR - RECOVER
// -----------------------------------------------------------------------
Moghunter.v_actor_recover[1] = ["naruto (2)","naruto (3)","naruto (13)","naruto (31)","naruto (45)","naruto (52)","naruto (71)","naruto a gente da conta","naruto super legal hein [vocals]","naruto to de volta ao jogo","narutooq ta acontecendo aqui"];
Moghunter.v_actor_recover[2] = ["naruto (21)","naruto (25)"];
Moghunter.v_actor_recover[3] = ["sasuke vamos começar logo [vocals]","sasuke precisamos fazer isso [vocals]","sasuke eu nao vou perder de jeito nenhum [vocals]","sasuke chega","sasuke vou pegar pesado agora"];
Moghunter.v_actor_recover[4] = ["sakura pessoal [vocals]","sakura preciso proteger esses dois [vocals]","sakura rindo 2 [vocals]","Sakura sim obrigada [vocals]","Sakura vai nessa","sakura entendido"];
Moghunter.v_actor_recover[0] = ["P1_Recover_01","P1_Recover_02"];
// -----------------------------------------------------------------------
// ACTOR - DEAD
// -----------------------------------------------------------------------
Moghunter.v_actor_dead[1] = ["naruto (60)","naruto (20)","naruto (19)","naruto (60)","naruto (5)"];
Moghunter.v_actor_dead[2] = ["naruto (22)"];
Moghunter.v_actor_dead[3] = ["sasuke gemido [vocals]","SASUKE gemido","sasuke gemido2 [vocals]","SASUKE gemido4","SASUKE gemido5","SASUKE gemido6","SASUKE gemido23","sasuke gemidos [vocals]","sasuke grunhido","sasukegemido3 [vocals]"];
Moghunter.v_actor_dead[4] = ["Sakura GEmido [vocals]","Sakura gemido 1","Sakura gemido","Sakura gemido3","Sakura gemidos2 [vocals]","Sakura gemidos3 [vocals]"];
Moghunter.v_actor_dead[0] = ["P1_Dead_01"];
// -----------------------------------------------------------------------
// ACTOR - VICTORY
// -----------------------------------------------------------------------
Moghunter.v_actor_victory[1] = ["naruto (64)","naruto (10)","naruto (45)","naruto (73)","naruto (71)","naruto Um super ninja prox hokage"];
Moghunter.v_actor_victory[2] = ["naruto (19)","naruto (13)"];
Moghunter.v_actor_victory[3] = ["sasuke estamos no fim","sasuke nós ja terminamos a missao de hj eu to indo embora","sasuke vou restabelecer meu clan [vocals]"];
Moghunter.v_actor_victory[4] = ["sakuraE me tornei um pouco mais forte","Sakura time 7 foi convocado vamos la [vocals]","sakura rindo 2 [vocals]","Sakura nunca mais vou perder para vc [vocals]","Sakura eu consegui [vocals]","SAkura A pessoa que eu gosto é [vocals]"];
// -----------------------------------------------------------------------
// ACTOR - LEVEL UP
// -----------------------------------------------------------------------
Moghunter.v_actor_levelup[1] = ["naruto (64)","naruto (10)","naruto (45)","naruto (73)","naruto (71)","naruto Um super ninja prox hokage"];
Moghunter.v_actor_levelup[2] = ["naruto (19)"];
Moghunter.v_actor_levelup[3] = ["sasuke estamos no fim","sasuke nós ja terminamos a missao de hj eu to indo embora","sasuke vou restabelecer meu clan [vocals]"];
Moghunter.v_actor_levelup[4] = ["sakuraE me tornei um pouco mais forte","Sakura time 7 foi convocado vamos la [vocals]","sakura rindo 2 [vocals]","Sakura nunca mais vou perder para vc [vocals]","Sakura eu consegui [vocals]","SAkura A pessoa que eu gosto é [vocals]"];
// ACTOR - ESCAPE
// -----------------------------------------------------------------------
Moghunter.v_actor_escape[1] = ["naruto (74)","naruto (53)","naruto (52)","naruto (43)","naruto (28)","naruto (29)"];
Moghunter.v_actor_escape[2] = ["naruto (19)"];
Moghunter.v_actor_escape[3] = ["sasuke to fora disso"];
Moghunter.v_actor_escape[4] = ["sakura Profavor deixa a gente ir [vocals]"];
// -----------------------------------------------------------------------
// ACTOR - EVADED & MISS
// -----------------------------------------------------------------------
Moghunter.v_actor_evaded[1] = ["naruto (53)","naruto (47)","naruto (45)"];
Moghunter.v_actor_evaded[2] = ["naruto (45)"];
Moghunter.v_actor_evaded[3] = ["sasuke isso é uma bobeira","sasuke eu nao vou perder de jeito nenhum [vocals]","sasuke chega"];
Moghunter.v_actor_evaded[4] = ["Sakura vc quer brincar [vocals]","Sakura para com isso","Sakura idiota"];
// -----------------------------------------------------------------------
// ACTOR - COUNTER
// -----------------------------------------------------------------------
// ENEMY - DEFAULT ACTION
// -----------------------------------------------------------------------
Moghunter.v_enemy_default_action[900] = ["P1_Action_01","P1_Action_02","P1_Action_03"];
Moghunter.v_enemy_default_action[901] = ["P2_Action_01","P2_Action_02","P2_Action_03"];
// -----------------------------------------------------------------------
// ENEMY - SKILL
// -----------------------------------------------------------------------
Moghunter.v_enemy_skill[7] = {
34:["Cel_Attack_02","Cel_Attack_08"],
35:["Cel_Attack_01"],
36:["Cel_Attack_03"],
39:["Cel_Attack_04"]
};
Moghunter.v_enemy_skill[901] = {1:["P2_Action_04","P2_Action_05","P2_Action_06"]};
// -----------------------------------------------------------------------
// ENEMY - DAMAGE
// -----------------------------------------------------------------------
Moghunter.v_enemy_damage[7] = ["Cel_Damage1","Cel_Damage2"];
Moghunter.v_enemy_damage[901] = ["P2_Damage_01","P2_Damage_02","P2_Damage_03"];
// -----------------------------------------------------------------------
// ENEMY - EVADED & MISS
// -----------------------------------------------------------------------
Moghunter.v_enemy_evaded[900] = ["P1_Evade_01"];
Moghunter.v_enemy_evaded[901] = ["P1_Evade_01"];
// -----------------------------------------------------------------------
// ENEMY - COUNTER
// -----------------------------------------------------------------------
Moghunter.v_enemy_counter[900] = ["P1_Counter_01"];
Moghunter.v_enemy_counter[901] = ["P2_Counter_01"];
// -----------------------------------------------------------------------
// ENEMY - REFLECTION
// -----------------------------------------------------------------------
Moghunter.v_enemy_reflection[900] = ["P1_Reflection_01"];
Moghunter.v_enemy_reflection[901] = ["P2_Reflection_01"];
// -----------------------------------------------------------------------
// ENEMY - RECOVER
// -----------------------------------------------------------------------
Moghunter.v_enemy_recover[900] = ["P1_Recover_01","P1_Recover_02"];
Moghunter.v_enemy_recover[901] = ["P2_Recover_01","P2_Recover_02"];
// -----------------------------------------------------------------------
// ENEMY - DEAD
// -----------------------------------------------------------------------
Moghunter.v_enemy_dead[900] = ["P1_Dead_01","P1_Dead_02"];
Moghunter.v_enemy_dead[901] = ["P2_Dead_01"];
//=============================================================================
// ** Sound Manager
//=============================================================================
//==============================
// * select Voice
//==============================
SoundManager.selectVoice = function(voices){
if (!voices) {return};
if (voices.length === 0) {return};
var voiceIndex = Math.randomInt(voices.length);
var fileName = voices[voiceIndex];
this.playVoice(fileName);
};
//==============================
// * Play Voice
//==============================
SoundManager.playVoice = function(fileName){
var se = {};
se.name = fileName;
se.pitch = 100;
se.volume = Moghunter.v_volume;
AudioManager.playSe(se);
};
//=============================================================================
// ** BattleManager
//=============================================================================
//================================
// ** Random Actor
//================================
BattleManager.randomActor = function() {
var actorIndex = Math.randomInt($gameParty.aliveMembers().length);
return $gameParty.aliveMembers()[actorIndex];
};
//==================================
// ** Start Battle
//==================================
var _alias_mog_bmngr_startBattle = BattleManager.startBattle;
BattleManager.startBattle = function() {
_alias_mog_bmngr_startBattle.call(this);
if (!Imported.MOG_BattleTransitions ||
(Imported.MOG_BattleTransitions && $gameSystem._treType[1] === -1)) {
var actor = this.randomActor();
if (actor) {SoundManager.selectVoice(actor._v_start)};
};
};
//==================================
// ** Process Victory
//==================================
var _alias_mog_bcry_processVictory = BattleManager.processVictory;
BattleManager.processVictory = function() {
var actor = this.randomActor();
if (actor) {SoundManager.selectVoice(actor._v_victory)};
_alias_mog_bcry_processVictory.call(this);
};
//==================================
// ** Process Escape
//==================================
var _alias_mog_bcry_processEscape = BattleManager.processEscape;
BattleManager.processEscape = function() {
var actor = this.randomActor();
if (actor) {SoundManager.selectVoice(actor._v_escape)};
_alias_mog_bcry_processEscape.call(this);
};
//=============================================================================
// ** Game Battler
//=============================================================================
//==============================
// * InitMembers
//==============================
var _alias_mog_batcry_gbattler_initMembers = Game_Battler.prototype.initMembers;
Game_Battler.prototype.initMembers = function() {
_alias_mog_batcry_gbattler_initMembers.call(this);
this.battleCrySetup();
};
//==============================
// * Battle Cry Setup
//==============================
Game_Battler.prototype.battleCrySetup = function() {
this._v_start = [];
this._v_turn = [];
this._v_default_action = [];
this._v_damage = [];
this._v_evaded = [];
this._v_counter = [];
this._v_reflection = [];
this._v_dead = [];
this._v_recover = [];
this._v_escape = [];
this._v_victory = [];
this._v_levelup = [];
};
//==============================
// * Battle Cry Setup Actor
//==============================
Game_Battler.prototype.battleCrySetupActor = function() {
if (Moghunter.v_actor_start[this._actorId]) {this._v_start = Moghunter.v_actor_start[this._actorId]};
if (Moghunter.v_actor_turn[this._actorId]) {this._v_turn = Moghunter.v_actor_turn[this._actorId]};
if (Moghunter.v_actor_default_action[this._actorId]) {
this._v_default_action = Moghunter.v_actor_default_action[this._actorId]};
if (Moghunter.v_actor_damage[this._actorId]) {this._v_damage = Moghunter.v_actor_damage[this._actorId]};
if (Moghunter.v_actor_evaded[this._actorId]) {this._v_evaded = Moghunter.v_actor_evaded[this._actorId]};
if (Moghunter.v_actor_counter[this._actorId]) {this._v_counter = Moghunter.v_actor_counter[this._actorId]};
if (Moghunter.v_actor_reflection[this._actorId]) {this._v_reflection = Moghunter.v_actor_reflection[this._actorId]};
if (Moghunter.v_actor_dead[this._actorId]) {this._v_dead = Moghunter.v_actor_dead[this._actorId]};
if (Moghunter.v_actor_recover[this._actorId]) {this._v_recover = Moghunter.v_actor_recover[this._actorId]};
if (Moghunter.v_actor_escape[this._actorId]) {this._v_escape = Moghunter.v_actor_escape[this._actorId]};
if (Moghunter.v_actor_victory[this._actorId]) {this._v_victory = Moghunter.v_actor_victory[this._actorId]};
if (Moghunter.v_actor_levelup[this._actorId]) {this._v_levelup = Moghunter.v_actor_levelup[this._actorId]};
};
//==============================
// * Battle Cry Setup Enemy
//==============================
Game_Battler.prototype.battleCrySetupEnemy = function() {
if (Moghunter.v_enemy_default_action[this._enemyId]) {
this._v_default_action = Moghunter.v_enemy_default_action[this._enemyId]};
if (Moghunter.v_enemy_damage[this._enemyId]) {this._v_damage = Moghunter.v_enemy_damage[this._enemyId]};
if (Moghunter.v_enemy_evaded[this._enemyId]) {this._v_evaded = Moghunter.v_enemy_evaded[this._enemyId]};
if (Moghunter.v_enemy_counter[this._enemyId]) {this._v_counter = Moghunter.v_enemy_counter[this._enemyId]};
if (Moghunter.v_enemy_reflection[this._enemyId]) {this._v_reflection = Moghunter.v_enemy_reflection[this._enemyId]};
if (Moghunter.v_enemy_dead[this._enemyId]) {this._v_dead = Moghunter.v_enemy_dead[this._enemyId]};
if (Moghunter.v_enemy_recover[this._enemyId]) {this._v_recover = Moghunter.v_enemy_recover[this._enemyId]};
};
//===============================
// ** PerfotmAction
//===============================
var _alias_mog_bcry_performActionStart = Game_Battler.prototype.performActionStart;
Game_Battler.prototype.performActionStart = function(action) {
if (action) {this.playVoiceAction(action)};
_alias_mog_bcry_performActionStart.call(this, action);
};
//===============================
// ** play Voice Action
//===============================
Game_Battler.prototype.playVoiceAction = function(action) {
var actionID = action.item().id
if (this.isActor()) {
if (action.isSkill() && Moghunter.v_actor_skill[this._actorId] &&
Moghunter.v_actor_skill[this._actorId][actionID]) {
SoundManager.selectVoice(Moghunter.v_actor_skill[this._actorId][actionID]);
return;
} else if (action.isItem() && Moghunter.v_actor_item[this._actorId] &&
Moghunter.v_actor_item[this._actorId][actionID]) {
SoundManager.selectVoice(Moghunter.v_actor_item[this._actorId][actionID]);
return;
};
} else if (this.isEnemy()) {
if (Moghunter.v_enemy_skill[this._enemyId] && Moghunter.v_enemy_skill[this._enemyId][actionID]) {
SoundManager.selectVoice(Moghunter.v_enemy_skill[this._enemyId][actionID]);
return;
};
};
SoundManager.selectVoice(this._v_default_action);
};
//==============================
// ** perform Counter
//==============================
var _mog_btcry_gbat_performCounter = Game_Battler.prototype.performCounter;
Game_Battler.prototype.performCounter = function() {
_mog_btcry_gbat_performCounter.call(this);
SoundManager.selectVoice(this._v_counter);
};
//==============================
// ** perform Reflection
//==============================
var _mog_btcry_gbat_performReflection = Game_Battler.prototype.performReflection;
Game_Battler.prototype.performReflection = function() {
_mog_btcry_gbat_performReflection.call(this);
SoundManager.selectVoice(this._v_reflection);
};
//=============================================================================
// ** Game Actor
//=============================================================================
//==============================
// * Setup
//==============================
var _mog_bcry_gact_setup = Game_Actor.prototype.setup;
Game_Actor.prototype.setup = function(actorId) {
_mog_bcry_gact_setup.call(this,actorId);
this.battleCrySetupActor();
};
//=============================================================================
// ** Game Enemy
//=============================================================================
//==============================
// * Setup
//==============================
var _mog_bcry_gemy_setup = Game_Enemy.prototype.setup;
Game_Enemy.prototype.setup = function(enemyId, x, y) {
_mog_bcry_gemy_setup.call(this,enemyId, x, y);
this.battleCrySetupEnemy();
};
//=============================================================================
// ** Scene Battle
//=============================================================================
//==============================
// * select Voice
//==============================
var _alias_mog_bcry_scbat_start = Scene_Battle.prototype.start;
Scene_Battle.prototype.start = function() {
_alias_mog_bcry_scbat_start.call(this);
this._actorvoice = null;
};
//==============================
// * Update Battle Process
//==============================
var _alias_mog_bcry_updateBattleProcess = Scene_Battle.prototype.updateBattleProcess;
Scene_Battle.prototype.updateBattleProcess = function() {
if (this._actorvoice != BattleManager.actor()) {this.playActorTurn()};
_alias_mog_bcry_updateBattleProcess.call(this);
};
//==============================
// * Play Actor Turn
//==============================
Scene_Battle.prototype.playActorTurn = function() {
this._actorvoice = BattleManager.actor();
if (this._actorvoice) {AudioManager.stopSe();
SoundManager.selectVoice(this._actorvoice._v_turn)};
};
//=============================================================================
// ** Game Action
//=============================================================================
//==============================
// * Apply
//==============================
var _alias_mog_bcry_gaction_apply = Game_Action.prototype.apply;
Game_Action.prototype.apply = function(target) {
var old_hp = target.hp
_alias_mog_bcry_gaction_apply.call(this,target);
if (old_hp != target.hp || this.item().damage.type === 3) {this.playVoiceHP(old_hp,target.hp,target)};
if (target.result().missed || target.result().evaded) {SoundManager.selectVoice(target._v_evaded)};
};
//==============================
// * Play Voice HP
//==============================
Game_Action.prototype.playVoiceHP = function(old_hp,now_hp,target) {
if (target.isDead()) {
SoundManager.selectVoice(target._v_dead);
} else if (old_hp < now_hp || this.item().damage.type === 3) {
SoundManager.selectVoice(target._v_recover);
} else if (old_hp > now_hp) {
SoundManager.selectVoice(target._v_damage);
};
};
//==============================
// * Item Effect Recover HP
//==============================
var _alias_mog_btcry_gact_itemEffectRecoverHp = Game_Action.prototype.itemEffectRecoverHp;
Game_Action.prototype.itemEffectRecoverHp = function(target, effect) {
var old_hp = target.hp;
_alias_mog_btcry_gact_itemEffectRecoverHp.call(this,target, effect)
if (old_hp <= target.hp) {SoundManager.selectVoice(target._v_recover)};
};