Sign in to follow this  
Ahiri

WurmMapUploader Height Scale

Recommended Posts

So I'm messing around with WurmMapUploader and was wondering what the scale for the height is. I saw the variable where I can adjust the scale but digging through the code for both WurmMapUploader and for the API I can't find any documentation on what the default scale is. If I'm generating a height map is each shade bit increase equal to 1 meter in game? or 1 dirt? 


Share this post


Link to post
Share on other sites

 WurmAPI is 1 dirt per integer step, + land, - sea, and WurmMapUploader is following that convention in it's grayscale images.


 


Wurm Online/Unlimited have been reverse engineered using photographic scale trigonometry methods to be 4m tiles which is 40dm and 40 dirt slope  is a proven 45 degrees  thus in Wurm 1 dirt is 1dm.


 


Map making is more artistic than scientific.  Download a sat survey that used 1m per integer step and you will find shrinking continents down to scale turns mountains into boring mole hills.  Interpolate a local 8km survery map into a height map grid and you find it is also boring because mountains have larger foothill bases than 8km.  Satellite Surveys are typically integer scale is 1m.  Topological surveys are interpolated and depend on the contour intervals - but usually in metric or feets.  Elder Scrolls games have no consistency they have all been different scales so any of those map porter you need to know which version game ESM it is reading and what the reader is assuming because this info is not in the files.


 

The way Wurm does it is the same way Skyrim did it.  They stretch the truth and use mountains that are unrealistically steep and do not preserve their slopes.    And also Swedish Fjords look like that and devs are Swedish....so there you go.  You do not actually notice the mountains are tiny but steep unless you try to run it in VR with stereo perspective.


 


I would pick anything between 1 dirt is 1dm or 1 dirt is 1 m or maybe even 1 dirt is 10m if you want to capture Everest.  Whichever you find more playable for your map source balancing reality vs. playability vs. fun.  That is why the importer has a scale value.


Edited by yarnevk

Share this post


Link to post
Share on other sites

So you're saying that each integer represents 1/10th a meter? So if I adjust the scale value to say equal 10 then each integer will represent a meter. And so on and so forth? 


 


Edit: I'm actually trying to figure this out to write some scripts that will take a heightmap I have and automatically exaggerate the heights and slopes of it. Importing it directly is, as you said, pretty bland. So what I'm aiming to do is take a couple of features of the map currently, come up with the height I want them at in meters in game. Using this data set I plan to model an equation that I will apply to the current heightmap that will get it closer to what I'm looking for. Then I intend to hand edit everything after that. Just trying to get to a starting point.


Edited by Ahiri

Share this post


Link to post
Share on other sites

when i saved my heightmaps in 16 bit i had to use the min grey scale of 30000 and max of 45000  you can mess around with it to get the water level right


Share this post


Link to post
Share on other sites

In signed math that WurmAPI uses int16 range is -2^15 to 2^15-1 but you should avoid close to max - so stick to +/-30k dirt max (+/-3km at 1dm = 1dirt Wurm scale).   Add 2^15 to get unsigned grayscale numbers.


Edited by yarnevk

Share this post


Link to post
Share on other sites

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
Sign in to follow this