This is my first LOVE game. A simple snake game.
controls:
Up, down, left and right arrow keys.
Pause is 'p'.
If you died, press 'Enter' to restart.
Download
Enjoy.
simple snake
simple snake
Last edited by bmzz on Sat May 07, 2011 1:31 am, edited 4 times in total.
Re: simple snake
worked nicely.
but after dying it should maybe still display the score?
now to make it a real game with levels, multiplayer and all that
but after dying it should maybe still display the score?
now to make it a real game with levels, multiplayer and all that
Re: simple snake
This is awesome. Well done.
It's an amazing example of the kind of thing new Löve developers should be doing for their first project. Just brilliant. It seems to cover all the basics including drawing primitives, text, using colour, updating, taking input and it's even got a little highscore tracking system. Fantastic man.
My criticism would be that the player seems to move a bit too slowly.
It's an amazing example of the kind of thing new Löve developers should be doing for their first project. Just brilliant. It seems to cover all the basics including drawing primitives, text, using colour, updating, taking input and it's even got a little highscore tracking system. Fantastic man.
My criticism would be that the player seems to move a bit too slowly.
Do you recognise when the world won't stop for you? Or when the days don't care what you've got to do? When the weight's too tough to lift up, what do you? Don't let them choose for you, that's on you.
Re: simple snake
Hi knorke,
you are right, i should always show the score. I have modified snake.love for it.
Thank you for your idea, i will think about them.
you are right, i should always show the score. I have modified snake.love for it.
Thank you for your idea, i will think about them.
Re: simple snake
Hi Lafolie,
I am greatly flattered by your evaluation.I just a LOVE/lua newbie...
Anyway, Thank you very much.
I am greatly flattered by your evaluation.I just a LOVE/lua newbie...
Anyway, Thank you very much.
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: simple snake
Yeah, I agree with Lafolie on the speed, I didn't really get far in the game, though I spent a good 2 minutes playing it, making it faster should make it more fun.
Re: simple snake
i'm have no idea about speed.
i adjust speed from 0.04(sec per block) to 0.02, maybe it will be better.0.015 is the fastest on my pc.
i adjust speed from 0.04(sec per block) to 0.02, maybe it will be better.0.015 is the fastest on my pc.
Re: simple snake
You use the value dt which is passed down through love.update. Basically, you should do:bmzz wrote:i'm have no idea about speed.
i adjust speed from 0.04(sec per block) to 0.02, maybe it will be better.0.015 is the fastest on my pc.
Code: Select all
time_based_value * dt
I also added a conf.lua based on your current setup and changed the window size. I felt that the speed of the snake (even updated) was too low to justify such a huge window. Unless you have a huuuuge score you may have to travel an extreme distance, which isn't much fun. I used conf.lua to specify the window dimensions and adjusted your code to read the window size.
Oh, and I added in a little surprise. I have a good reason for doing that, but I hope it helps introduce you to another Löve module.
- Attachments
-
- snake_dt_audio.love
- (536.66 KiB) Downloaded 543 times
Do you recognise when the world won't stop for you? Or when the days don't care what you've got to do? When the weight's too tough to lift up, what do you? Don't let them choose for you, that's on you.
Re: simple snake
Thank you.Lafolie wrote:You use the value dt which is passed down through love.update. Basically, you should do:bmzz wrote:i'm have no idea about speed.
i adjust speed from 0.04(sec per block) to 0.02, maybe it will be better.0.015 is the fastest on my pc.
I took the time to edit your code and implement dt rather than the manual os.time() comparison you were making. The result is much smoother. If you want to adjust the speed, do so moderately, using small values, e.g. speed = 2 will be slightly slower, speed = 0.5 will be slightly faster. I personally feel that 0.75 - 1 work quite well.Code: Select all
time_based_value * dt
I also added a conf.lua based on your current setup and changed the window size. I felt that the speed of the snake (even updated) was too low to justify such a huge window. Unless you have a huuuuge score you may have to travel an extreme distance, which isn't much fun. I used conf.lua to specify the window dimensions and adjusted your code to read the window size.
Oh, and I added in a little surprise. I have a good reason for doing that, but I hope it helps introduce you to another Löve module.
I learned a lot from you. =)
Re: simple snake
It's cool man. I learned some stuff from your code too man. 's all good!
Hate to say but that's what the rep button is for, heh.
Hate to say but that's what the rep button is for, heh.
Do you recognise when the world won't stop for you? Or when the days don't care what you've got to do? When the weight's too tough to lift up, what do you? Don't let them choose for you, that's on you.
Who is online
Users browsing this forum: No registered users and 183 guests