Simple and Fast Multimedia Library - a free, portable API that provides access to graphics, input, audio, etc.

learn more… | top users | synonyms

8
votes
1answer
3k views

Fast, accurate 2d collision

I'm working on a 2d topdown shooter, and now need to go beyond my basic rectangle bounding box collision system. I have large levels with many different sprites, all of which are different shapes and ...
53
votes
9answers
6k views

How can you put all images from a game to 1 file?

I've just finished a basic RPG game written in C++ SFML, I've put a lot of effort into the game and I'd want to distribute it, however I've ran into a small issue. Problem is, I have well over 200 ...
10
votes
4answers
2k views

Collision rectangle response

I'm having difficulties getting a moveable rectangle to collide with more than one rectangle. I'm using SFML and it has a handy function called intersects which takes 2 rectangles and returns the ...
6
votes
1answer
183 views

Get SFML to report the version of OpenGL that is being used

How can I get SFML to report the version of OpenGL that is being used by the render window?
3
votes
1answer
289 views

Jittery Movement, Uncontrollably Rotating + Front of Sprite?

So I've been looking around to try and figure out how I make my sprite face my mouse. So far the sprite moves to where my mouse is by some vector math. Now I'd like it to rotate and face the mouse as ...
2
votes
2answers
522 views

how to keep a GUI on-screen without moving or resizing it according to camera movement

Hey i'm trying to make a GUI lib with SFML, and everything's done except one problem: Making the Interface stay still even when the camera moves or zooms in/out. This would be easy to fix if zooming ...
0
votes
2answers
915 views

Action button: only true once per press

I'm using SFML2.0 and am trying to make a wrapper class for my controller/joystick. I read all the input data from my controller and send it off to my controllable object. I want to have two types of ...
-1
votes
2answers
333 views

Shooting many bullets toward the mouse position

I try to shoot a bullet toward the mouse position by this code. float deltaX = mousePosition.x - (aircraft.getPosition().x + aircraft.getLocalBounds().width / 2); float deltaY = mousePosition.y - ...
-3
votes
1answer
193 views

Simple collision detection implementation [closed]

I'm making a game with C++ where the program extracts the lines out of an image (via openCV), stores them in an std::vector< std::vector< int > > and the builds a tile map out of it which is ...