Page 1 of 1

Claustrum: a small work in progress [NEW! as of Jan 13]

Posted: Wed Jan 12, 2011 7:26 am
by Fourex
I haven't used Love in a long while, so I began a very easy project to refresh my memory. I'm not done, but I was hoping I could get some feedback! Claustrum (Latin for an enclosed space) is a simple game which uses only the arrow keys, the space bar, and the s key. You control an orb, and try to avoid touching the other orbs. I find it slightly entertaining. I'm sure you can figure out the controls!

So, if you have some time:
Play the game.
What features should I add? I will add a main menu, some scoring system, and actually losing the game. (you lose if your health bar depletes)
Open it up and take a look at the code! (there isn't much)
Any advice to give me for improving my coding techniques? I'm fairly new to both Love and programming in general, so everything helps!

You can download it here: http://fourex.harkin.net/ You want version 0.2!
Yes, I know I can upload files to the forum. The last 2 times I tried that I was permanently banned from the forums and had to email an admin to fix the glitch. :?

Re: Claustrum: a small work in progress

Posted: Wed Jan 12, 2011 9:43 pm
by Buddy4point0
Fourex wrote:I haven't used Love in a long while, so I began a very easy project to refresh my memory. I'm not done, but I was hoping I could get some feedback! Claustrum (Latin for an enclosed space) is a simple game which uses only the arrow keys and the space bar. You control an orb, and try to avoid touching the other orbs. I find it slightly entertaining. I'm sure you can figure out the controls!
Cool, I've never programmed with love, but I've programmed with lua before on PSP using luaplayer and PGE so I'm hoping to have some fun with this.
As you can see it's only my second post :) Hi Everybody!
Fourex wrote: So, if you have some time:
Play the game.
What features should I add? (I will add a main menu, a health bar, some scoring system, and a consequence for touching other orbs.)
Open it up and take a look at the code! (there isn't much)
Any advice to give me for improving my coding techniques? I'm fairly new to both Love and programming in general, so everything helps!
I've played it and other than what you mentioned, I have some suggestions:
  • Make the camera follow the player, or make it so the player cannot leave the camera.
  • Powerups like a bomb that clears the screen and the ability to pass though orbs.
  • Selectable characters (different sized orbs which move different speeds)
  • Cheat codes :P

Re: Claustrum: a small work in progress

Posted: Thu Jan 13, 2011 12:28 am
by TechnoCat
I feel like the mouse is more suited for this game. The spacebar is an interesting mechanic though.

Re: Claustrum: a small work in progress

Posted: Thu Jan 13, 2011 3:56 am
by Ensayia
Welcome! I'm glad you are in LOVE like the rest of us.

It would be a good idea to add in some code that does not allow the player object go off the screen, I went too far out and lost myself :ehem:. A simple way to do this is to check the player's x and y and if they are greater than or less than a certain value set them to a new value. Here's some example code:

Code: Select all

screenx = 800 --set these to screen resolution
screeny = 600
if player.x > screenx then player.x = screenx --set player x value to 800 if it goes further than 800
  elseif player.x < screenx - 800 then player.x = screenx - 800 --set player x value to 0 if it goes further than 0
  elseif player.y > screeny then player.y = screeny  --set player y value to 600 if it goes further than 600
  elseif player.y < screeny - 600 then player.y = screeny - 600 --set player y value to 0 if it goes further than 0
end
This makes some assumption about how you store your player x and y variables so it may need adjusting.

EDIT: Corrected code. I really need to proofread better.

Re: Claustrum: a small work in progress

Posted: Thu Jan 13, 2011 7:20 am
by Robin
Ensayia wrote:EDIT: Corrected code. I really need to proofread better.
Not really. Lua doesn't have // for comments, it uses --

Re: Claustrum: a small work in progress

Posted: Thu Jan 13, 2011 7:53 am
by BlackBulletIV
Lol. It can be hard switching back and forth between languages. Some things come, others don't.

Re: Claustrum: a small work in progress

Posted: Fri Jan 14, 2011 3:12 am
by Ensayia
I have absolutely no idea why the hell I used // instead of --, I'll correct it.

Re: Claustrum: a small work in progress

Posted: Fri Jan 14, 2011 6:56 am
by Fourex
I've added a new version!
Additions:
-A health bar
-Now you can't go out of the screen (thanks to Ensayia for inspiration)
-"Invisibility" - I didn't know what else to call it. While active, you can pass through orbs unharmed (use space)
-Power bar (this goes down rapidly while invisible)
-To stop the player, now use s.