Well I noticed that the map version value is defined as being 11 in the map editor... How reliable would this be for checking the validity of a soldat map file, or is there some other attribute for a map file that I'm not seeing that could be used to check validity?
I dont think that value is used at all except if you try and play a 1.1.5+ map on Soldat 1.05b
Checking if the map is valid is done via Checksum, and also a random 6 char number which is in the map files header aswell.
Where in the map file is the checksum stored... also I know about the random ID but thats not really that useful for checking if a map is valid... since its random, its more or less an attempt at a unique ID for soldat to use internally.
Checksums are not stored in the maps, they are generated when the maps are being loaded.. Starting to sound like your trying to make a map hack.
the randomID was soldats old defence, checksums is the current one.
No, I'm not trying to make map hacks, I have set up what I wanted to do (it took all night), goto http://bluefire.hopto.org/upload.php, It will let you upload a map onto my server which is located at bluefire.hopto.org. Now all I have to do is get it added to the rotation:S
The problem with using checksums, is I dont know the checksum of the map being uploaded to begin with:S
Are you trying to make sure somone does overwrite an existing map?
They cant, if you upload a map with the same name as an existing map, its just deleted. Also the uploader wont accept files larger then 500k, and they have to have a .pms extension, as well there are some checks right now to make sure its a soldat map file, but they are kind of weak, not that it matters, you cant execute anything you post anyways;)
er, basically I was asking why you want to get a checksum for the maps O.o
well i didnt want the checksum... I wanted a way to verify that a given file was actually a soldat map, and not some script kiddy trying to upload dlls onto my server in the hopes of taking it over.
Just make sure there PMS files I guess :/
just make sure the first 4 bytes are 0B 00 00 00
I did that, I also make sure that the texture name ends in .bmp, since soldat only uses bmps;)