I have SFML.NET working fine, and wrote my own little scene manager. In the scene interface I have a method called "Update". I'm trying to see if the user has clicked on the play button or quit button, but I get nothing.
public void Update(RenderWindow window)
{
if (Mouse.IsButtonPressed(Mouse.Button.Left))
{
Program.WriteDebug("Mouse was clicked.");
Vector2i mousePosition = Mouse.GetPosition(window);
if (play.TextureRect.Contains(mousePosition.X, mousePosition.Y))
{
// Not displaying text.
Program.WriteDebug("Play button pressed.");
}
else if (quit.TextureRect.Contains(mousePosition.X, mousePosition.Y))
{
// Not displaying text.
Program.WriteDebug("Quit button pressed");
}
}
}
EDIT: I have the project set to Console Application, so I can see the console and the application.