Exemplo n.º 1
0
        public static void Simulate()
        {
            simulationCount--;
            if (simulationCount <= 0)
            {
                simulationCount = SimulationSpread;
            }
            else
            {
                return;
            }


            for (i = 0; i < PeakCount; i++)
            {
                if (SimObjectExists [i])
                {
                    b1 = SimObjects [i];
                    b1.EarlySimulate();
                }
            }
            Partition.CheckAndDistributeCollisions();
            for (i = 0; i < PeakCount; i++)
            {
                if (SimObjectExists [i])
                {
                    b1 = SimObjects [i];
                    b1.Simulate();
                }
            }
        }
 public static void Simulate()
 {
     for (i = 0; i < PeakCount; i++)
     {
         if (SimObjectExists [i])
         {
             b1 = SimObjects [i];
             b1.EarlySimulate();
         }
     }
     Partition.CheckAndDistributeCollisions();
     for (i = 0; i < PeakCount; i++)
     {
         if (SimObjectExists [i])
         {
             b1 = SimObjects [i];
             b1.Simulate();
         }
     }
 }
Exemplo n.º 3
0
 public static void Simulate()
 {
     Partition.CheckAndDistributeCollisions();
     Simulated = true;
 }