public VentanaJuego() { InitializeComponent(); //this.Width = w; //this.Height = h; //pictureBox1.Width = w ; //pictureBox1.Height = h; //----------Manager--------------------// F_M = new FileManager(); R_M = new RenderManager(); S_M = new SceneManager(); PM = new PhisicManager(); //--------Delegados-------------------// S_H = new SceneHandler(S_M.PlayScene); R_H = new RenderHandler(R_M.AddData); F_H = new FileHandler(F_M.GetImg); //---------Inicializacion------------// R_M.AddHandlers(S_H, F_H); //mapa1.SetFileManager(F_H); mapa1 = F_M.CargarMapa("../../Mapas/mapa3.xml", this.Width, this.Height, 32); mapa1.IM.left = Keys.A; mapa1.IM.right = Keys.D; mapa1.IM.up = Keys.W; mapa1.IM.down = Keys.S; mapa1.Draw(R_H); R_M.Sorting(); //--------Timer--------------------// //Thread mov = new Thread(Caminar); //Thread col = new Thread(Colicion); //mov.Start(); timer1.Start(); //col.Start(); mapa1.FraccPantalla(pictureBox1.Width, pictureBox1.Height); mapa1.CentrarJugador(); //----------Sonido------------------// //mp = new MP3Player(); //mp.Open(F_M.GetAud_Path("Correr")); //mp.Play(); pictureBox1.Refresh(); }