• interested in more? sign up to the newsletter

     

LibGDX-ing it

Tweet about this on TwitterShare on RedditShare on Facebook

sg_gameoverstats

Last week was a hugely productive week, changing the looks of the game completely by adding a light system, adding a lot of stuff, and making big decisions.

The big decision, business wise, is to create this game fully in LibGDX. My Steam games are already running on LibGDX, but I didn’t have the guts to base also the Android and iOS releases on it. Having done some early tests with the latest release and tools, and doing some struggles with Apple’s provisioning profiles in combination with LibGDX, it was pretty cool to see my current build (which so far was tested on my Mac) run perfect on my Nexus 5, Android TV, and iPad.

The reason I haven’t made the step before is something I explained before, so I’ll keep it short. In the years I’ve been doing this professional, I’ve seen many game engines and libraries come and go, and I have seen many developers struggling to pick them selves up once their game engine stops working correctly with newer hardware.

For a hobby dev that’s not a huge thing, just take some time to learn new tools.. but if your livelihood depends on creating and releasing games, it’s slightly more important to have tools that work and not having to take out time to learn new tools and completely change your work-flow.

I now decided to take the step because I got comfortable enough using LibGDX for Steam releases, and still “owning” my own code. I actually use very little of LibGDX except the core stuff, which replaces my own cross-platform framework (handling graphics, input, audio and program-lifespan). If I ever need to switch to something else, or fall back to my own stuff, it’s still do-able.

Meanwhile I don’t have to do much porting anymore, and I get a lot of power that LibGDX does offer over my own code, which brings us to the next news:

Space Grunts now shines bright! I’ve been adding a cool light system lastweek, first trying out a combination of LibGDX’s box2dlights and box2d.. which ran nice on PC’s, but not so nice on my iPad 2.. Luckily I only wasted about 8 hours to get all that setup and running (which is pretty fast and smooth), so with some hints from Simon over at Robotality I started looking into doing a quick and hacky way of lights and rewrote the full light system the next day in perhaps just 2 hours.

The trick is just rendering alpha-blended “light” sprites onto the screen in different colors, shapes and sizes. It’s extremely fast, looks absolutely awesome on screenshots, and runs smooth on all devices tested without any change in FPS. I’ll write some techy-blog about it soon when I get some time.

The biggest thing is to not overdo it with lights and colors, but that’s just all design (I have seen games that use it way too much).

sg_warpers

Space Grunts has now entered that state where I basically just keep adding things to make it bigger and better.  The core gameplay is there, the game is fun to play, and it has a lot of content. There are literally no two games the same with everything being procedurally generated, a large and growing collection of items to find and use, and more and more enemy types being added.

Some of the stuff I’ve been adding the last few days are: short-range and long-range teleporters, protective boots to walk cross acid, game-over screen statistics, warper-enemies which teleport in-and-out around you, breakable surroundings, great mouse-controls for PC gamers, time-distortion devices (everything stands still while you can walk X steps), and the light system obviously, and improved the weapon system.

I still have a list of stuff to add, but at this pace I’m very hopeful to release in September.

Right now I am thinking about doing a Steam-first release, which allows me to do some quick updates, patches, fixes, improvements and make sure the game is all it can be before I release it onto the Appstore, Google Play and other markets.

The ChromeOS version will be without the light-system, most likely, and released later possibly after having done at least one or two bigger updates to the core game.

Bookmark the permalink.
  • Hi, fellow Dutch gamedev here, although not (yet?) as professional as you ;) LibGDX is great — it’s actually pretty mature now, and has a good community behind it. It’s nice that it’s only partly a framework, but still largely a library, in the sense that you can pick and choose the pieces that you want to use, as you did.

    • yep LibGDX is a good option for many devs out there

  • mataronasd

    apart from the lighting effect with box2D lights, how do you achieve the slowly fade in light effect when entering a room ?

    • not using box2d anymore, using a much faster fake-light system that looks about the same but doesn’t have dynamic shadows.

      the room fading is just fading in the tiles that make up the room you just entered (from alpha transparency 0 to 255 ). nothing difficult, and nothing with box2dlights :)

      • mataronasd

        “much faster” than box2dlights ? That’s surprising. How come you made that decision ? I found that box2dlights are pretty fast.

        • oh box2dlights was fast, but slowed down on iPad 2 and older android devices.
          the fake light system is basically rendering alpha-blended sprites in different colors and sizes.. which is, as you can imagine, a lot faster than casting light-rays and calculating shadows

          • mataronasd

            Is that library open source ? I’d love a link to check it out out of curiosity. Thanks for your reply by the way ! I loved all of your games. Very straight forward, great graphics and very nostalgic style over all. You inspired me to create a game like this one. I’m working on it for 2 weeks already.

          • still trying to write a blog post about it, but haven’t found the time for that :) it’s not really a library, just some very simple rendering tricks that look awesome as a result.
            will eventually blog about it! ;)

            good luck on your game! it’s a fun genre to work in

          • Carlos Eduardo

            Did that blog post come out yet? I’d love to read that! Amazing work, cheers.

  • oasix

    Great Work !!
    Why did not you choose Unity 2D (Which have many advantages) ?
    To stay within the context of a framework free, open source ? Or it was representing a too big investment to learn it ?

    Thanks