LWJGL16k

Just testing the waters here… when the dust from the 4k compo has settled, would anyone be interested in a LWJGL16k competition? (Picked 16 for the hell of it coz you don’t have to arse around with non-OO coding and daft short variable/filenames so much)

Because JRE users get all this ImageIO and AWT and media player stuff for free I was thinking we might allow LWJGL+JOrbis+DevIL as our platform…

Cas :slight_smile:

The end of the 4k compo is set to “end of feb”, which is still quite far away.

16k. Hm.

How will people use it? How would you use it?

8k classes, some tiny images and some tiny sounds?

Well, it’s enough room to make procedural textures and sound worthwhile… not sure if that’s necessarily a good direction.

Seems like a good idea to me…
But why 16K ? Why not 32k, 48k, or even 64k ?

Chman

Seems a bit pointless to put a size restriction on unless its tight enough to enforce the developer to think in a different way. IMHO thats what makes J4K so interesting.

I’d be all in support of a LWJGL games compo (I’d love to enter) but I think you want to limit on time. Announce, 2 months? - entries. You’d have to take it on good faith that the game had only be in development 2 months tho…

Or simply just have an anual best LWJGL game competition. Though I think tribal trouble is gonna win hands down this year :slight_smile:

Maybe you could go for single developer projects?

Kev

Indeed, I was thinking similar thoughts but with Xith3D :wink:

I think such a competition would be fun, I’d enter for sure. As I am coding my 4k entry, I am always thinking how much nicer the game would look using LWJGL :slight_smile: I’m very annoyed that 1.5 isn’t on Mac yet, as I don’t have a Java high resolution timer and no LWJGL either :’(.

These competitions are quite fun problem solving exercises. The only problem about allowing third party library X, is that it eases the restrictions, potentially lessening the challange. For example, one could code a 4kutil library with a bunch of stuff aimed at making creating games in 4k easier (e.g. the SuperPackME loader) and say 4k-but-you-get-Util.class-for-free, but then you really lose the point of it being 4k to begin with, as the download isn’t 4096 bytes anymore.

Other competitions could be restricted in different ways,
e.g. (pick one):

  • you have to create a game out of a set of 20 sprites
  • you can only have 3,000 lines of code (official java style guide, so no multiple statements on one line)
  • you can only have 50 “if” statements
  • you have to create an asteroids clone
  • you can only use ASCII art to make the game
  • you can only use line art
  • etc…

Software Engineering is about solving problems with the tools you have available and within a given set of limitations (time, size, memory etc). Having a some tight restrictions that you wouldn’t normally have makes it challenging and fun, and also reduces the barriers to enter. I think this is where the big game contest last year fell flat – too open ended, way too much effort to enter with a hope of winning (unless you had something already).

Varying these competitions up a bit could be fun, as different tricks apply. E.g., if going from 4k to 64k, you probably don’t have to worry about declaring constants or embedding sprites in the code and you can have more than one class.

Will.

I wonder whether a time limit would make things interesting - I don’t mean a themed contest with a 48 hour duration like Ludum Dare though.

Using whatever libraries you like, what could you come up with after just one hour?

A mess, certainly.

Kev

Probably, but that’s half the fun! ;D

I wrote Puppytron in 5 hours flat. We had an applet competition at work, and that was my entry. My minions respectively produced a table football game and Asteroids.

I’m thinking that we’d deliberately put a heavy restriction on the APIs used:

  • NO AWT/ImageIO/Swing/etc. Test it by compiling against the Alien Flux VM :slight_smile:
  • LWJGL
  • DevIL
  • JOrbis (as used by Puppytron)
    In fact I can supply a special JVM to compile against :wink:

Now, as for 16kb, I figure that that gives you the freedom to use proper coding style and even include some sound effects in heavily compressed OGG format if you like. It also pretty much limits the time available because there’s only so much you can fit in 16kb.

If we held the compo in time for JavaOne perhaps…

Cas :slight_smile:

…and one thing that annoys me about the 4k compos is that you actually spend more time making things smaller and illegible than you actually spend just writing a game. Programming games is more fun than optimising bytecode!

Cas :slight_smile:

Actually, most of the saving I’ve come across is changing the way I might do something, making me think about different solutions to the same problem… I at least found it quite useful.

I don’t think I’d be as interested if we’re going to have to cut down to the sepcialised JVM. Then I really would doing things in a different way just to match a different requirement. (Although, admitted, in my case I guess it wouldn’t change much).

Kev

It’s not a specialised VM, just a heavy restriction on what APIs can and can’t be used. What we’re trying to do here is promote LWJGL so everyone realises just how much it r0xors :wink:

Cas :slight_smile:

Personally, I belive the popularity + success of the 4k comp is either that people realise everyone else is restricted and so - with their own limited time, or limited skill (different from person to person - it’s “worth a shot without my entry looking completely rubbish”.

or…knowing that it’s not going to take more than X hours of your life, so you probably have time to finish it even with a busy work life?

So it’s not so much the difficulty that matters as the fact there is some constraint on total time + expected quality, even if an easy one.

For instance, I’d generally not bother competing in a comp where I knew i was up against megacorps online or tribal trouble, because I know I simply dont have the resources to make an even half-assed attempt at it (unless I move to a full time job developing java games client-side)

[quote]Just testing the waters here… when the dust from the 4k compo has settled, would anyone be interested in a LWJGL16k competition?
[/quote]
instead of by size (given the fact that LWJGL is bieng used) perhaps limit by some high-level feature, such as “total maximum playtime”? If the whole game takes 5 minutes to play to the end (assuming you finish it) then it keeps the games feasible for time-poor people to enter and sufficiently constrained to keep out mega-impressive games that put everyone else off even taking part.

At the end of the last J4K, I tried to start a J4K3D (you could use any of the major Java 3D APIs).

No one submitted an entry. :’(

I’d love to see one take off ;D

Trying to do 3d in 4k is kicking my ass. Vertex and triangle indices eat loads of storage.

Consider the simple cube:

8 verts: float = 32 bytes
12 triangle indexes; int = 48
total: 80 bytes.

16k with opengl would allow alot more breathing room for sure. Semi interesting geometry, simple textures, procedural textures, smooth shading, lighting. You could even indulge in an actual matrix class!!!

To me actually using a 3d api wouldn’t be as interesting though.

Thats data size at runtime not class size.

If you used casted floats for your indexes you’d have:

private float[][] pts = new float[20][100];

for a hundred points. Which class size isn’t going to be anywhere near that.

Kev

Besides, I’d be using bytes for the coordinates. However - 3D really does rather raise the bar far higher than anyone really wants to bother with for such a weeny compo.

Cas :slight_smile:

I think that the reason we have this thread here is that the 4K compo has been quite successful. The reason for that is probably to a great degree that almost anybody in the forums could create something in 4K and not be ashamed about it. We can always blame ___ on the 4K limit ;D And it isn’t a huge undertaking to make an entry. That is at least why I already have made (started) 3 entries. And it is really great to see the entries, since there are many great ideas and good focus on gameplay.

On the other hand I feel that it is a bit of a shame to waste so much time on byte hunting and making code worse just to make it in 4K. I have a (more than) full time job, and I don’t really think that I will have much use for the knowledge that I get. Trading readability and speed for size is the opposite of what you want to do in 90% of the time.

Going full out and allowing any size could be bad, since most would be too scared to enter since we know that we would get our asses so badly beaten by two or three guys here :wink:

I would personally like to see a two week compo, where there would be some limitations like have to use certain images, objects and maybe a general broad theme (have to involve kangaroos or something :slight_smile: ) It would have to be fairly limiting! I’d also love to see it as open source. I have not really gotten into any of the game libs yet. If there all of a sudden would be 10 compliments to Kevglass’ Space Invader 101, I think that it would help a lot for a lot of ppl. With that limitation we might even drop the mem limit? We would have a fairly levelled playingfield (as long as theme limitation goes well, the really hard part), wouldn’t be too much work, because of the time limit, and we would still have an excuses for not everything being perfect, code could actually look pretty OK, and games as well (or at least not horribly uggly as my 4K entries :stuck_out_tongue: ) Reducing the points for gfx and sfx in favour for gameplay, to make it fair for us untalented ppl. Maybe also points for how well it involvs the required images, sounds and kangaroos?

I think that it would fertilize the ground for more Java game dev and help everybody here.

Would have to perfect that kangaroo idea… More ideas?

Sorry for rambling on like a mad man. :slight_smile:

Yes, casting bytes… so long as values are between -128 and 128. :o