Beispiel #1
0
        private void UpdateInternal()
        {
            MyStatToken token;

            MySimpleProfiler.BeginBlock("UpdateFrame", MySimpleProfiler.ProfilingBlockType.INTERNAL);
            using (token = Stats.Generic.Measure("BeforeUpdate"))
            {
                MyRenderProxy.BeforeUpdate();
            }
            this.m_totalTime      = this.m_gameTimer.Elapsed;
            this.m_updateCounter += (ulong)1L;
            if (MySession.Static != null)
            {
                this.m_simulationTimeWithSpeed += MyTimeSpan.FromMilliseconds(16.666666666666668 * MyFakes.SIMULATION_SPEED);
            }
            bool enableNetworkPacketTracking = MyCompilationSymbols.EnableNetworkPacketTracking;

            this.Update();
            if (!IsDedicated)
            {
                this.PrepareForDraw();
            }
            using (token = Stats.Generic.Measure("AfterUpdate"))
            {
                this.AfterDraw();
            }
            MySimpleProfiler.End("UpdateFrame");
            MySimpleProfiler.Commit();
        }