Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

LuaDigger - game inspired by Digger

edited January 2012 in Code Sharing Posts: 6

Hi,
I wrote LuaDigger for fun and Lua language learning. I tried also some classic algorithms for path finding and implemented them in Lua. Check out the result. Some features didn't work yet, most notable - bomb doesn't kill

image

you can try this classic arcade game, from here
https://github.com/pelegrin/LuaDigger

p.s. This is my first encounter in Lua. Language is nice and simple. Credits to Simeon for his particle engine, that I took from twolivesleft.com

Tagged:

Comments

  • SimeonSimeon Admin Mod
    Posts: 5,387

    Fantastic work, @pelegrin! I love digger.

  • Posts: 2,820

    It's absolutely awsome... Love it! Mabey add iCade support? (And if someone who owns one like @Bortels could add some stuff to the forums on wiki an about how to support that in your app, that would be great)

  • @Zoyt I think iCade support should be in Codea. In IONAudio documentations was mentioned Key Up and Key Down events. If Codea pass it, no problem to use it.
    So question to Simeon

  • Posts: 2,820

    I think it acts as a BlueTooth keyboard, but I'll run that by @Bortels and ask him to post something about it on the Codea FAQ. He owns one. I'll KYP.

  • SimeonSimeon Admin Mod
    Posts: 5,387

    This is great. Bit Invader on iCade

  • BortelsBortels Mod
    Posts: 1,557

    The keyboard support for 1.3 works beautifully with the iCade.

    http://home.bortels.us/decodea/results/iCade.html

    Yes - the screen shot is boring. It's hard to show action. The stick moves and the buttons light up. I was going to make a movie, but real life is cramping my style.

    The demo has an "iCade" class, which works like this:

    i = iCade()  -- in setup()
    
    if (i.up) then print("The stick is pressed up") end
    if (i.b3) then print("Button 3 is pressed") end
    

    I honestly don't think the API could be simpler. :-)

  • Posts: 622

    Digger was worth taking the time to get

  • Posts: 118

    Cool! I love the fading you used to transition between screens!

    At the end of the game you are supposed to hit 'reload' to play again, right? Small improvement would be to restart when the user taps the end screen.

  • edited January 2012 Posts: 6

    Yep, also I had plans to add 3 more type of bugs (you can see it in source code), one particulary interesting is guard who moving on predefined path, but can catch you if you come closer. And a must have feature for that's type of games is Editor for games level.
    Fading was implemented via closure, that is a very nice Lua feature.

  • Posts: 2,161

    I love the idea of adding bugs.

    (Of course, I know what you mean ...)

  • Posts: 118

    @pelegrin Thanks for pointing me towards closures. I only have been using Lua for a couple of weeks, and I wasn't familiar with it. Cool concept!

Sign In or Register to comment.