Example #1
0
        public override void Init(BasePet pet, PetAtkState controller)
        {
            base.Init(pet, controller);
            m_AtkTimes = AtkTimes;
            ItemItem          weaponItem      = Global.gApp.gGameData.GetItemDataByName(GameConstVal.WDeadthWalker);
            GunsPass_dataItem weaponLevelData = Global.gApp.CurScene.GetGunPassDataItem();
            double            atk             = weaponLevelData.DeathWalker[(int)MWeapon.Atk];


            int curLv = Global.gApp.gSystemMgr.GetWeaponMgr().GetWeaponLevel(GameConstVal.WDeadthWalker);
            GunsSub_dataItem levelItem = Global.gApp.gGameData.GunSubDataConfig.Get(curLv);

            double[] weaponParams = ReflectionUtil.GetValueByProperty <GunsSub_dataItem, double[]>("base_params_" + weaponItem.qualevel, levelItem);

            float campAtkInc = Global.gApp.CurScene.GetMainPlayerComp().GetBuffMgr().CampPetIncAtk;

            m_Damage = atk * AtkParam * weaponParams[0] * (1 + campAtkInc);

            m_DtTime             = weaponItem.dtime + m_AnimTime;
            m_LockTools          = new PetLockDisTools(transform, pet);
            m_LockTools.MaxRadio = 1;
            m_LockTools.MinRadio = 1;
            m_LockTools.BreakDis = BreakDis;
            m_LockTools.SetBreakCall(BreakCall);
        }
Example #2
0
 public override void Init(BasePet pet, PetAtkState controller)
 {
     base.Init(pet, controller);
     m_UAVGun.Init(null);
     m_UAVGun.enabled     = false;
     m_LockTools          = new PetLockDisTools(transform, pet);
     m_LockTools.MaxRadio = 1;
     m_LockTools.MinRadio = 1;
     m_LockTools.BreakDis = BreakDis;
     m_LockTools.SetBreakCall(BreakCall);
 }
Example #3
0
 public override void Init(BasePet pet, PetAtkState controller)
 {
     base.Init(pet, controller);
     m_DogGun.SetDogPet((pet as DogPet));
     m_DogGun.Init(null);
     m_DogGun.enabled     = false;
     m_PursureCallBack    = PursueCallBack;
     m_LockTools          = new PetLockDisTools(transform, pet);
     m_LockTools.MaxRadio = 1;
     m_LockTools.MinRadio = 1;
     m_LockTools.BreakDis = BreakDis;
     m_LockTools.SetBreakCall(BreakCall);
 }
Example #4
0
 public virtual void Init(BasePet pet, PetAtkState controller)
 {
     m_Pet        = pet;
     m_Controller = controller;
 }