Closed segfaultdev closed 1 year ago
Comparison of the two world generators:
Old generation(1000x250): New generation(780x320, haven't added the new ores nor the underworld yet):
While making the new one, I wanted to make it look like the actual game of Terraria, by making smoother and longer caves, but it still feels odd, so @KBD2 please tell me what you think.
Those long caves are looking really good - I think sprinkling a few smaller caves with the old circular shape between them would help make it look like Terraria's generation system.
Ok so I uncommented part of the old circular cave's code and make the long ones a bit thinner.
It turns out, the algorithm I used for the updated cavegen was really slow, so I spent 3 days rewriting the cave system algorithm. I also rewrote the map tool in C to not have to wait for it to generate, and also to make code changes in both the tool and the game easier. Here is a photo of the new worldgen: I still have to reimplement rooms, but I think it's looking great as of now. By the way, do you want me to keep the C tool separate and update the Python one or to add the C one to the repo?
The python tool was purely for ease of implementation, you can go ahead and add the C one since I'm sure it's a lot faster. I'll probably see if I can get it to parity with the Python one w.r.t. stuff like beaches and the scattered mud around the jungle edge.
Added beaches, rooms and some noise in the jungle edge, just have to add life crystals and chests back and I'll push it to the repo.
I'm done with the C tool, what do you think? Now I'll start moving all this code into the game itself.
Also please don't mind the different formatting in the tool's code, I'll pass it through clang-format when I have some spare time.
Looks good to me, just make sure it runs within a reasonable time - maybe put some warning text in the corner for parts that take a while?
Todo list:
I don't know if I will actually end up implementing all of these features, just added whatever came to my mind at the moment of writing this, while being realistic with what i could do.