- //============================================================================= 
- // NTJ_ChangeBaseSkill.js 
- //============================================================================= 
-   
- /*: 
- * @plugindesc 通过注释更换 攻击 和 防护的技能id。 
- *  牛头牛头牛头菌 
- * @author yorlbgy 
- * 
- * @help 更换基本技能: 
- 1、在武器/角色/职业  注释上写<aSkillId: 技能id> 如<aSkillId: 3> 更换普通攻击的技能 
-    在盾牌/武器/角色/职业  注释上写<gSkillId: 技能id> 如<gSkillId: 3> 更换防护的技能 
-   
- 2、在角色和职业上面还可以根据武器类型来分别定义 
- <aSkillIdWith武器类型id: 技能id>  <aSkillIdWith2: 3> 如果装备的是剑就会用技能3作为普通攻击。 
- <gSkillIdWith武器类型id: 技能id>  同上。 
- 注意:不要再with和武器类型id之间加空格! 
-   
- 3、bug?:我乡下人不会玩,所以插件还有些问题 
-         1在横板战斗里面,角色的动作有点问题(我还不会改,以后再改吧。 
-         2由于没有做逃跑的处理,所以请不要把技能改成逃跑这类特别的技能。 
-   
- 4、优先级说明:在多个条件满足的时候,优先级如下 
-         攻击:武器  > 角色武器类型指定 > 角色 > 职业武器类型指定 > 职业 
-         防护:盾牌 > 武器  > 角色武器类型指定 > 角色 > 职业武器类型指定 > 职业 
- 5、武器类型:参考武器类型列表 
-         0:无 
-         1:匕首 
-         2:剑 
-         3:链枷 
-         4:斧 
-         5:鞭 
-         6:杖 
-         7:弓 
-         8:弩 
-         9:枪 
-         10:爪 
-         11:手套 
-         12:矛 
- */  
- (function() { 
-   
-   
-   
-                 var _Game_ActorattackSkillId = Game_Actor.prototype.attackSkillId; 
-   
-                 if(!_Game_ActorattackSkillId){ 
-                         _Game_ActorattackSkillId = function(){ 
-                                 return 1; 
-                         } 
-                 } 
-   
-                 var My_Game_ActorattackSkillIdStr = function(){ 
-   
-                         if(!this.hasNoWeapons()){ 
-                                 for(var i = 0;i<this.weapons().length;i++){ 
-                                         var weaponAttackId = this.weapons()[i].meta.aSkillId; 
-                                         if(weaponAttackId){ 
-                                                 return weaponAttackId; 
-                                         } 
-                                 } 
-   
-                                 var actorWeaponAttackId = this.actor().meta["aSkillIdWith"+this.weapons()[0].wtypeId]; 
-                                 if(actorWeaponAttackId){ 
-                                         return actorWeaponAttackId; 
-                                 } 
-   
-   
-                         } 
-   
-                         var actorAttackId = this.actor().meta.aSkillId; 
-                         if(actorAttackId){ 
-                                 return actorAttackId; 
-                         } 
-   
-                         if(!this.hasNoWeapons()){ 
-                                 var classWeaponAttackId = this.currentClass().meta["aSkillIdWith"+this.weapons()[0].wtypeId]; 
-                                         if(classWeaponAttackId){ 
-                                                 return classWeaponAttackId; 
-                                         } 
-                         } 
-   
-                         var classAttackId = this.currentClass().meta.aSkillId; 
-                         if(classAttackId){ 
-                                 return classAttackId; 
-                         } 
-   
-                         var result = _Game_ActorattackSkillId.call(this); 
-                     return result; 
-   
-                 }; 
-   
-                 Game_Actor.prototype.attackSkillId = function(){ 
-                         var result =  My_Game_ActorattackSkillIdStr.call(this); 
-                         if(!result) { 
-                                 return 1; 
-                         } 
-                         return Number(result); 
-                 } 
-   
-   
-   
-   
-                 var _Game_ActorguardSkillId = Game_Actor.prototype.guardSkillId; 
-   
-   
-                 if(!_Game_ActorguardSkillId){ 
-                         _Game_ActorguardSkillId = function(){ 
-                                 return 2; 
-                         } 
-                 } 
-   
-                 var My_Game_ActorguardSkillId = function(){ 
-                         for(var i=0;i<this.armors().length;i++){ 
-                                 var shield = this.armors()[i];         
-                                 if(shield.etypeId == 2){ 
-                                         var guardSkillId = shield.meta.gSkillId; 
-                                         if(guardSkillId){ 
-                                                 return guardSkillId; 
-                                         } 
-                                 } 
-                         } 
-   
-                         if(!this.hasNoWeapons()){ 
-                                 for(var i = 0;i<this.weapons().length;i++){ 
-                                         var weaponGuardId = this.weapons()[i].meta.gSkillId; 
-                                         if(weaponGuardId){ 
-                                                 return weaponGuardId; 
-                                         } 
-                                 } 
-   
-                                 var actorWeaponGuardId = this.actor().meta["gSkillIdWith"+this.weapons()[0].wtypeId]; 
-                                 if(actorWeaponGuardId){ 
-                                         return actorWeaponGuardId; 
-                                 } 
-   
-   
-                         } 
-   
-   
-   
-                         var actorGuardId = this.actor().meta.gSkillId; 
-                         if(actorGuardId){ 
-                                 return actorGuardId; 
-                         } 
-   
-                         if(!this.hasNoWeapons()){ 
-                                 var classWeaponGuardId = this.currentClass().meta["gSkillIdWith"+this.weapons()[0].wtypeId]; 
-                                 if(classWeaponGuardId){ 
-                                         return classWeaponGuardId; 
-                                 } 
-                         } 
-   
-                         var classGuardId = this.currentClass().meta.gSkillId; 
-                         if(classGuardId){ 
-                                 return classGuardId; 
-                         } 
-   
-                         var result = _Game_ActorguardSkillId.call(this); 
-                         return result; 
-                 } 
-   
-   
-   
-                 Game_Actor.prototype.guardSkillId = function(){ 
-                         var result = My_Game_ActorguardSkillId.call(this); 
-                         if(!result){ 
-                                 return 2; 
-                         } 
-                         return Number(result); 
-                 }; 
-   
- })();