Jump to content
  • Advertisement
  • entries
    444
  • comments
    1237
  • views
    774493

/cast Resurrect HeightMapEditor

Sign in to follow this  
JTippetts

1390 views

A short while ago (translation: 10 years) I had been working on a heightmap editor for a game project I was working on. Like most of my projects, it fell by the wayside. I haven't really had time lately to do much, but I have resurrected that old project... in a way, at least. In spirit, if nothing else, since none of the code has made it from backup onto my current hard drive.

Anyway, I've been re-building the heightmap editor using Urho3D. The forum thread where I show stuff is here, and the github repo for the project is here. It requires the Urho3D library to be built with Lua support, and so far the shaders I have written are HLSL only. GLSL shaders are on the TODO list.

The editor allows simple brush-based editing of height and up to 8 terrain layers. I've been experimenting with various shader schemes, starting with Urho's 3-layer scheme and elaborating up until I have settled on the current scheme: 8 terrain layers stored in 2 composite 4x4 texture atlases and a blending approach that uses the scheme described in this article. The results are quite nice:

F9Jytpo.png
hU7ENNX.png
4hfXxPc.png

The editor supports a rudimentary filter script system, wherein you can write scripts in Lua that apply effects or alterations to the terrain. Included filters so far include a basic Perlin fractal height generator, a Perlin fractal terrain layering generator, a river builder tool, a road builder tool, a tool to turn slopes greater than a specified threshold to cliffs, and so forth.

The UI is very rough. I am not in a polish stage on it yet, so things are barely usable. But I am working on it pretty steadily as I can. I'm getting to the point where I can start cleaning things up, though I am sort of waiting on some pending merges to the Urho3D master regarding shader structure before I really commit to a lot of the cleanup.

Anyway, that's about all I've been up to. I did dig out the Goblinson Crusoe code and attempt to build it against the latest master, but all I get is a black screen so clearly there is going to be some refactoring there if/when I ever get back to that game.
Sign in to follow this  


7 Comments


Recommended Comments

10 years, pah ! A good project is like a good wine, it needs time to get ripe. Nice to see you again working on your old projects, especially Goblinson Crusoe seemed really promising, so get it running again :-)

Share this comment


Link to comment

That's actually what I'm working on this morning. I kinda have you to thank for my renewed interest in GC, btw. The new Gnoblins looks, like, totally rad and groovy. Far out. Right up my alley, far more so than when it was an FPS thingy. It kinda got my old creaky brain working again to see the new videos. Between that, and all the Divinity: Original Sin I've been playing, I have a renewed interest in seeing what I can turn GC into.

Share this comment


Link to comment
The stuff I was doing with the terrain editor has started to bring some ideas for an alternative way of handling the ground tiles in GC:

8WxPrIO.png

Something like this could actually be more lightweight than my previous method of having large collections of unique tiles.

Share this comment


Link to comment

Looks good. At the water screenshot, have you tried to use a smoothstep function to have the decline at the transition to water tile ?

Share this comment


Link to comment
To be honest, I haven't even thought much about water yet. Up there, that's just a quick alpha blended hex added to pit tiles for the sheer heck of it. I might do something more elaborate in the future, but I still have some work ahead of me just to get back to playable.

Share this comment


Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!