예제 #1
0
 public void Initialize(SpriteBatch spriteBatch)
 {
     zombies = new List<Zombie>();
     var zombieTexture = ContentLoader.getInstance().LoadTexture2D("zombiechar");
     background = ContentLoader.getInstance().LoadTexture2D("graveyard__wallpaper");
     carrot = new Animation(ContentLoader.getInstance().LoadTexture2D("carrot"));
     zombies.Add(new Zombie());
     lastTime = 0;
 }
예제 #2
0
 public Zombie()
 {
     anim = new Animation(ContentLoader.getInstance().LoadTexture2D("zombiechar"));
     Random rand = new Random();
     position = new Vector2(880, lanes[rand.Next(3)]);
 }