It's all in your head, Part 10

The only place you'll ever hear the truth
User avatar
Chris
Introversion Staff
Introversion Staff
Posts: 1172
Joined: Sat Nov 25, 2000 7:28 pm
Location: Cambridge, UK
Contact:

It's all in your head, Part 10

Postby Chris » Mon Mar 24, 2008 8:43 pm

Continuing the topic of user-made content, let’s talk about Map Editors. Ultimately if we want people to be able to make content for our game, there will have to be a map editor and there’s very little doubt that it will be clumsy, difficult and awkward to use, and fairly unintuitive. This may sound harsh, but try using a commercially available map editor like Hammer or UnrealEd, or a Pro tool like 3d Studio or Maya. And let’s be fair about it – anyone who has made a map using the Darwinia map editor will know we’re no better. What they all are is _powerful_, what they are not is user friendly. We have a map editor for Subversion, and true to form it’s very powerful, and not very user friendly. Here’s a picture of it displaying a map imported from Doom.

Image

A couple of weeks ago I had a very strong image of a particular type of map editor for Subversion, that would be extremely easy for me to create, and (far more importantly) extremely easy for pretty much anyone to use. I was thinking about older games like Dungeon Keeper, and newer indie stuff like Dwarf Fortress, and they don’t bother with any complex geometry – they restrict the whole game world to squares, and do everything on a grid. It’s like drawing on graph paper, and every square can be empty or it could be a wall, or water, whatever. Initially this might seem extremely limiting, but both of those games manage to exhibit lots of possibilities to the player and don’t feel particularly restrained because of their grid like nature. I decided to run with this concept for a while and threw together a simple graph-paper prototype in a few hours.

Image

It’s actually a lot of fun to use, and you can build quite complex geometry extremely quickly. Left clicking/dragging creates a room, ie an empty space with a 1 square wall around it. You can hold the shift key to fill the area with solid wall, and you can hold the ctrl key to delete whatever is in your dragged area. You can just left click on any square and doodle freehand if you like. In a possible future version, you could rotate the camera to be facing one of the walls and you could use the same mouse moves to cut out a window, a door, whatever you wanted. This system could also be easily extended with 45 degree angles, so it doesn’t have to be locked down to a grid. Dead simple, lots of fun to play with – both excellent properties of an editor designed with user-made content in mind.

I felt this was a pretty good prototype, but I could already see the technical limitations. Lets say for example you have a grid of 100x100, and each cell represents 1 metre square, that gives you 100 square metres, but the bad news is that all your walls have to be one metre thick. I’m not currently planning on setting the game inside NORAD or inside a dwarven fortress, so this clearly isn’t acceptable. But if you make your cells (say) 10cm square, then a 100x100 grid gives you just 10 square metres to play with, which isn’t big enough for anything. Why is the grid limited to 100x100? Because we’re rendering the world on a cell by cell basis, a 100x100 grid is already giving us 10,000 polygons just for a flat surface. Ultimately if you want large areas but the ability to edit fine detail, you can quickly find yourself blowing the whole render budget on geometry that’s no more advanced than D-Generation.

I quickly realised this was a stupid way to go, and set about working on an improved version using Quad Trees. Quad Trees are related to BSP trees commonly used to get FPS games running at a decent frame rate, and basically give us a nice way to partition the world so that we can have big empty areas that use up very few polygons, but still have the extremely high detail exactly where we need it. If you imagine a 100 metre square area, a quad tree would recursively divide this area into 4 blocks of 50 metres square each, one in each quarter. Each of those blocks would be further divided into 4 blocks of 25 metres square each. You can continue this subdivision all the way down, until you end up with areas that are just 10cm or even less in the areas where you need the detail. This is a much more efficient method of storing the same geometry, and is much quicker to render. This screenshot shows the same system, with red lines to represent the division of the world into a quad tree.

Image

So four paragraphs and two pictures later, why am I still banging on about this when it’s clearly so limited? This method actually has some serious advantages over any modern system that are not immediately obvious. For example, the scenery is completely dynamic – there’s no need for any pre-computing, you can render everything via the quad tree extremely fast. You could blow the walls down with explosives or drill holes through the roof from one section to the next – genuinely dynamic game geometry for free. You can also render the world in correct back-to-front order, meaning you can do transparency without first having to depth sort your geometry. I tried to do this with the existing system a while back and concluded it was impossible without generating a BSP tree first – an extremely slow process that results in static geometry. Ray casting in this system is extremely fast – meaning you can do realtime shadows over everything for very little cost. Ultimately though, the biggest benefits are for the user – editing a world in this way is extremely simple and intuitive.

Image

There’s already an example of a first person shooter that has been built using this core idea – and it’s called Cube. If you’re still thinking this form of map editing is very limited, I suggest you have a look at some of the game maps in this game.
http://cubeengine.com/
To really hammer the point home, while playing Cube in a Multiplayer environment you can press E to open the map editor and start building new geometry, and other players will see it too. You can knock down walls, build new ones, whatever you like, in real time. Try doing that in Unreal and see how far you get.

Here's another example showing what you can achieve if you take this to extremes. This is a Voxel demo using very similar (but more advanced) concepts, with completely destructable terrain in 3d space. This is from Ken Silverman, author of the Build engine used in Duke 3d et all. This demo also uses ray tracing to render the world, rather than polygon rendering - which probably makes more sense (it makes the polygon limit go away) but it's just not how modern graphics cards want to operate.
http://www.advsys.net/ken/voxlap/voxlap03.htm

Ultimately I’m not totally sold on the idea, because although you can approximate complex geometry, you can’t really do anything with totally weird angles. Looking at the pic of the doom map above, this sort of map would be extremely difficult to emulate in a grid based system. But I also know that perhaps ten times less people will be willing to edit maps with the kind of system that leads to doom maps like the one above. So ultimately some kind of hybrid may be the way forwards – using the grid system as a scratch pad for quick and dirty editing, and converting that into a more complex system if the user wants to.

On a totally unrelated note, today is 24th March, which some of our hardest-core fans might recognise as the starting date for Uplink (2010 of course). It also happens (not entirely un-coincidentally) to be my birthday, which makes me 29 today – just 12 months to go until the scary big Three Oh. I already own the slippers, and the dog is looking more and more likely every day.
RabidZombie
level5
level5
Posts: 2414
Joined: Fri Nov 18, 2005 10:09 pm

Postby RabidZombie » Mon Mar 24, 2008 9:14 pm

Happy Birthday!

The trade off between user-friendliness and versatility is a very tricky one. From the point of view of someone who can understand and use complex tools (eg. Hammer), the versatility is superior. It allows you to create something closer to what you have imagined. Yet, from the point of view of someone less experienced and even the developer (who's looking to have vast amounts of user content made), complex is, well, difficult. The more difficult something is the less time people will spend making and the more time people will spend learning, resulting in a reluctance to actually do anything at all.

This isn't the only thing to take into consideration though. Another problem could be fatigue, which effects both experienced and inexperienced. The longer something takes to finish, the more likely the creator is to get bored and stop half way though (this is why I've only been able to make two crap maps in Hammer and a few average Doom maps). The quicker it is to get what you want (or at least something good), the better in this aspect.

One awesome thing Cube, and similar, is the immediate interaction with what you've created, as you said. If you can see the results immediately, it's so much easier and more encouraging. Another good example might be scripting. Scripting not only allows complex mods, but you can change 1 line in it and see the result in less than 2 mins. Recompiling code for one small change takes ages, and isn't worth the effort if it is only minor. This is some minds could outweigh the limitations set by these kind of systems.


Edit: First post! Aside from Chris'.

If xander can do it, so can I!
Last edited by RabidZombie on Mon Mar 24, 2008 9:20 pm, edited 1 time in total.
User avatar
mibias
level5
level5
Posts: 1487
Joined: Sun Apr 16, 2006 9:54 am
Location: Denmark

Postby mibias » Mon Mar 24, 2008 9:17 pm

It seems strange working on a map editor for a game that doesn't have a 'concept' yet. But of course the earlier you start, the better it's going to be.

Also, happy birthday!
User avatar
Ace Rimmer
level5
level5
Posts: 10803
Joined: Thu Dec 07, 2006 9:46 pm
Location: The Multiverse

Postby Ace Rimmer » Mon Mar 24, 2008 9:22 pm

A. Still can't wait for subversion to materialize!

B. Happy birthday, a dog isn't so bad, if you've got the right one.

C. I told ya it was gonna be based on Cube some sorta way. :P

Seriously though, as a probably future subversion map editing forum member, a hybrid version as mentioned seems the way to go. Not having time to fumble through learning a complex system is definitely a concern of mine.
Smoke me a kipper, I'll be back for breakfast...
sasb
level1
level1
Posts: 23
Joined: Mon Jul 05, 2004 4:39 pm
Location: Moscow, Russia

Postby sasb » Mon Mar 24, 2008 9:53 pm

Happy Birthday!
User avatar
ynbniar
level5
level5
Posts: 2028
Joined: Wed Nov 08, 2006 10:36 pm
Location: Home again...

Postby ynbniar » Mon Mar 24, 2008 9:56 pm

Dogs are great...they love Frisbee...

Image

...and the big 30 isn't a problem either...good excuse to drink lots of Cava.

:wink:
User avatar
zach
level5
level5
Posts: 1350
Joined: Wed Jun 30, 2004 1:21 pm
Location: Denmarkia
Contact:

Postby zach » Mon Mar 24, 2008 11:23 pm

Happy Birthday indeed, Chris.

Coincidence would that I in fact reinstalled Uplink, and started playing through again just earlier today. I don't know what the odds are - well, I did know that the Uplink calendar starts today, but it was not something I had given any thought. And little did I know it was your birthday, though.


The appropriate approach for map editing depends a lot on the game, I think. I am somewhat skeptical of making all this engine/map editing stuff before having a clear idea (assuming you don't), or even any idea at all about how and why this game is what it is, or will be. After all, you yourself shunned the creation of engines over games in a manifest many years ago, Chris :roll:
I am probably very wrong, because somehow I think my skepticism is much less than my belief in Introversion ... You've shown unusual approaches to be more than successful in the past, and we all love you for not doing what everyone else does.

And yes, I am aware that strictly speaking, Subversion might not really be seen as an engine. I still think it has a lot in common with various types of engines, though.
User avatar
NeoThermic
Introversion Staff
Introversion Staff
Posts: 6256
Joined: Sat Mar 02, 2002 10:55 am
Location: ::1
Contact:

Postby NeoThermic » Mon Mar 24, 2008 11:32 pm

zanzer7 wrote:The appropriate approach for map editing depends a lot on the game, I think. I am somewhat skeptical of making all this engine/map editing stuff before having a clear idea (assuming you don't), or even any idea at all about how and why this game is what it is, or will be. After all, you yourself shunned the creation of engines over games in a manifest many years ago, Chris :roll:


Prototyping an idea, even if it's an engine idea or gameplay idea; etc is a fantastic way to see if the idea in question works. Chris started out with the 1 square idea, and then worked his way to a quad tree. Throw in the final dimension (octo trees, as Chris told me), and voilà, you've a prototype technology that works as both a map editor and a game mechanic. :)

NeoThermic
martin
level5
level5
Posts: 3210
Joined: Fri Nov 19, 2004 8:37 pm

Postby martin » Tue Mar 25, 2008 12:14 am

subversion looks more and more cool every time Chris makes a blog, and this one is especially interesting since I'm definitely going to be modding subversion :D

I wonder where the map editing will come into a procedurally generated world :?

Also, Happy birthday :D
GENERATION 22:The first time you see this, copy it into your sig on any forum and add 1 to the generation. Social experiment.
User avatar
Pox
level5
level5
Posts: 1786
Joined: Sat Mar 03, 2007 11:23 am
Location: Melbourne

Postby Pox » Tue Mar 25, 2008 12:39 am

Hehe, I remember hours of fun with Cube and later Sauerbraten... looks like a very user-friendly system, and the translucency and stencil shadows sound (and look) delectable.

I'm still not sold on the idea of a map editor in Subversion though... procedural generation to the max would be better. Why can't I just say "Build me a fancy-shmancy office with creative bits and nice spots for terrorists to camp with AK47s"? :wink:
User avatar
xander
level5
level5
Posts: 16869
Joined: Thu Oct 21, 2004 11:41 pm
Location: Highland, CA, USA
Contact:

Postby xander » Tue Mar 25, 2008 2:00 am

There really isn't much I can add that hasn't been said already, so I shall keep my comments short and sweet:

1) Damn, that's nifty.
2) Happy birthday.

xander
User avatar
KingAl
level5
level5
Posts: 4138
Joined: Sun Sep 10, 2006 7:42 am

Postby KingAl » Tue Mar 25, 2008 2:24 am

Pox wrote:I'm still not sold on the idea of a map editor in Subversion though... procedural generation to the max would be better. Why can't I just say "Build me a fancy-shmancy office with creative bits and nice spots for terrorists to camp with AK47s"? :wink:


My immediate guess was that you could design new security systems within the buildings, a la Icepick's VDPIN in Uplink. Even were this not the case, it's hard to automatically generate tactically interesting rooms.

Anyway, Happy Birthday, Chris! (Sentences with all initial capitals, they look strange.)
Gentlemen, you can't fight in here: this is the War Room!
Ultimate Uplink Guide
Latest Patch
User avatar
Pox
level5
level5
Posts: 1786
Joined: Sat Mar 03, 2007 11:23 am
Location: Melbourne

Postby Pox » Tue Mar 25, 2008 2:31 am

KingAl wrote:Anyway, Happy Birthday, Chris! (Sentences with all initial capitals, they look strange.)


Indeed they do. So lose the two unnecessary ones. :P
User avatar
KingAl
level5
level5
Posts: 4138
Joined: Sun Sep 10, 2006 7:42 am

Postby KingAl » Tue Mar 25, 2008 4:58 am

RabidZombie wrote:Happy Birthday!

sasb wrote:Happy Birthday!

zanzer7 wrote:Happy Birthday indeed, Chris.


There's precedent! Precedent, I say!
Anyway, this thread is not about the correct capitalisation of Happy Birthday. I think.
Gentlemen, you can't fight in here: this is the War Room!

Ultimate Uplink Guide

Latest Patch
User avatar
Pox
level5
level5
Posts: 1786
Joined: Sat Mar 03, 2007 11:23 am
Location: Melbourne

Postby Pox » Tue Mar 25, 2008 5:03 am

KingAl wrote:
RabidZombie wrote:Happy Birthday!

sasb wrote:Happy Birthday!

zanzer7 wrote:Happy Birthday indeed, Chris.


There's precedent! Precedent, I say!
Anyway, this thread is not about the correct capitalisation of Happy Birthday. I think.


You never know. Especially around these parts. >_>

Return to “Introversion Blog”

Who is online

Users browsing this forum: No registered users and 0 guests