Ejemplo n.º 1
0
        public override void Close()
        {
            if ((m_smokeCue != null) && m_smokeCue.Value.IsPlaying)
            {
                m_smokeCue.Value.Stop(SharpDX.XACT3.StopFlags.Release);
            }

            base.Close();
            MyUniversalLauncherShells.Remove(this, m_ownerEntityID.PlayerId);
        }
Ejemplo n.º 2
0
 public override void Close()
 {
     if (m_hologramShip != null)
     {
         MyHologramShips.Remove(m_hologramShip);
         m_hologramShip.MarkForClose();
         m_hologramShip = null;
     }
     base.Close();
     MyUniversalLauncherShells.Remove(this, m_ownerEntityID.PlayerId);
 }
Ejemplo n.º 3
0
        public override void Close()
        {
            var ownerShip = OwnerEntity as MySmallShip;

            if (ownerShip != null)
            {
                ownerShip.RemoveRemoteBomb(this);
            }

            base.Close();
            MyUniversalLauncherShells.Remove(this, m_ownerEntityID.PlayerId);
        }
Ejemplo n.º 4
0
        public override void Close()
        {
            var ownerShip = OwnerEntity as MySmallShip;

            if (ownerShip != null)
            {
                ownerShip.RemoveRemoteCamera(this);
            }
            m_directionAfterContact = null;

            base.Close();

            MyUniversalLauncherShells.Remove(this, m_ownerEntityID.PlayerId);
        }
Ejemplo n.º 5
0
        public override void Close()
        {
            foreach (var particle in m_particles)
            {
                if (particle.ParticleEffect != null)
                {
                    particle.ParticleEffect.Stop();
                    particle.ParticleEffect = null;
                }
            }

            if ((m_flareLoop != null) && m_flareLoop.Value.IsPlaying)
            {
                m_flareLoop.Value.Stop(SharpDX.XACT3.StopFlags.Release);
            }

            m_flaresFired = false;
            Visible       = true;
            base.Close();
            MyUniversalLauncherShells.Remove(this, m_ownerEntityID.PlayerId);
        }
Ejemplo n.º 6
0
        bool Shot <T>() where T : class, IUniversalLauncherShell, new()
        {
            T shell = MyUniversalLauncherShells.Allocate <T>(Parent.EntityId.Value.PlayerId);

            if (shell != null)
            {
                Vector3 forwardVelocity = MyMath.ForwardVectorProjection(this.WorldMatrix.Forward,
                                                                         GetParentMinerShip().Physics.LinearVelocity);

                if (MinerWars.AppCode.Game.Managers.Session.MySession.Is25DSector)
                {
                    m_positionMuzzleInWorldSpace.Y = 0;
                }

                shell.Start(m_positionMuzzleInWorldSpace, forwardVelocity, WorldMatrix.Forward, 100, Parent);

                return(true);
            }

            return(false);
        }
Ejemplo n.º 7
0
 public override void Close()
 {
     base.Close();
     MyUniversalLauncherShells.Remove(this, m_ownerEntityID.PlayerId);
 }