quadtree

LD20

I’m in!

Hi, this will be my first Ludum Dare, so this should be interesting!

Platform: Java Applet

Tools:

  • Eclipse
  • GIMP
  • Audacity
  • SFXR
  • LMMS

I will also be using a custom game base library I call SGF, for the curious it can be downloaded here but its pretty basic.

Some progress

Here’s a screenshot of what I’ve got so far. Its an adventure game that I’m calling Robot Village.

Screenshot of my game

Done

I’ve finished my Action-RPG, Robot Village. If I had it to do over again, I’d try to make it a bit longer.

Play Robot Village.

LD21

I’m in!

This is my second LD, after LD #20, which was great fun, so I’m really looking forward to getting started.

Technology: Java Applet

IDE: Eclipse

Sounds: Audacity and sfxr

Graphics: GIMP and Blender

Physics: JBox2D

Base Code: Simple graphics/audio/networking library for applets. Downloadable here.

Current status

All it needs now is a title screen… And maybe some sound.

All done

I’ve just finished my mulitiplayer roguelike, Lost in the Depths.

Making this one multiplayer was an interesting experience, but unfortunately I couldn’t fix some of the lag issues. I was also hoping to make an offline-only version but ran out of time. I just hope there aren’t too many connection issues.

http://www.ludumdare.com/compo/ludum-dare-21/?action=preview&uid=4024

Lost in the Depths – Postmortem

This is my second Ludum Dare entry, my first being in LD20. For this one, I really wanted to try making a multiplayer game, as I it seemed like an interesting thing to do in 48 hours. My concept was a roguelike game where the player was part of an adventuring party who must escape from a dungeon after things go wrong. Because I figured many people would end up playing the game solo, I also wanted the ability for players to carve messages into the floor (an idea straight out of Nethack, I’ll admit). I was thinking that maybe people would carve hints or some such.

What Went Right

The Graphics/Audio/Networking Library
I was using a modified version of my base code from the last Ludum Dare, with a networking component I grabbed from another one of my projects and added to my base code. It generally worked really well, with few notable problems. I worked out most of the kinks last time (mostly related to applet startup/shutdown). I did have to fix a single performance issue with the renderer, though.

Server Performance
My main game server is running on a small virtual server, and I was worried that it would run out of CPU if more than a few people connected. But so far, it has handled the load very well. There also have been no problems with bandwidth on the server side.

Backend/Threading/etc.
I went with a weird architecture that had a separate thread for each zone (which was a bit pointless in retrospect as my server only really has one core). Still, I’m happy that it works without crashing excessively. Even with a few players connected CPU utilization is low on the server. Also, I was a bit concerned that the communication between the threads could lead to some kind of deadlock, but that doesn’t seem to happen, which is good.

Pathfinding
I wanted to give the player character the ability to path around obstacles, which would make the game more user-friendly. To do this, I made a simple implementation of the A* pathfinding algorithm. Because the pathfinding was server side, I was worried that it would overload the small server. But it actually works pretty well with no noticeable stutters. There is the slight issue that you can order it to path to places where the entire path isn’t on screen, though. Using this trick a player can find paths to anywhere onscreen, even if the actual path runs all over the level.

What Went Wrong

Responsiveness
As any good UI designer will tell you, a good GUI must be very responsive, aka it must respond immediately to user actions. To ensure this, most multiplayer games use client side prediction to create the illusion that the game responds instantly to player actions. However, to simplify things, Lost in the Depths uses a “dumb client” model where all game logic is processed on the server side, and the client serves as a sort of glorified renderer. As a result, any action requires at least double the ping time to the server before the user sees any response. This problem is exacerbated by the fact that the server only runs 4 logic ticks per second, so the request must wait for the server to get to the next tick before it processes it. Finally, there is an error in my code that delays all actions by an additional 1 tick (250ms), which does not help either.

Testing
My design for this game was somewhat complex, probably too complex. I did not have enough time to completely test and balance all the components, and as a result there are several balance issues. Plate armor is grossly underpowered, and robes are probably overpowered, just to name a few. Another issue came up on the last day when I was about to test multiplayer. The problem, of course, was that there was only one of me so I couldn’t fully test actual multiplayer, in an allegedly multiplayer game. As a result, the multiplayer game itself isn’t very well balanced.

Level Design
I’m fairly happy with most of the level design, except for Level 2, the Labyrinth. It is supposed to be a bit of a confusing maze, but the result is way too confusing, and there are too few monsters, making it boring to play. This is exacerbated by the lack of an auto-map, leaving players wandering.

Artwork
In my LD20 entry, a lot of the main graphics were made in Blender, and were of robots, which are a lot easier to draw then people. In this game, I relied more heavily on hand-drawn graphics, and unfortunately, I’m not very good at drawing. It also didn’t help that I ended up making most of the graphics last, and at 3 in the morning.

GUI
Some parts of the game require text input, and my plan was to use the Swing part of Java to get this input. The problem was my graphics library was based on AWT and wasn’t designed to work with other GUI components. This wasn’t a showstopper, but it did take a few hours of tweaking to get this right.

Overall, it was an interesting experiment, but I’m not that happy with how it turned out. Working on a complex entry like this was fun even if the result is a bit sluggish. If I were to do it over again I would simplify the game a bit and focus more on tweaking the network performance to make the game more responsive.

LD22

I’m in!

I’m in! This will be my third Ludum Dare, after #20 and #21. I’m hoping this time to make something compatible with both PC and Android, so getting the UI working should be fun.

Tools:

  • Language: Java
  • Main Library: GDX
  • Sound: sfxr
  • Graphics: Blender, GIMP
  • IDE: Eclipse

I can’t wait to get started, and I’ve got my warmup entry here.

Some progress

Graphics and the editor are working, now I just need some content and stuff to interact with…

LD23

I’m in!

Man, its been a hectic week but I’m still planning to enter. This will be my fourth Ludum Dare, and its been more fun each time I’ve done it!

Tools:

  • Language: Java/Javascript/HTML
  • Engine: PlayN
  • IDE: Eclipse
  • Sound: Audacity/sfxr
  • Graphics: Blender/GIMP

I also may be using this font renderer I made.

Getting there…

I’ve got about seven things left on the to-do list to finish this. Anyway, here’s a screenshot of our wannabe Space Imperator getting a warm welcome from a large planet.

All done

My entry, Space Imperator is complete and uploaded. I was really hoping to get the HTML5 version fully working, but in the end it just had too many weird incompatibilities. Still, the Java version works great.

See it here.

LD24

I’m in!

This will be my fifth LD (my first was LD20). Can’t wait to get started!

Tools:

  • Language: Java
  • IDE: Eclipse
  • Framework: PlayN
  • Sound: sfxr, Audacity
  • Graphics: Blender, GIMP
  • Physics: Box2D

Some Progress

Alright, here’s what I’ve got so far of my game, which is tentatively titled “Petri Dish Empire”. Here is my (partially successful) attempt to breed something that is actually dangerous.

 

 

All done!

My entry, Empire of the Petri Dish, is done. I like how it turned out, especially how the conversion to HTML5 worked out well.

Comments

26. Aug 2012 · 22:56 UTC
um, I don’t get it… also, bug. if you pull up the help screen again and try to remove it by clicking. it does not go away. using HTML5 vers

Empire of the Petri Dish – Post Mortem

I’ve been waiting to post this until after judging was over so that I could post some hopefully interesting charts derived from my server’s access logs.

This was my fifth LD48 entry. I’ve entered every LD48 since LD20. I probably slacked off more this time then on previous ones, but that was largely intentional, as I tried to come up with a design simple enough that I didn’t have to rush too much. I think it worked out well, as I actually managed to add in music this time.

What Went Well

Analytics

Since the game was implemented in HTML5, all resources were loaded on demand using separate HTTP requests. While this would slow it down for a big game, this one didn’t need too many assets. This also had the advantage that I see in my server access logs when a resource is loaded, like the win screen. See below.

PlayN

Against my better judgement, I decided to use PlayN again even though last time I got burned when I discovered compatibility problems late in development. Specifically, I’d been testing using native Java, and when I switched over to HTML5 compilation I discovered that transformation matrices weren’t compatible with hardware accelerated WebGL at all, and I had to largely abandon the HTML5 version due to time.

This time, I carefully tested the HTML5 version before the very end, and I avoided transformation matrices altogether. The HTML5 version works as well as you could expect, even in IE9, although of course it is extremely slow compared to the native Java version.

GUI

Compared to my previous efforts, I think this one’s UI turned out fairly well. It has better highlighting and visual/audio cues as to what will happen if the user performs some action. I also mostly managed to keep it simple, and avoided huge help pages with dozens of controls (unlike some of my previous entries).

Evolution

Ah, the most important thing, right? The way the bacterium’s genes work is this:

  • Each creature has a set number of arms (which is actually a floating point, however a creature with 2.3 arms will just have 2 for gameplay purposes).
  • Each creature has a genome, consisting of an arbitrary number of genes, each one representing one “segment” on its arms. Each gene has 5 attributes, each itself a floating point:
    • Length
    • Width
    • Type: A number, usually from 0 to 5. It is rounded to the nearest whole number, determining the piece type:
      • 0 (Or anything outside the range): Structure
      • 1: Engine
      • 2: Solar Cell
      • 3: Armor
      • 4: Weak Structure
      • 5: Weapon
    • Angle: The angle of this piece relative to its parent’s angle
    • Backtrack: Allows branching by causing this piece to move its base toward the center by this many segments before branching off. So for example backtrack 1 would create a Y shape.
  • When a new creature is created, its stats like arm length and number of arms are just averaged from its parents. Gaussian (bell curve shaped) random numbers are added to these averages. Then for each segment it gets a random one from all its possible parents. The inherited segment’s genes are also altered by Gaussian randomness.
  • The damage, health, solar collection, engine power etc. of each component is determined by its mass, which is close to width*length.

The end result gave a lot of variety in the creature types, and I’m pretty happy with it.

Music

Considering that it was randomly generated by Wolfram Tones, I’m pretty happy with how the music turned out. The only small thing is that the music can seem a bit dissonant with the tone of the rest of the game at times. Another oddity was that the 64-bit JRE refused to load the music file, saying it was too big. The 32-bit JRE had no trouble, though.

What Went… Less Well

PlayN

Again, PlayN was something of a mixed bag, especially because of its default build system, Maven. When Maven works, it works really well but its error messages can be a bit incomprehensible when it fails.

Additionally, PlayN’s severe performance problems in HTML5 mode forced me to repeatedly scale back the size of the game world. I suspect this has a lot to do with JavaScript being slow.

AI

The game’s AI isn’t very good, although creating good AI for a game where the structures of creatures is so random would be a bit difficult. Still, I would have liked to make better AI for both enemies and player controlled bacteriums.

The Name

This was the first LD48 entry I had trouble naming. Originally, it was going to be called “Petri Dish Empire”. You can still see this name in some of the source code, and in the URL on my site “/pde/”. Eventually, I decided this sounded uninspired and I switched to “Empire of the Petri Dish”, which while sounding a bit better is a mouthful. It was only after the compo was over that I realized I should have named it “Bacterium Imperium”.

Testing and Balance

I noticed partway through development that weapon pieces were overpowered, so I made them more expensive, but it wasn’t really enough.

Another problem was that if the player wasn’t aggressive enough, the enemy bacteria could grow out of control and make the game very slow. This is why I added the solar cell cap, but it was a kind of rough change that I added late in development.

Late in development, I discovered a nasty exploit where you could use the fact that you can create a bacterium anywhere to put a small, heavily armed but immobile bacterium right in the core of an enemy, killing them quickly and easily. To fix this, I made it so that if on creation a bacterium intersected another, it was pushed away from the other one. If it still intersected others, it was pushed away until it did not, moving farther each time. The problem was that I just normalized the difference vector between their positions and then multiplied it by an increasing multiplier. Thus, in the degenerate case where they were right on top of each-other, it would enter an infinite loop. The issue was only discovered after the compo was over, so I couldn’t fix it in the compo version. Judging from the comments, it doesn’t look like a lot of people hit this issue, luckily.

Analytics

I went back through my server access logs to see if I could make some interesting graphs of how people played the game. Here’s what I found:

Here’s how people downloaded the two versions (The native Java one, and the HTML5 one). It shows both which ones they downloaded and in what order they did:

In total, 90 people viewed the HTML5 version. However, 16 of them went on to download the Java version, so I suspect the HTML5 version didn’t work for them. Of the remaining 74:

Of the 9 people who won the HTML5 version, I measured the time from when they first requested the Javascript (the first thing that happens when you load the game in a browser) to when they won:

Finally, the game lets users select their screen size. While users can select any size, they’re encouraged to select a size just under the viewable area of their browser. Here are the sizes people used (The size of the bubble indicates the number at that size):

 

All in all, I’m pretty happy with how it turned out, and I hope you all enjoyed playing it!

For the curious, there is also a post-compo version with some alterations.

 

LD25

I’m in!

This will be my 6th Ludum Dare. Every previous one I did with Java, so I think it’s time to try something new.

  • Platform: Flash
  • IDE: FlashDevelop
  • Framework: Starling
  • Physics: Box2D
  • Graphics: GIMP, Blender
  • Sound: Sfxr, Wolfram Tones

Good luck everyone!

Progressing!

ss1

 

The player can now move and cast spells in my game, Paradise Island. Here the Dark Lord greets the inhabitants of the island.

All done!

ss1

My entry, Paradise Island is complete! In it you play as the evil Dark Lord and must conquer the peaceful utopia of Paradise Island, and then hold off the Knights of Light with various traps, turrets and spells. It s a bit shorter than I would have liked, but I tried to keep it from getting repetitive.