static void InitNumberOfCores()
 {
     //  Get number of cores of local machine. As I don't know what values it can return, I clamp it to <1..4> (min 1 core, max 4 cores). That are tested values. I can't test eight cores...
     NumberOfCores = Environment.ProcessorCount;
     MyMwcLog.WriteLine("Found processor count: " + NumberOfCores);       //  What we found
     NumberOfCores = MyMwcUtils.GetClampInt(NumberOfCores, 1, 16);
     MyMwcLog.WriteLine("Using processor count: " + NumberOfCores);       //  What are we really going use
 }
 protected void DecreaseSmoke()
 {
     m_smokeToGenerate -= MyAutocanonConstants.SMOKE_DECREASE;
     m_smokeToGenerate  = MyMwcUtils.GetClampInt(m_smokeToGenerate, 0, MyAutocanonConstants.SMOKES_MAX);
 }
 protected void IncreaseSmoke()
 {
     m_smokeToGenerate += MyAutocanonConstants.SMOKE_INCREASE_PER_SHOT;
     m_smokeToGenerate  = MyMwcUtils.GetClampInt(m_smokeToGenerate, 0, MyAutocanonConstants.SMOKES_MAX);
 }
Example #4
0
 void ClampSmokesToGenerate()
 {
     m_smokesToGenerate = MyMwcUtils.GetClampInt(m_smokesToGenerate, 0, MyAutocanonConstants.SMOKES_MAX);
 }