Пример #1
0
        public override void OnEnter()
        {
            this.hitboxName = "Sword";

            this.damageType        = DamageType.Generic;
            this.damageCoefficient = 3.8f;
            this.procCoefficient   = 1f;
            this.pushForce         = 300f;
            this.bonusForce        = Vector3.zero;
            this.baseDuration      = 1f;
            this.attackStartTime   = 0.2f;
            this.attackEndTime     = 0.4f;
            this.baseEarlyExitTime = 0.4f;
            this.hitStopDuration   = 0.012f;
            this.attackRecoil      = 0.5f;
            this.hitHopVelocity    = 4f;

            this.swingSoundString  = "NemrySwordSwing";
            this.hitSoundString    = "";
            this.muzzleString      = swingIndex % 2 == 0 ? "SwingLeft" : "SwingRight";
            this.swingEffectPrefab = Modules.Assets.nemSwordSwingEffect;
            this.hitEffectPrefab   = Modules.Assets.nemSwordHitImpactEffect;

            this.impactSound = Modules.Assets.nemSwordHitSoundEvent.index;

            base.OnEnter();

            this.energyComponent = base.GetComponent <NemryEnergyComponent>();
        }
Пример #2
0
        public override void OnEnter()
        {
            this.hitboxName = "Sword";

            this.damageType        = DamageType.PoisonOnHit;
            this.damageCoefficient = 28f;
            this.procCoefficient   = 1f;
            this.pushForce         = -500f;
            this.baseDuration      = 0.6f;
            this.attackStartTime   = 0.8f;
            this.attackEndTime     = 0.95f;
            this.baseEarlyExitTime = 0f;
            this.hitStopDuration   = 0.03f;
            this.attackRecoil      = 2.5f;
            this.hitHopVelocity    = 8f;

            this.swingSoundString  = "NemrySwordSwing";
            this.hitSoundString    = "";
            this.muzzleString      = "SwingCenter";
            this.swingEffectPrefab = Modules.Assets.nemSwordStabSwingEffect;
            this.hitEffectPrefab   = Modules.Assets.nemSwordHitImpactEffect;

            this.impactSound = Modules.Assets.nemSwordHitSoundEvent.index;

            base.OnEnter();

            NemryEnergyComponent energyComponent = base.GetComponent <NemryEnergyComponent>();

            if (energyComponent)
            {
                energyComponent.SpendEnergy(100f, SkillSlot.Special);
            }
        }
Пример #3
0
 public override void OnEnter()
 {
     this.energyComponent = base.GetComponent <NemryEnergyComponent>();
     this.tracker         = base.GetComponent <HenryTracker>();
     base.OnEnter();
 }
Пример #4
0
        private static bool HasSufficientEnergy([NotNull] GenericSkill skillSlot)
        {
            NemryEnergyComponent energyComponent = ((NemryEnergySkillDef.InstanceData)skillSlot.skillInstanceData).energyComponent;

            return((energyComponent != null) ? (energyComponent.currentEnergy >= skillSlot.rechargeStock) : false);
        }