public CityMapViewManager(StrategyGameThread game, int width, int height) : base(game) { Width = width; Height = height; //coloca a camera no mais ou menos no centro do mapa //Camera.Location = Polygon.CalculateCenter(Camera.RelativeToCamera(this.MapPolygon)); //Camera.Location = Polygon.CalculateCenter(Camera.RelativeToCamera(this.MapPolygon)); }
public MainWindow() { InitializeComponent(); //inicianlizando a surface do jogo XNAgameThread = new StrategyGameThread(pcbTeste.Handle, this, pcbTeste); //setando o metodo do sizechanged do picture box pro StrategyGameThread tratar pcbTeste.SizeChanged += XNAgameThread.pictureBox_SizeChanged; //setando a localização do jogo System.Threading.Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("pt-BR"); }