What's the best collision system for an RPG?
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
What's the best collision system for an RPG?
Right now, I'm making an RPG that uses love.physics for the collisions. I feel like that's a bit overkill, and I was wondering what the best system is? Before love.physics I had a simple system that detected wether the x and y of the player collided with a block, but my player could keep glitching inside it, and weird things happened. I probably didn't code it that well, I am just a beginner. I don't want to use any external libraries, I want to learn here, right? What's the best way to implement simple collisions for an RPG?
- Jasoco
- Inner party member
- Posts: 3726
- Joined: Mon Jun 22, 2009 9:35 am
- Location: Pennsylvania, USA
- Contact:
Re: What's the best collision system for an RPG?
The current agreed upon simple to use collision system for rectangle on rectangle collision resolution is Bump 3.0 by kikito. It's in the projects and demos forum.
Re: What's the best collision system for an RPG?
I would recommend implementing AABB-collision (axis-aligned bounding box) if your goal is to implement it yourself, rather than using a library. It's only a couple of lines, and I think it will be challenging enough for you that you will learn without getting discouraged. Try making a simple program where you move squares around, and have them change color when they collide for testing. Once you know it works you can stick it into your game.
Simple AABB won't be any good if your rectangles are going to rotate, though :S
Simple AABB won't be any good if your rectangles are going to rotate, though :S
- Jasoco
- Inner party member
- Posts: 3726
- Joined: Mon Jun 22, 2009 9:35 am
- Location: Pennsylvania, USA
- Contact:
Re: What's the best collision system for an RPG?
You'll still have to write your own resolution. Bump takes care of that for you and offers many options without being overwhelming.
Who is online
Users browsing this forum: Bing [Bot] and 7 guests