Edit level.dat in C

Discuss PoP1 for DOS here.
Post Reply
User avatar
Akruzen
Developer
Developer
Posts: 141
Joined: April 30th, 2016, 10:16 am

Edit level.dat in C

Post by Akruzen »

Hello,

Anyone has any idea how to edit the level.dat file so that I can write it in C language? I am thinking of possibility of creating auto generated rooms based on specific restrictions, something similar to the 'seeds' referred in Minecraft.

Regards,
princeomkar
What if life is a video game and Déjà Vu are just checkpoints?
User avatar
atrueprincefanfrom18
Site Shah
Site Shah
Posts: 1785
Joined: January 21st, 2020, 2:53 pm
Contact:

Re: Edit level.dat in C

Post by atrueprincefanfrom18 »

Welcome back ;)
You can maybe take a look at the level editors available and take a look at the source code.
Norbert might be able to help you with more information.
Love to create new MODS :)

My complete list of mods until now!

My channel. Do consider subscribing it! :)
User avatar
Akruzen
Developer
Developer
Posts: 141
Joined: April 30th, 2016, 10:16 am

Re: Edit level.dat in C

Post by Akruzen »

Thanks!
I wonder where the source code could be..
Also, I found the randomize option in the Apoplexy Editor. Just adding a few restrictions to what tiles can be placed and what cannot next to each other might help to achieve the "auto generation".
I think Norbert might be able to help me with it as you said.
What if life is a video game and Déjà Vu are just checkpoints?
User avatar
Norbert
The Prince of Persia
The Prince of Persia
Posts: 5745
Joined: April 9th, 2009, 10:58 pm

Re: Edit level.dat in C

Post by Norbert »

If editing LEVELS.DAT, which is a relatively basic operation, is a hurdle for you, then you are most likely overreaching yourself if you would take on the task of implementing meaningful autogeneration. This is why I feel inclined to take your remark about contemplating autogeneration as a more general attempt at initiating dialog about autogeneration. At the moment, I personally lack the time to participate in this dialog. However, I have tried to find on-topic forum threads. What I could find are:
viewtopic.php?f=76&t=4022
viewtopic.php?f=73&t=3383
viewtopic.php?f=68&t=3779
As for apoplexy. Perhaps one day I will build upon its randomization feature to implement autogeneration. Although, to be honest, I'm more likely to improve what the program can do for SDLPoP (e.g. new custom tiles) - or even work on SDLPoP itself (e.g. multiplayer). I don't see a lot of value in autogeneration given that some thoughtfully created mods already remain virtually unplayed. Currently, there are 260 PoP1 for DOS mods on PoPOT. This makes implementing autogeneration primarily an interesting technical challenge. Other technical challenges, that are similarly interesting, exist that lead to more useful - and (therefore) probably more enthusiastically-received - tools.
User avatar
Akruzen
Developer
Developer
Posts: 141
Joined: April 30th, 2016, 10:16 am

Re: Edit level.dat in C

Post by Akruzen »

Thanks for the reply Norbert. Yes, I agree with what you say and I think I might need to up my skills more to achieve what I had in mind. And yes, its more practical too to work on your current projects. Thanks Again :)

P.S. the multiplayer idea you told could be awesome
What if life is a video game and Déjà Vu are just checkpoints?
Post Reply