Пример #1
0
 public Plagued SpawnPlagueCritter()
 {
     Plagued p = new Plagued(TextureRefs.plagueTexture, new Rectangle(), 0);
     mPlagues.Add(p);
     return p;
 }
Пример #2
0
        public Critter SpawnCritter(char cType, int age)
        {
            Critter critter;

            if (cType == 'M')
            {
                critter = new Male(TextureRefs.maleTexture, new Rectangle(), age);
                mMales.Add(critter);
            }
            else if (cType == 'F')
            {
                critter = new Female(TextureRefs.femaleTexture, new Rectangle(), age);
                mFemales.Add(critter);
            }
            else if (cType == 'D')
            {
                critter = new Doctor(TextureRefs.doctorTexture, new Rectangle(), age);
                mDoctors.Add(critter);
            }
            else
            {
                critter = new Plagued(TextureRefs.plagueTexture, new Rectangle(), age);
                mPlagues.Add(critter);
            }

            return critter;
        }