Page 1 of 2

Qbic: The adventure begin [FROZEN]

Posted: Sun Oct 16, 2011 7:57 am
by AxGS
Hello guys, Im making a platform game named Qbic. The story will be SMB-like with some RPG, like upgradable weapons, skills, etc. But I dont know if I need to make it with physics or with statements like 'for', 'do' or 'while'. I really need help with how to make it without physics. I appreciate your help ;) .

Re: Qbic: The adventure begin

Posted: Sun Oct 16, 2011 10:51 am
by ivan
AxGS wrote:I dont know if I need to make it with physics or with statements like 'for', 'do' or 'while'. I really need help with how to make it without physics. I appreciate your help ;) .
Hi. The physics library that comes with Love is called Box2D.
It's not designed for platformers per se - if you decide to use it you would have to figure out certain things like how to implement one-sided platforms and such.
If you don't want to use Box2D, then you would have to program your own collision detection and resolution system which can get pretty complicated.

Re: Qbic: The adventure begin

Posted: Sun Oct 16, 2011 12:21 pm
by T-Bone
For a standard platformer, using Box2D will only make things a lot harder. Do it "the normal way".

Implementing a simple collision detector isn't hard at all. Making a tile system is more complicated but still not a big problem. Just drawing tiles on a bunch of 512*512 framebuffers and then drawing the ones that should be visible on screen isn't too hard and gives good performance.

Re: Qbic: The adventure begin

Posted: Sun Oct 16, 2011 2:49 pm
by AxGS
Oh, thank you guys, I will try to make the collition system, but play a little bit with Box2D, I hope you guys like this project :cool: . I think, will be a quite hard to do the collition system because its my first platform project, wish me luck :ultraglee: .

Re: Qbic: The adventure begin

Posted: Sun Oct 16, 2011 2:59 pm
by T-Bone
AxGS wrote:Oh, thank you guys, I will try to make the collition system, but play a little bit with Box2D, I hope you guys like this project :cool: . I think, will be a quite hard to do the collition system because its my first platform project, wish me luck :ultraglee: .
But collisions aren't hard. When it comes to collision between objects, do somthing like http://love2d.org/wiki/BoundingBox.lua and then if you use tiles, just mark the tiles that are "solid" and check every time an object tries to move whether or not the place it's trying to move to is inside a solid tile. It's not very hard at all.

Making an efficient tile system is more complicated. There are a bunch of tutorials on this subject though (although none of them use framebuffers which I consider ideal for this task).

Re: Qbic: The adventure begin

Posted: Sun Oct 16, 2011 5:28 pm
by Kadoba
Personally I think a good collision system is WAY harder to code than tile maps. Luckily you don't have to do either.

http://vrld.github.com/HardonCollider/
http://love2d.org/forums/viewtopic.php?f=5&t=2567

Re: Qbic: The adventure begin

Posted: Sun Oct 16, 2011 5:31 pm
by T-Bone
Kadoba wrote:Personally I think a good collision system is WAY harder to code than tile maps. Luckily you don't have to do either.

http://vrld.github.com/HardonCollider/
http://love2d.org/forums/viewtopic.php?f=5&t=2567
Well, it depends on the game. Simply checking if two boxes overlap works great and is very easy. It's also very easy to save performance by, for example, only checking collisions with stuff on screen. For most games this will be enough.

Re: Qbic: The adventure begin

Posted: Sun Oct 16, 2011 7:38 pm
by tentus
T-Bone wrote:
Kadoba wrote:Personally I think a good collision system is WAY harder to code than tile maps. Luckily you don't have to do either.

http://vrld.github.com/HardonCollider/
http://love2d.org/forums/viewtopic.php?f=5&t=2567
Well, it depends on the game. Simply checking if two boxes overlap works great and is very easy. It's also very easy to save performance by, for example, only checking collisions with stuff on screen. For most games this will be enough.
But with a platformer, you have to handle what to do with collisions, not just whether or not they're touching.That gets into dealing with solids, semi-solids, and a host of unusual situations.

I was able to put together a working system in Kurosuke with Box2D without as much difficulty as everyone seems convinced of, but it does mean I can't do one-way platforms. Doesn't bother me too much though, everything else works pretty well and pretty quickly.

Re: Qbic: The adventure begin

Posted: Sun Oct 16, 2011 10:58 pm
by bmelts
tentus wrote:I was able to put together a working system in Kurosuke with Box2D without as much difficulty as everyone seems convinced of, but it does mean I can't do one-way platforms.
LÖVE 0.8.0 will make one-way platforms a possibility. :D

Re: Qbic: The adventure begin

Posted: Mon Oct 17, 2011 3:59 am
by AxGS
Kadoba wrote:Personally I think a good collision system is WAY harder to code than tile maps. Luckily you don't have to do either.

http://vrld.github.com/HardonCollider/
http://love2d.org/forums/viewtopic.php?f=5&t=2567
Thank you by the help ;) . Im glad there are grateful people in this forum :ultrahappy: