Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
Help
»
General
»
Collision Detection
Print
Pages: [
1
]
Author
Topic: Collision Detection (Read 3483 times)
0 Members and 1 Guest are viewing this topic.
Gio
Newbie
Posts: 16
Collision Detection
«
on:
June 02, 2010, 12:17:46 am »
Im trying to write a Roguelike Game for my first SFML project and want to know if it is possible to use collision detection. If so, how? If not, are there any 2D physics engine/libraries that this can be integrated with? thanks!
Logged
~~Gio~~
Walker
Full Member
Posts: 181
Collision Detection
«
Reply #1 on:
June 02, 2010, 03:42:48 am »
Of course it's possible!
Some people use Box2D with SFML. It would be overkill for most roguelikes though. I don't know what experience you've had before SFML, but adding a physics (simulation) engine to your project is a fair bit of work and just increases the complexity and time it will take to finish.
There's a pretty good collision detection class in the wiki -
http://www.sfml-dev.org/wiki/en/sources/simple_collision_detection
Most roguelikes don't even need that level of collision detection - they just need to check if the player is on the same tile as an item or next to an enemy.
If you wanted a physics engine just for cool effects or something though, sorry for ranting :lol:
Logged
dunce
Jr. Member
Posts: 77
Collision Detection
«
Reply #2 on:
June 02, 2010, 08:32:47 am »
Besides Box2d there is a more lightweight and slightly faster 2d physics library Chipmunk.
Logged
Print
Pages: [
1
]
SFML community forums
»
Help
»
General
»
Collision Detection
anything