[attributes]-file

General talk about editing, cheating, and deprotecting maps.

Moderator: Cheaters

Falletor
Newcomer
Posts: 3
Joined: February 3rd, 2009, 3:44 pm

[attributes]-file

Post by Falletor »

Hey guys,

could you please tell me something about the (attributes)-file in the
Warcraft III-maps (.w3x)? I guess that it's from WE, right :razz: ?
Which data is stored in there,
what is the file needed for,
would it be helpful for any optimization tools like WTS Inliner or heavylock?
Can I create this file if it does not exist?

Ty for all replies,
Falletor
Falletor
Newcomer
Posts: 3
Joined: February 3rd, 2009, 3:44 pm

Re: [attributes]-file

Post by Falletor »

Just found a possibility to create an (attributes)-file:
If you create a new MPQ archive with Ladiks MPQ Editor you can make one for the new archive...
User avatar
Senethior459
Forum Staff
Posts: 2618
Joined: June 2nd, 2007, 6:53 pm
Title: I Just Lost the Game

Re: [attributes]-file

Post by Senethior459 »

The attributes file contains information about the MPQ.
(attributes) = attributes of files in the w3m file, it is checked when a map is loaded in the World Editor, if you have modified a file of a map and didn't update the (attributes) file properly it will say that the map is corrupted, the easy way to prevent this is deleting the file from the archive, the harder way is updating it, the format of the file is as follows:

int: unknown1: set to 0x64000000
int: unknown2: set to 0x03000000
"n" times a CRC32, "n" is the number of used slots (=files) in the MPQ archive
So for each file we have the CRC32 (cycling redundancy check) value here, wich is a sort of checksum, you can find functions that calculate the CRC32 of a file on the web
"n" times a Filetime, "n" is the number of used slots (=files) in the MPQ archive
The Filetime specifies for each file when it was added to the archive. It consists of two ints (low and high date/time). These two integers include information about the year, month, day, hour, minute and second when each file has been added, these 2 values represent a WinAPI file time structure and can be converted to the WinAPI system time type by using the SystemTimeToFileTime and FileTimeToSystemTime functions in kernel32.dllint:
int: low date time

The order of the CRC32 and Filetimes is the same as the order of the files in the archive. Logically this means that the information of the last CRC32 and Filetime is the information about the (attributes) file, because it has to be added to the archive after all other files. This also means that the CRC32 of the last file is always 0, because you cannot calculate the CRC32 of a file that will be changed later, which would make the CRC invalid again.
You don't need it for anything. Like I said, if you make any changes to the map, you need to delete the (attributes) file or it will prevent the map from being played.
It's not helpful for any tools; they delete it too, to make sure that the map doesn't have errors.
Yeah, but you need to make a new map then, and if you want to do anything to it, the (attributes) file is no longer valid.
My Warcraft III Tool Collection
If you want to chat/game with me:
Blizzard: Senethior459#1962
Discord: Kyle#7409
Steam: Spacekidkyle