protected void CreateTarget() { const int TARGET_SIZE = 32; SizeF size = new SizeF(TARGET_SIZE, TARGET_SIZE); PointF location = WrappedWorld.RandomPositionInsideViewport(m_rndGen, size); m_target = WrappedWorld.CreateGameObject(@"White10x10.png", location, size); // Plumber: //m_target.X = m_rndGen.Next(0, World.Scene.WidthFov - m_target.WidthFov + 1); //m_target.Y = World.Scene.HeightFov - m_target.HeightFov; // Roguelike: //m_target.X = m_rndGen.Next(0, WrappedWorld.Viewport.WidthFov - m_target.WidthFov + 1); //m_target.Y = m_rndGen.Next(0, WrappedWorld.Viewport.HeightFov - m_target.HeightFov + 1); }