Insane layer landscaping bug in the Level Editor (with workaround)

Anything to do with Drakan level editing and modifications, post it here! Also this is the place to tell us about your new levels and get player feedback.
Post Reply
User avatar
Mechanist
Dragon
Posts: 303
Joined: Wed Mar 07, 2018 7:27 pm
Location: Poland

Insane layer landscaping bug in the Level Editor (with workaround)

Post by Mechanist »

So I was trying to do some landscaping in my nicely prepared level (50 layers, none overlapping, all set to the same initial height, and fully painted with grass texture) - but the Level Editor refused to cooperate:
Curse of the number 50.png
Curse of the number 50.png (59.13 KiB) Viewed 19415 times

In addition to the above result, this "problem layer" was also mysteriously getting its height changed when landscaping layers near the top edge of the map - despite being hundreds of LU from the nearest map edge!
It's also possible (but not tested) that its visibility would have been calculated incorrectly as well.

After a lot of tinkering and experimenting (moving layers around, deleting and remaking them, etc.), I finally managed to narrow down the cause of it... it was because I had exactly 50 layers in the map!

Adding (or removing) a layer, to make the number other than 50, made the problem go away!

In this case, since I don't need more than 50 layers at this stage, I just made a 1x1 dummy layer and placed it out of the way (in the upper left corner, actually).
Seems the parameters of the "extra layer" don't matter in the slightest; it simply needs to exist, so that the total number of layers is not 50.

It's possible (but I haven't tested it) that the layer type matters (so 50 floor layers?), but I have no desire to mess around with this any more than I have to at this point.

It's equally possible (and likely near-certain) that other numbers of layers are also affected, not just 50.

So if the Editor causes problems with some layers not landscaping properly, or having incorrect visibility calculated, just try changing the number of layers (eg. by adding some unused ones).

Post Reply