LD17 April 23–26, 2010

LuaGL performance fail!

For obvious reasons, it’s not a good idea to use immediate mode (gl.Begin() gl.End()) with an interpreted language (lots of slow function calls).

I therefore tried to use vertex arrays, since it’s apparently recommended by the Redbook of OpenGL. So be it. ‘Twas fine, until I realised that LuaGL would flatten arrays of vertices at every frame, which is slow as hell.

I therefore transfered that part of the code to pure C. Once I have my nice mesh in Lua, I flatten it once, copy everything in one C array, and then uses this one with glDrawArrays. It’s a looot better.

However, I wonder if my EeePC is really a 3D  beast, because the following scene:

200*200 heightfield, with 2 triangles per cell --> 80000 polys, rendered twice (filled, outlined)

200*200 heightfield, with 2 triangles per cell --> 80000 polys, rendered twice (filled, outlined)

runs at about 4 fps. Laaaame.

OK now I never did 3D before, so maybe I’m just not doing it rite (insert kitty picture).

  • Vertex Arrays not supposed to be used like that? For now I have all the coordinates of all vertices of all polys one after the other into a 1D array of size (n tris * 3 vertices * 3 coordinates). So lots of vertices are repeated. Is that wrong? I see we can also use glDrawElements() to avoid repeating vertices, but that implies using an array of vertex indices. Would that be faster?
  • Better technique than vertex arrays?
  • Just plain too much polys, try to do level of detail, or manual clipping before drawing?
  • Get rid of the nice outline (um, which gives as about 5 more fps…)?

For now I’ll just reduce the size, try to get some proper terrain generation, and gameplay into that. Cause yeah, it’s supposed to be  a game at some point…

Tags: screenshot

Comments

24. Apr 2010 · 11:09 UTC
If you don’t need to deform your mesh, try using display lists.
26. Apr 2010 · 13:42 UTC
Another idea would be to use your viewing frustrum to clip out any geometry that doesn’t need to be sent to the video card.

Lunch – check!

I wrote a simple TODO list:

todolist

I’ve also done some coding, here is what I’ve got so far (move using cursor keys):

screen02

And as a reward – delicious chicken with potatoes:

lunch

Tags: flash, foodphoto, progress, screenshot

Comments

zomba
24. Apr 2010 · 12:15 UTC
you have a penis on your table

Why stuff always looks better on my mind?!…

Enough said:

screen02.jpg

Just finished the walk cycle of my main character, and it is UGLY! :\

Took me almost 2 hours to come up with something this horrible… I wish I could just steal art from some place so my games don’t look so terrible!

Anyway, now to build some “island”, “cloud” and “ground” sprites so I can do the actual game work… I’ll get back to this later if I find the time…

Comments

hdon
24. Apr 2010 · 11:35 UTC
Hard to say how it looks from the still image. It looks okay to me.

Pickup refactor

I realized that my “tags” (integer identifiers on each actor) would benefit from being combined with their position data, rather than put off in a separate component.

After another brief bug hunt(this one caused by there being two sets of identifiers for the player and pickup, one in the old tag code and one in the tile code) this is now working and the rogue-like collision, which I’ve made part of Fireball’s libraries, is that little bit more useful.

Now, I should really stop dicking around with tech. I’ve got a game to write :(

Comments

hdon
24. Apr 2010 · 11:37 UTC
What is the benefit? One down-side is that your identifiers would become invalidated if the actor’s position changed. Do you then have to propagate the new position to all actor identifiers?

Collect & Protect: Let’s lunch!!

Ok. 6 hours of almost non-stop programming… finally I can lunch!

Now the progress of the game…

The title screen

The title screen

The game has the titlescreen completely created, and the music too. It also has the character drawed and the island’s terrain tileset made.

Here you can test what I’ve done: http://aberustudios.co.cc/games/CollectAndProtect/

Tags: 2D, and, as3, collect, flex, Flixel, journal, protect

Comments

24. Apr 2010 · 11:08 UTC
TypeError: Error #1010: A term is undefined and has no properties.

at co.cc.aberustudios.AstUtils::AstPrerollState/_setCurrentPreroll()

at co.cc.aberustudios.AstUtils::AstPrerollState/_addOneToCurrentPreroll()

at co.cc.aberustudios.AstUtils::AstPrerollState/update()

at org.flixel::FlxGame/update()

TypeError: Error #1006: value is not a function.

at co.cc.aberustudios.AstUtils::AstButton/update()

at org.flixel::FlxGroup/updateMembers()

at org.flixel::FlxGroup/update()

at org.flixel::FlxState/update()

at co.cc.aberustudios.AstUtils::AstState/update()

at co.cc.aberustudios.CollectAndProtect::TitleState/update()

at org.flixel::FlxGame/update()
hdon
24. Apr 2010 · 11:39 UTC
I *love* the camera tweening! It already feels a little nautical, but I think it will feel even moreso if you add a subtle bobbing motion to the camera position!

I have a couple of ideas…

Both of which are pretty derivative, it must be said;

– Pirates Roguelike

– Tactical turn based variant of carrier command

As the former would be a client-side javascript game, and the latter as a proper web app, there’s a lot of divergence in the development process.

While I vacillate, have the sum total of my island-based efforts so far.betterisland

Comments

hdon
24. Apr 2010 · 11:40 UTC
beautiful concept art!

For some reason, my visual text editor for this site broke, along with just about everything else on the “new post” screen. Anyhow, a screenshot of what I have now.
Fully functioning island puzzle game. Huzzah!

Comments

hdon
24. Apr 2010 · 11:40 UTC
Tell people what browser you’re using!
24. Apr 2010 · 18:10 UTC
square = island

Font

It was important for me to use this font in the first game I have attempted to make in over a year. I received this font in the final email I will ever receive from an important friend of mine.

Isle Politic

Rest in peace

Comments

Hempuli
24. Apr 2010 · 11:08 UTC
Aww! How sad to hear this. ;(

Pincer – multiple levels

I implemented a win condition(touch the “end dock”), 8 (test) levels, and a level skip key (/). The basic framework of the game is almost done – just needs a title and a win screen. Progress!

Comments

hdon
24. Apr 2010 · 11:41 UTC
Kudos!

Mine’s Sorta Playable

Or at least you can swim around and collect some stuff. There are some graphics. Obviously, I haven’t yet created player art. Click the screenshot to try it out:

Gregory Weir's WIP screenshot

You’ll need to click on it to give it focus. My last WIP had control issues in Ubuntu; I have no idea how to address these, so they’re probably in this version too. Suggestions are welcome.

Comments

hdon
24. Apr 2010 · 11:42 UTC
Wow I love the undewater movement dynamics! It feels like holding an item underwater in Super Mario World!

What I have right now

I’m working with Game Maker 8 and I have done:

  • Main Menu
  • Level Selecting Menu
  • A save system for the game
  • Platforms engine

The graphic style will be “retro”, with 200% zoom, as many recent flash games.

I hope I’ll post an image soon, good luck!

Comments

24. Apr 2010 · 11:17 UTC
Good luck!! =D
hdon
24. Apr 2010 · 11:42 UTC
I’m using 4x zoom on both sides, so, 16x zoom!

Got an idea

Got an idea, finally.. Been dabbling with F# and SlimDX in the mean time. I ported the simple SlimDX triangle example from C# to F#. Shortly thereafter I decided to ditch SlimDX completely; 3D just takes too much time to make properly. So I’m now working with F# and WinForms and normal .NET 3.5 runtime should be enough in the end. It will be interesting to see how well the game runs as I’m planning on doing some fluid dynamics and stuff.. :)

Tags: LD17

Some progress…

Been sorting out a camera system, and making the “islands” & sea look a bit nicer.

islands

Tags: screenshot

Comments

24. Apr 2010 · 11:31 UTC
that’s freaking amazing… looks awesome!
24. Apr 2010 · 11:36 UTC
Yes, this looks absolutely fantastic. Can’t wait to see how it turns out!
hdon
24. Apr 2010 · 11:43 UTC
nice colors, but you still need more island-y parameters methinks
mattdev
24. Apr 2010 · 11:48 UTC
hdon: yep, going to start doing that now :)

Clouds!

TitleScreenClouds

Fiddled with my particle generator to get some clouds that more or less work the way I want them to.  I should probably start making the actual game part of the game now.  I seem to have spent most of the time so far getting the title screen right…

Comments

hdon
24. Apr 2010 · 11:43 UTC
wow you have some talent with watercolors!
24. Apr 2010 · 13:12 UTC
Looks great.

LD48_17_2

Slow progress, but some progress.  The heightmap is now ‘island-ized’, and I can run around it in first-person. It desparately needs a sky and some water

Off to a BBQ soon, so I’m going to lose the most productive LD-ing time, the saturday evening…  Not sure if anything will come of this one…

Comments

hdon
24. Apr 2010 · 11:45 UTC
if you can’t finish, i hope you’ll stick around and vote on everyone else’s entries :)

We have a floating gang of islands

Regalia

Comments

hdon
24. Apr 2010 · 11:44 UTC
That looks sick dude, totally sweet
Mstrp2ez
24. Apr 2010 · 11:50 UTC
Thanks mate! You are right, i will have to do something about them fonts..

Ground sprites done…

At least my ground sprites don’t look all that sucky…

screen03.jpg

Now I need to get the wizard moving on these, jumping and falling, with camera tracking… the usual stuff for platformers…

Comments

hdon
24. Apr 2010 · 11:45 UTC
skylands

Misc. LD17 game ideas

Arne's LD17 concepts

Arne's LD17 concepts

I was sleeping when the ‘Islands’ theme was announced for LD17, but now I’m awake and throwing ideas around. My first ideas felt too derivative, so I decided to go for something more exotic in the end.

Basically, you’re playing a large floating creature (an island of sorts) who raids islands. The creature can abduct human slaves which it uses for labor. The slaves can build factories, turrets etc on the back of the creature. As the raids go on, the island inhabitants get more and more upset, and defensive forces around the islands grow larger.

The strategy of the game is to figure out which islands to attack, since they offer different resources and different defense. A more developed creature will be able to grab more loot per raid, but the opposition will also be tougher later on.

The turrets could go in three groups (A,B,C) which can be fired individually. For example, the player can choose to put medium distance flak in one group, and long distance sniping in another. Aiming is done with the mouse. Each level (island) has a certain scroll distance to go. During the scroll, the creature is attacked by various enemies. They vary in terms of damage type (some might kill population), movement type, hit points, defense type, bullet trajectory, etc.

Comments

24. Apr 2010 · 11:46 UTC
awesome concept sketches!
hdon
24. Apr 2010 · 11:48 UTC
Your work reminds me a bit of the itchstudios guy. Is Koji Kondo going to score this? 😛
24. Apr 2010 · 12:05 UTC
Thanks!
hdon
24. Apr 2010 · 12:15 UTC
:DDD
24. Apr 2010 · 13:36 UTC
I wish I could draw
24. Apr 2010 · 13:40 UTC
It seems like you have to buy the songs that you make with MusicShake, and Wolfram has a pretty restrictive license :/ Also, I don’t understand the GarageBand interface.

Pincer – projectiles

Now I have some shooting action going. The projectiles spawn, move, and despawn correctly. I probably still want to add the “two steps per turn” thing though. It just seems like it would make the puzzle aspects more engaging to have to calculate relative speeds like that.

Build is up. Arrows to move, space to pass a turn, / to skip levels, WASD to shoot.

Comments

hdon
24. Apr 2010 · 11:46 UTC
man you guys blog at the speed of light! i can’t keep up reading everyone’s blog!

Graphics

screenshot102

At least I have some graphics right now. I don’t know how to proceed, nor do I have any idea as to what kind of a game I will be making.