Пример #1
0
#pragma warning disable 8618
            public Turret(ShellEntity shellFactory, int index)
#pragma warning restore 8618
            {
                _shellFactory = shellFactory;
                _index        = index;

                // ReSharper disable HeapView.BoxingAllocation
                _elevationName       = $":tgt_gun_elevation_{_index}";
                _bearingName         = $":tgt_gun_bearing_{_index}";
                _actualElevationName = $":gun_elevation_{_index}";
                _actualBearingName   = $":gun_bearing_{_index}";
                _gunReadyName        = $":gun_ready_{_index}";
                _gunTriggerName      = $":gun_trigger_{_index}";
                _gunFuseName         = $":gun_fuse_{_index}";
                // ReSharper restore HeapView.BoxingAllocation
            }
Пример #2
0
        public override string ToString()
        {
            int nFaces = ShellEntity.GetFaceCount();

            return(string.Format("DSShell(Faces = {0})", nFaces));
        }