Help with Platform game

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
somebodyelse
Prole
Posts: 11
Joined: Thu Feb 13, 2014 4:49 am

Help with Platform game

Post by somebodyelse »

I've made a simple game using just the info from the Wiki which is a great source but I am struggling with some concepts in Love2d. I'm trying to make a Platform game but am finding it difficult to even know which parts of the wiki I should be looking at in order to do what I need, and I have tried researching online for some help with Love2d and platform stuff but haven't found anything. I came across 2 things only. The first one is listed on theLove2d main page, it's a Mario-like platform game. I downloaded it and it didn't work. I then went to the forums here and the person said it is not compatible with Love 0.9.0 so it won't work. The second thing I found was a tutorial but all that it consisted of was a huge block on the bottom of the screen and a small block that jumps up and down. Not much to go by (for me anyway).

I have drawn an example of what I want to do just to give you an idea of what I'm talking about:

Image (here is the link: http://s15.postimg.org/bpk9mcgzf/L2_DG.png )

In the sample image there are blocks, a red coin thing that theplayer needs to "pick up" and water.

What I'm struggling with is, how would I "lay out" a platform level? Would I need to individually load draw and place each and every single block manually?

I have used the Tile map samples on the wiki and have thought about using a Tile-based approach to this, but I just don't know if that is the right approach to be using and I'm also unsure of tile map style because in my levels, I will also have "moving parts" (some regular blocks that you think are ground, will suddenly fall into the water when you step on them) So how can I turn a single tile-based block into a movable thing? Also, I need to take into account Camera. I'll need to move along with the player as he gets closer to the right-edge of the level so that more of the level is revealed.

Any help is much appreciated, and sorry for the long post!

Does anyone know of any working platform sample games that I can learn from, or where should I start from to make a proper platform game?
User avatar
micha
Inner party member
Posts: 1083
Joined: Wed Sep 26, 2012 5:13 pm

Re: Help with Platform game

Post by micha »

Hi,

once you are familiar with the LÖVE basics, then your question are not so much LÖVE-specific, but more a question of how to implement a platformer generally. For the beginning, I recommend making your game tile based.
For an overview over various methods for making a platformer, see here. You'd want to go for "Tile based (smooth)".
Then, for the implementation, I recommend the tutorial on Exploding Rabbit. It might be a bit outdated (it was made for 0.8.0 not for 0.9.0), but as far as I can tell, it should still work.
somebodyelse
Prole
Posts: 11
Joined: Thu Feb 13, 2014 4:49 am

Re: Help with Platform game

Post by somebodyelse »

Hey thanks for the links. Right after I posted my question, I found that Exploding Rabbit tutorial on Platformers. I skipped to the end (just to test out the final .love file) and noticed that when you click the titlebar of the window, move the window or resize the window, the character then falls through the ground and other tiles. Is there a way to avoid this behaviour?

Edit: I just checked out he Higher Order Fun site you linked to. Thanks so much for that link, very useful information!
User avatar
pacman
Citizen
Posts: 81
Joined: Thu Mar 14, 2013 4:10 pm

Re: Help with Platform game

Post by pacman »

I used this tutorial to start with love and checked if my game behaves like that.
Wiggled a little bit and every entity was in its place.
It means that this tutorial isn't the best :D But it's still good.
You will notice when something is not working and figure it out as it goes.
Be strong!
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 1 guest