Sigh…I must be crazy.
RPGs are just so information dense; doing one in one page seems almost impossible without cutting practically every feature that makes an RPG an RPG. But as you can see, I’m thinking positive…this is basically a much more effective reworking of the terrain generation I started on with 40-Hour RPG #1 (which I failed to complete, if you’ll remember).
Basically, I wanted a algorithm that made maps that reminded me of this. I must use an algorithm, because I want the map to be 64×64 (I don’t think a smaller map will feel big enough to represent a world). If I tried to simply use a data file, I’d waste 4096 bytes just on the world. An algorithm that takes up fewer than 4096 bytes and can generate a random world would be a big win.
I now know what I was doing wrong with my first terrain generator. I walked the Path of Perlin and tried to do a heightfield. I can’t really blame myself; google “random terrain generation” and practically all you will get are articles about heightfields.
You know what? I frigging hate heightfields. For one thing, they are not an accurate representation of how terrain looks. They’re too smooth; too rolling. They say nothing about what type of terrain it is or what is on the terrain, just what elevation it is. And you will never, ever get a realistic-looking river out of a heightfield.
So I went back to a very early idea I had – that of seeding the map grid at regular intervals with terrain types and then having them grow and fight each other for terrain tiles. I effectively walked the Path of Conway instead. This worked much better and started giving me maps that I felt I might be able to use, but I still think there is room for improvement.
My current intention is to include both a world generation algorithm and a dungeon level generation algorithm. I will probably run both until I get results I like and hardcode those seeds so that the player gets known content; otherwise the odds are good that the game would be unfinishable.
I am going to do my best to get it into one page. Going the two-page route here seems like a copout, since I’m almost positive I could do an RPG in two pages. (Especially since Tom is already doing an RPG in two pages. Gosh, it sure would be nice if he’d update his blog with a couple screenshots of it.)
Let’s see what I can do in one.
re: heightfields. You may wish to look up multifractals.. this is a pretty good book: http://www.texturingandmodeling.com/
re: textmode. http://tAAt.fi/tmdc/ – the contest deadline is 12.12.2006, you might be interested =)
I am glad to see that you are still working on your projects. While I enjoy your video blogs, it was beginning to look like you were putting all of your engery into those instead of coding. I look forward to seeing what you come up with.
I am amazed at how much time those video blogs take up – it usually takes about three or four hours of work just to get those fifteen minutes up on the internet. I’ve been thinking about doing the video blogs every other week…
Sol: That book looks very good (I’d heard of it before). I’ll probably have to pick it up at some point. And yes, I am familiar with the text-mode demo scene, but I doubt if anything I do will have a chance in Hades 🙂
re: hades, well, you never know before you try.
You can make realistic terrain by using DEM data freely available from sites like the US Geological Survey.
[…] I tried to write an RPG in one page. (That’s on permanent hiatus by the way; RPGs are just too information-dense to do in one page of source. I might try to write one in two pages later, we’ll see.) […]