BattleManagerTest.cs 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. using UnityEngine;
  2. using System.Collections;
  3. using System.Collections.Generic;
  4. using System;
  5. namespace YLBattle
  6. {
  7. public partial class BattleManager : IBattleGlobalOper
  8. {
  9. #region 测试
  10. /// <summary>
  11. /// 修改数值
  12. /// </summary>
  13. /// <param name="who"></param>
  14. /// <param name="hp"></param>
  15. public void TestModifyBattleResult(bool _bol)
  16. {
  17. EBattleTeam trgTeam = _bol ? EBattleTeam.REDTEAM : EBattleTeam.BLUETEAM;
  18. List<LogicFighter> fighters = this.Env().mLogicFighterOper.FindTeamAliveFighter(trgTeam);
  19. foreach (LogicFighter child in fighters)
  20. {
  21. child.SetProperty(EBattleProperty.HP, -1 * child.GetProperty(EBattleProperty.HPMAX));
  22. }
  23. }
  24. /// <summary>
  25. /// 修改数值
  26. /// </summary>
  27. /// <param name="who"></param>
  28. /// <param name="hp"></param>
  29. public void TestModifyPower(string who)
  30. {
  31. LogicFighter fighter = this.Env().mLogicFighterOper.FindFighter(who);
  32. if (fighter == null)
  33. {
  34. return;
  35. }
  36. fighter.ModifyProperty(EBattleProperty.NPOWER, fighter.GetProperty(EBattleProperty.NMAXPOWER));
  37. }
  38. /// <summary>
  39. ///
  40. /// </summary>
  41. /// <param name="who"></param>
  42. /// <param name="skilltid"></param>
  43. public void TestCastSkill(string who, string skilltid)
  44. {
  45. //this.mBulletModel.OnCastSkill(who, skilltid);
  46. }
  47. #endregion
  48. }
  49. }