Exemplo n.º 1
0
 public override void OnDamage(AttackedHitStatusFix status, Character to_obj)
 {
     if (!(to_obj as Enemy == null) && status.reactionType == 7)
     {
         downCount++;
     }
 }
Exemplo n.º 2
0
 public override void OnDamage(AttackedHitStatusFix status, Character to_obj)
 {
     if (!(status.fromObject as Self == null) && status.damage >= missionParam)
     {
         isOver = true;
     }
 }
Exemplo n.º 3
0
 public override void OnDamage(AttackedHitStatusFix status, Character to_obj)
 {
     if (!(to_obj as Self == null) && (status.badStatusTotal.paralyze > 0f || status.badStatusTotal.poison > 0f || status.badStatusTotal.burning > 0f || status.badStatusTotal.speedDown > 0f || status.badStatusTotal.attackSpeedDown > 0f))
     {
         badStatusCount++;
     }
 }
    public void CopyAttackedHitStatus(out AttackedHitStatusFix status)
    {
        //IL_0090: Unknown result type (might be due to invalid IL or missing references)
        //IL_0095: Unknown result type (might be due to invalid IL or missing references)
        //IL_0130: Unknown result type (might be due to invalid IL or missing references)
        //IL_0135: Unknown result type (might be due to invalid IL or missing references)
        //IL_0184: Unknown result type (might be due to invalid IL or missing references)
        //IL_0189: Unknown result type (might be due to invalid IL or missing references)
        AttackedHitStatus attackedHitStatus = new AttackedHitStatus();

        attackedHitStatus.fromObjectID = fromObjectID;
        attackedHitStatus.fromObject   = MonoBehaviourSingleton <StageObjectManager> .I.FindCharacter(fromObjectID);

        if (attackedHitStatus.fromObject != null && !attackedHitStatus.fromObject.isLoading)
        {
            attackedHitStatus.attackInfo = (attackedHitStatus.fromObject.FindAttackInfoExternal(attackInfoName, true, attackInfoRate) as AttackHitInfo);
        }
        if (attackedHitStatus.attackInfo == null)
        {
            attackedHitStatus.attackInfo = new AttackHitInfo();
        }
        attackedHitStatus.fromType     = (StageObject.OBJECT_TYPE)fromType;
        attackedHitStatus.hitPos       = hitPos;
        attackedHitStatus.fromClientID = fromClientID;
        if (attackedHitStatus.fromObject != null)
        {
            attackedHitStatus.skillParam = attackedHitStatus.fromObject.GetSkillParam(skillIndex);
        }
        attackedHitStatus.regionID         = regionID;
        attackedHitStatus.weakState        = (Enemy.WEAK_STATE)weakState;
        attackedHitStatus.damage           = damage;
        attackedHitStatus.downAddBase      = downAddBase;
        attackedHitStatus.downAddWeak      = downAddWeak;
        attackedHitStatus.isArrowBleed     = isArrowBleed;
        attackedHitStatus.arrowBleedDamage = arrowBleedDamage;
        attackedHitStatus.arrowBurstDamage = arrowBurstDamage;
        attackedHitStatus.hostPos          = hostPos;
        attackedHitStatus.hostDir          = hostDir;
        attackedHitStatus.afterHP          = afterHP;
        attackedHitStatus.afterRegionHP    = afterRegionHP;
        attackedHitStatus.afterHealHp      = afterHealHp;
        attackedHitStatus.breakRegion      = breakRegion;
        attackedHitStatus.reactionType     = reactionType;
        attackedHitStatus.blowForce        = blowForce;
        attackedHitStatus.downTotal        = downTotal;
        attackedHitStatus.badStatusTotal.Copy(badStatusTotal);
        attackedHitStatus.damageHpRate        = damageHpRate;
        attackedHitStatus.arrowBleedSkipFirst = arrowBleedSkipFirst;
        attackedHitStatus.isSpAttackHit       = isSpAttackHit;
        attackedHitStatus.barrierHp           = afterRegionBarrierHp;
        attackedHitStatus.damageDetails       = damageDetails;
        attackedHitStatus.shieldHp            = afterShieldHp;
        attackedHitStatus.grabHp          = afterGrabHp;
        attackedHitStatus.isShadowSealing = isShadowSealing;
        attackedHitStatus.aegisParam.Copy(aegisParam);
        status = new AttackedHitStatusFix(attackedHitStatus);
    }
Exemplo n.º 5
0
    public virtual void OnAttackedHit(AttackHitInfo info, AttackHitColliderProcessor.HitParam hit_param)
    {
        //IL_0049: Unknown result type (might be due to invalid IL or missing references)
        //IL_004e: Unknown result type (might be due to invalid IL or missing references)
        //IL_0055: Unknown result type (might be due to invalid IL or missing references)
        //IL_005a: Unknown result type (might be due to invalid IL or missing references)
        //IL_009d: Unknown result type (might be due to invalid IL or missing references)
        //IL_00a2: Unknown result type (might be due to invalid IL or missing references)
        AttackedHitStatus attackedHitStatus = new AttackedHitStatus();

        attackedHitStatus.hitParam           = hit_param;
        attackedHitStatus.attackInfo         = info;
        attackedHitStatus.fromObjectID       = hit_param.fromObject.id;
        attackedHitStatus.fromObject         = hit_param.fromObject;
        attackedHitStatus.fromType           = hit_param.fromObject.objectType;
        attackedHitStatus.fromPos            = hit_param.fromObject._position;
        attackedHitStatus.hitPos             = hit_param.point;
        attackedHitStatus.distanceXZ         = hit_param.distanceXZ;
        attackedHitStatus.hitTime            = hit_param.time;
        attackedHitStatus.isSpAttackHit      = hit_param.isSpAttackHit;
        attackedHitStatus.attackMode         = hit_param.attackMode;
        attackedHitStatus.damageDistanceData = hit_param.damageDistanceData;
        attackedHitStatus.exHitPos           = hit_param.exHitPos;
        nowAttackedHitStatus = attackedHitStatus;
        if (MonoBehaviourSingleton <CoopManager> .IsValid())
        {
            attackedHitStatus.fromClientID = MonoBehaviourSingleton <CoopManager> .I.coopMyClient.clientId;
        }
        if (attackedHitStatus.fromType == OBJECT_TYPE.SELF)
        {
            attackedHitStatus.fromType = OBJECT_TYPE.PLAYER;
        }
        OnAttackedHitDirection(new AttackedHitStatusDirection(attackedHitStatus));
        if (IsValidAttackedHit(hit_param.fromObject) && !IsPuppet() && !hit_param.fromObject.IsPuppet())
        {
            OnAttackedHitLocal(new AttackedHitStatusLocal(attackedHitStatus));
            if (IsMirror() || IsPuppet())
            {
                if (packetSender != null)
                {
                    packetSender.OnAttackedHitOwner(new AttackedHitStatusOwner(attackedHitStatus));
                }
            }
            else if (IsEnableAttackedHitOwner())
            {
                OnAttackedHitOwner(new AttackedHitStatusOwner(attackedHitStatus));
                AttackedHitStatusFix status = new AttackedHitStatusFix(attackedHitStatus);
                OnAttackedHitFix(status);
                if (packetSender != null)
                {
                    packetSender.OnAttackedHitFix(status);
                }
            }
        }
    }
Exemplo n.º 6
0
 public override void OnAttackedHitFix(AttackedHitStatusFix status)
 {
     //IL_0026: Unknown result type (might be due to invalid IL or missing references)
     //IL_002c: Unknown result type (might be due to invalid IL or missing references)
     //IL_0038: Unknown result type (might be due to invalid IL or missing references)
     base.OnAttackedHitFix(status);
     if (status.damage > 0 && status.fromType == OBJECT_TYPE.ENEMY)
     {
         EffectManager.OneShot(breakEffectName, _position, _rotation, false);
         this.get_gameObject().SetActive(false);
     }
 }
Exemplo n.º 7
0
 public void Add(Character to_chara, AttackedHitStatusFix status)
 {
     if (!to_chara.isDead && MonoBehaviourSingleton <CoopManager> .I.isStageHost)
     {
         int skill_id = 0;
         if (status.skillParam != null)
         {
             skill_id = status.skillParam.baseInfo.id;
         }
         int damage = status.damage;
         Add(to_chara, status.fromObjectID, skill_id, status.attackInfo.name, damage);
     }
 }
Exemplo n.º 8
0
 public virtual void OnAttackedHitFix(AttackedHitStatusFix status)
 {
     if (enableSend && owner.IsOriginal())
     {
         bool flag = false;
         if (status.afterHP <= 0)
         {
             flag = true;
         }
         if (status.breakRegion)
         {
             flag = true;
         }
         Coop_Model_ObjectAttackedHitFix coop_Model_ObjectAttackedHitFix = new Coop_Model_ObjectAttackedHitFix();
         coop_Model_ObjectAttackedHitFix.id = owner.id;
         coop_Model_ObjectAttackedHitFix.SetAttackedHitStatus(status);
         if (flag)
         {
             SendBroadcast(coop_Model_ObjectAttackedHitFix, true, null, delegate(Coop_Model_Base send_model)
             {
                 if (owner == null)
                 {
                     return(false);
                 }
                 Coop_Model_ObjectAttackedHitFix coop_Model_ObjectAttackedHitFix2 = send_model as Coop_Model_ObjectAttackedHitFix;
                 Character character = owner as Character;
                 if (character != null)
                 {
                     coop_Model_ObjectAttackedHitFix2.afterHP = character.hp;
                     Player player = owner as Player;
                     if (player != null)
                     {
                         coop_Model_ObjectAttackedHitFix2.afterHealHp = player.healHp;
                     }
                     if (coop_Model_ObjectAttackedHitFix2.afterHP > 0 && coop_Model_ObjectAttackedHitFix2.reactionType == 8)
                     {
                         coop_Model_ObjectAttackedHitFix2.reactionType = 0;
                     }
                 }
                 return(true);
             });
         }
         else
         {
             SendBroadcast(coop_Model_ObjectAttackedHitFix, false, null, null);
         }
     }
 }
 public void SetAttackedHitStatus(AttackedHitStatusFix status)
 {
     //IL_003c: Unknown result type (might be due to invalid IL or missing references)
     //IL_0041: Unknown result type (might be due to invalid IL or missing references)
     //IL_00d0: Unknown result type (might be due to invalid IL or missing references)
     //IL_00d5: Unknown result type (might be due to invalid IL or missing references)
     //IL_0124: Unknown result type (might be due to invalid IL or missing references)
     //IL_0129: Unknown result type (might be due to invalid IL or missing references)
     attackInfoName = status.attackInfo.name;
     attackInfoRate = status.attackInfo.rateInfoRate;
     fromObjectID   = status.fromObjectID;
     fromType       = (int)status.fromType;
     hitPos         = status.hitPos;
     fromClientID   = status.fromClientID;
     if (status.skillParam != null)
     {
         skillIndex = status.skillParam.skillIndex;
     }
     regionID         = status.regionID;
     weakState        = (int)status.weakState;
     damage           = status.damage;
     downAddBase      = status.downAddBase;
     downAddWeak      = status.downAddWeak;
     isArrowBleed     = status.isArrowBleed;
     arrowBleedDamage = status.arrowBleedDamage;
     arrowBurstDamage = status.arrowBurstDamage;
     hostPos          = status.hostPos;
     hostDir          = status.hostDir;
     afterHP          = status.afterHP;
     afterRegionHP    = status.afterRegionHP;
     afterHealHp      = status.afterHealHp;
     breakRegion      = status.breakRegion;
     reactionType     = status.reactionType;
     blowForce        = status.blowForce;
     downTotal        = status.downTotal;
     badStatusTotal.Copy(status.badStatusTotal);
     damageHpRate         = status.damageHpRate;
     arrowBleedSkipFirst  = status.arrowBleedSkipFirst;
     isSpAttackHit        = status.IsSpAttackHit;
     afterRegionBarrierHp = status.afterBarrierHp;
     damageDetails        = status.damageDetails;
     afterShieldHp        = status.afterShieldHp;
     afterGrabHp          = status.afterGrabHp;
     isShadowSealing      = status.isShadowSealing;
     aegisParam.Copy(status.aegisParam);
 }
Exemplo n.º 10
0
 public override void OnAttackedHitFix(AttackedHitStatusFix status)
 {
     base.OnAttackedHitFix(status);
     if (status.damage > 0 && status.fromType == OBJECT_TYPE.ENEMY && isHitBreakEnable && breakEnebleFlag && !isBreak)
     {
         isBreak = true;
         int i = 0;
         for (int num = _colliderList.Length; i < num; i++)
         {
             if (_colliderList[i] != null)
             {
                 _colliderList[i].set_enabled(false);
             }
         }
         _animEventShot.OnDestroy();
     }
 }
    public override void OnDamage(AttackedHitStatusFix status, Character to_obj)
    {
        if (status.reactionType == 8)
        {
            switch (missionRequire)
            {
            case MISSION_REQUIRE.SELF:
                if (!(to_obj as Self == null))
                {
                    isDead = true;
                }
                break;

            case MISSION_REQUIRE.ALL:
                if (!(to_obj as Player == null) && !MonoBehaviourSingleton <StageObjectManager> .I.nonplayerList.Contains(to_obj))
                {
                    isDead = true;
                }
                break;
            }
        }
    }
 public override void OnAttackedHitFix(AttackedHitStatusFix status)
 {
     //IL_0037: Unknown result type (might be due to invalid IL or missing references)
     //IL_0042: Unknown result type (might be due to invalid IL or missing references)
     //IL_0048: Expected O, but got Unknown
     //IL_0053: Unknown result type (might be due to invalid IL or missing references)
     //IL_006e: Unknown result type (might be due to invalid IL or missing references)
     //IL_0073: Unknown result type (might be due to invalid IL or missing references)
     //IL_0081: Unknown result type (might be due to invalid IL or missing references)
     //IL_0086: Unknown result type (might be due to invalid IL or missing references)
     //IL_008e: Unknown result type (might be due to invalid IL or missing references)
     //IL_0093: Unknown result type (might be due to invalid IL or missing references)
     //IL_009e: Unknown result type (might be due to invalid IL or missing references)
     //IL_00b6: Unknown result type (might be due to invalid IL or missing references)
     if (!isDead)
     {
         _nowHp = status.afterHP;
         if (_nowHp <= 0)
         {
             _nowHp = 0;
             SoundManager.PlayOneShotSE(param.targetBreakSeId, status.hitPos);
             if (!object.ReferenceEquals((object)this.get_gameObject(), null))
             {
                 Object.Destroy(this.get_gameObject());
             }
         }
         else
         {
             string  targetHitEffect = param.targetHitEffect;
             Vector3 hitPos          = status.hitPos;
             float   x       = hitPos.x;
             Vector3 hitPos2 = status.hitPos;
             EffectManager.OneShot(targetHitEffect, new Vector3(x, 0f, hitPos2.z), Quaternion.get_identity(), param.targetHitEffectScale, false, null);
             SoundManager.PlayOneShotSE(param.targetHitSeId, status.hitPos);
         }
     }
 }
 public virtual void OnDamage(AttackedHitStatusFix status, Character to_obj)
 {
 }
Exemplo n.º 14
0
 public virtual void OnAttackedHitFix(AttackedHitStatusFix status)
 {
 }
Exemplo n.º 15
0
    protected override bool HandleCoopEvent(CoopPacket packet)
    {
        switch (packet.packetType)
        {
        case PACKET_TYPE.OBJECT_DESTROY:
            if (owner is Self)
            {
                return(true);
            }
            return(owner.DestroyObject());

        case PACKET_TYPE.OBJECT_ATTACKED_HIT_OWNER:
        {
            Coop_Model_ObjectAttackedHitOwner model5 = packet.GetModel <Coop_Model_ObjectAttackedHitOwner>();
            model5.CopyAttackedHitStatus(out AttackedHitStatusOwner status2);
            if (owner.IsEnableAttackedHitOwner())
            {
                owner.OnAttackedHitOwner(status2);
                AttackedHitStatusFix status3 = new AttackedHitStatusFix(status2.origin);
                owner.OnAttackedHitFix(status3);
                if (owner.packetSender != null)
                {
                    owner.packetSender.OnAttackedHitFix(status3);
                }
            }
            break;
        }

        case PACKET_TYPE.OBJECT_ATTACKED_HIT_FIX:
        {
            Coop_Model_ObjectAttackedHitFix model4 = packet.GetModel <Coop_Model_ObjectAttackedHitFix>();
            model4.CopyAttackedHitStatus(out AttackedHitStatusFix status);
            owner.OnAttackedHitFix(status);
            break;
        }

        case PACKET_TYPE.OBJECT_KEEP_WAITING_PACKET:
        {
            Coop_Model_ObjectKeepWaitingPacket model3 = packet.GetModel <Coop_Model_ObjectKeepWaitingPacket>();
            owner.KeepWaitingPacket((StageObject.WAITING_PACKET)model3.type);
            break;
        }

        case PACKET_TYPE.OBJECT_BULLET_OBSERVABLE_SET:
        {
            Coop_Model_ObjectBulletObservableSet model2 = packet.GetModel <Coop_Model_ObjectBulletObservableSet>();
            owner.RegisterObservableID(model2.observedID);
            break;
        }

        case PACKET_TYPE.OBJECT_BULLET_OBSERVABLE_BROKEN:
        {
            Coop_Model_ObjectBulletObservableBroken model = packet.GetModel <Coop_Model_ObjectBulletObservableBroken>();
            owner.OnBreak(model.observedID);
            break;
        }

        default:
            Log.Warning(LOG.COOP, "not valid packet");
            return(true);
        }
        return(true);
    }
 public override void OnAttackedHitFix(AttackedHitStatusFix status)
 {
     base.OnAttackedHitFix(status);
     m_sphereCollider.set_enabled(false);
     RequestDestroy();
 }