Example #1
0
        public static void lecture_bossentry(StreamReader lecture)
        {
            string ligne = lecture.ReadLine();
            int    x     = System.Convert.ToInt32(ligne);

            ligne = lecture.ReadLine();
            int y = System.Convert.ToInt32(ligne);

            checkPointBossEntry = new CheckPoint(x, y, "bossentry");
            ligne = lecture.ReadLine();
        }
Example #2
0
        public static void lecture_arrivee(StreamReader lecture)
        {
            string ligne = lecture.ReadLine();
            int    x     = System.Convert.ToInt32(ligne);

            ligne = lecture.ReadLine();
            int y = System.Convert.ToInt32(ligne);

            checkpointArrivee = new CheckPoint(x, y, "arrivee");
            ligne             = lecture.ReadLine();
        }
Example #3
0
 public Param_Map(bool[,] liste, bool[,] liste_projectile, List <Spawn> liste_spawn, List <DestructibleItems> liste_barrel, Spawn_Items liste_caisses, int x, int y, int texture_map, int hauteur, int largeur, CheckPoint checkpointArrivee, CheckPoint checkpointBossEntry, bool scrolling)
 {
     this.liste            = liste;
     this.liste_projectile = liste_projectile;
     this.liste_spawn      = liste_spawn;
     this.liste_barrel     = liste_barrel;
     this.liste_caisses    = liste_caisses;
     this.x                   = x;
     this.y                   = y;
     this.texture_map         = texture_map;
     this.hauteur             = hauteur;
     this.largeur             = largeur;
     this.checkpointArrivee   = checkpointArrivee;
     this.checkpointBossEntry = checkpointBossEntry;
     this.scrolling           = scrolling;
 }
Example #4
0
        public static void lecture_arrivee(StreamReader lecture)
        {
            string ligne = lecture.ReadLine();
            int x = System.Convert.ToInt32(ligne);

            ligne = lecture.ReadLine();
            int y = System.Convert.ToInt32(ligne);

            checkpointArrivee = new CheckPoint(x, y, "arrivee");
            ligne = lecture.ReadLine();
        }
Example #5
0
 public Param_Map(bool[,] liste, bool[,] liste_projectile, List<Spawn> liste_spawn, List<DestructibleItems> liste_barrel, Spawn_Items liste_caisses, int x, int y, int texture_map, int hauteur, int largeur, CheckPoint checkpointArrivee, CheckPoint checkpointBossEntry, bool scrolling)
 {
     this.liste = liste;
     this.liste_projectile = liste_projectile;
     this.liste_spawn = liste_spawn;
     this.liste_barrel = liste_barrel;
     this.liste_caisses = liste_caisses;
     this.x = x;
     this.y = y;
     this.texture_map = texture_map;
     this.hauteur = hauteur;
     this.largeur = largeur;
     this.checkpointArrivee = checkpointArrivee;
     this.checkpointBossEntry = checkpointBossEntry;
     this.scrolling = scrolling;
 }
Example #6
0
        public static void lecture_bossentry(StreamReader lecture)
        {
            string ligne = lecture.ReadLine();
            int x = System.Convert.ToInt32(ligne);

            ligne = lecture.ReadLine();
            int y = System.Convert.ToInt32(ligne);

            checkPointBossEntry = new CheckPoint(x, y, "bossentry");
            ligne = lecture.ReadLine();
        }
Example #7
0
        // CONSTRUCTOR
        public Map(Param_Map parametre)
        {
            this.parametre = parametre;

            MapTexture = new Rectangle(0, 0, parametre.hauteur * 16, (parametre.largeur - 1) * 16);
            this.map_physique = new PhysicsEngine(parametre.liste, parametre.liste_projectile);
            this.liste_ia = new List<IA>();
            if (parametre.texture_map == 3)
            {
                Player p1 = new Player(Keys.Up, Keys.Down, Keys.Left, Keys.Right, Keys.N, Keys.P, Keys.Enter, Keys.T, Ressources.Player1, parametre.x, parametre.y);
                Player p2 = new Player(Keys.Z, Keys.S, Keys.Q, Keys.D, Keys.A, Keys.E, Keys.R, Keys.W, Ressources.Player2, parametre.x, parametre.y);
                p1.bomb = 5;
                p2.bomb = 5;
                liste_joueurs.Add(p1);
                liste_joueurs.Add(p2);
            }
            else
            {
                this.liste_joueurs.Add(new Player(Keys.Up, Keys.Down, Keys.Left, Keys.Right, Keys.N, Keys.P, Keys.Enter, Keys.T, Ressources.Player1, parametre.x, parametre.y));
            }

            //HEALTH + AMMO BOXES
            this.liste_box = new List<Items>();
            this.liste_box2 = new List<Items>();

            //EXPLOSIVE BOXES
            this.liste_barrel = new List<DestructibleItems>();
            this.liste_barrel = parametre.liste_barrel;

            //EXPLOSION PARTICULE
            this.liste_explosions = new List<ParticuleExplosion>();
            this.liste_explosions2 = new List<ParticuleExplosion>();
            this.liste_explosions3 = new List<ParticuleExplosion>();
            this.explosionTexture = Ressources.ExplosionParticule;

            //BLOOD PARTICULE
            this.liste_blood = new List<ParticuleExplosion>();
            this.liste_blood2 = new List<ParticuleExplosion>();

            //TURRETS
            this.liste_turret = new List<Turret>();
            this.liste_turret2 = new List<Turret>();

            //RAIN (que sur la map01)
            this.liste_rain = new List<ParticuleRain>();
            this.rainTexture = Ressources.mRain;

            this.spawns = parametre.liste_spawn;
            this.spawn_items = parametre.liste_caisses;

            this.liste_clavier = new List<Keys>();
            this.liste_clavier_2 = new List<Keys>();

            fin_niveau = parametre.checkpointArrivee;
            boss_entry = parametre.checkpointBossEntry;

            //Client.initialisationClient(4242);
            //Serveur.intialisationServeur(1338);
        }