コード例 #1
0
        protected virtual void PlayDefenderMiss(UIBattleShip ship, Vector3 defenderPos, BattleFieldCamera fieldCamera)
        {
            SoundUtils.PlayDamageSE(HitState.Miss, false);
            ParticleSystem splashMiss = BattleTaskManager.GetParticleFile().splashMiss;

            splashMiss.get_transform().set_parent(this.particleParent);
            splashMiss.SetLayer(Generics.Layers.UnRefrectEffects.IntLayer(), true);
            splashMiss.get_transform().set_position(Vector3.Lerp(fieldCamera.get_transform().get_position(), defenderPos, 1f));
            splashMiss.get_transform().positionY(0f);
            splashMiss.get_transform().set_localPosition(new Vector3(splashMiss.get_transform().get_localPosition().x, splashMiss.get_transform().get_localPosition().y, (!ship.shipModel.IsFriend()) ? -15f : 15f));
            splashMiss.SetActive(true);
            splashMiss.Play();
            this.PlayHpGaugeDamage(ship, this.hitState);
        }
コード例 #2
0
        protected virtual void PlayDefenderGard(UIBattleShip ship, Vector3 defenderPos, BattleFieldCamera fieldCamera)
        {
            ParticleSystem explosionB3WhiteSmoke = BattleTaskManager.GetParticleFile().explosionB3WhiteSmoke;

            explosionB3WhiteSmoke.get_transform().set_parent(this.particleParent);
            explosionB3WhiteSmoke.SetLayer(Generics.Layers.UnRefrectEffects.IntLayer(), true);
            explosionB3WhiteSmoke.get_transform().set_position(Vector3.Lerp(fieldCamera.get_transform().get_position(), defenderPos, 0.9f));
            explosionB3WhiteSmoke.SetActive(true);
            explosionB3WhiteSmoke.Play();
            SoundUtils.PlayDamageSE(HitState.Gard, false);
            this.PlayDamageVoice(ship, this._clsHougekiModel.Defender.DamageEventAfter);
            this.PlayHpGaugeDamage(ship, this.hitState);
            fieldCamera.cameraShake.ShakeRot(null);
        }
コード例 #3
0
        protected virtual void PlayDefenderGard(UIBattleShip ship, Vector3 defenderPos, BattleFieldCamera fieldCamera)
        {
            ParticleSystem explosionB3WhiteSmoke = BattleTaskManager.GetParticleFile().explosionB3WhiteSmoke;

            ((Component)explosionB3WhiteSmoke).transform.parent = particleParent;
            ((Component)explosionB3WhiteSmoke).SetLayer(Generics.Layers.UnRefrectEffects.IntLayer(), includeChildren: true);
            ((Component)explosionB3WhiteSmoke).transform.position = Vector3.Lerp(fieldCamera.transform.position, defenderPos, 0.9f);
            ((Component)explosionB3WhiteSmoke).SetActive(isActive: true);
            explosionB3WhiteSmoke.Play();
            SoundUtils.PlayDamageSE(HitState.Gard, isTorpedo: false);
            PlayDamageVoice(ship, _clsHougekiModel.Defender.DamageEventAfter);
            PlayHpGaugeDamage(ship, hitState);
            fieldCamera.cameraShake.ShakeRot(null);
        }
コード例 #4
0
        protected virtual void PlayDefenderMiss(UIBattleShip ship, Vector3 defenderPos, BattleFieldCamera fieldCamera)
        {
            SoundUtils.PlayDamageSE(HitState.Miss, isTorpedo: false);
            ParticleSystem splashMiss = BattleTaskManager.GetParticleFile().splashMiss;

            ((Component)splashMiss).transform.parent = particleParent;
            ((Component)splashMiss).SetLayer(Generics.Layers.UnRefrectEffects.IntLayer(), includeChildren: true);
            ((Component)splashMiss).transform.position = Vector3.Lerp(fieldCamera.transform.position, defenderPos, 1f);
            ((Component)splashMiss).transform.positionY();
            Transform transform      = ((Component)splashMiss).transform;
            Vector3   localPosition  = ((Component)splashMiss).transform.localPosition;
            float     x              = localPosition.x;
            Vector3   localPosition2 = ((Component)splashMiss).transform.localPosition;

            transform.localPosition = new Vector3(x, localPosition2.y, (!ship.shipModel.IsFriend()) ? (-15f) : 15f);
            ((Component)splashMiss).SetActive(isActive: true);
            splashMiss.Play();
            PlayHpGaugeDamage(ship, hitState);
        }