SFML community forums
Help => Graphics => Topic started by: Fantasy on January 05, 2012, 10:46:28 am
-
Hello guys
I have a sprite called button and my player sprite.
now i have a problem where the button sprite is moving with the screen. How can i only move the screen without moving the button sprite?
-
Draw the button on the default view:
...
set your view
draw player
reset default view // window.SetView(window.GetDefaultView()) //
draw button
...
-
Draw the button on the default view:
...
set your view
draw player
reset default view // window.SetView(window.GetDefaultView()) //
draw button
...
thank you very much that works :)
-
For SFML 1.6:
App.SetView(App.GetDefaultView())
Place that before your button is drawn and after your player is drawn.