 |
Server Help Community forums for Subgame, ASSS, and bots
|
Author |
Message |
k0zy Guest
Offline
|
Posted: Mon Jan 06, 2003 11:35 am Post subject: Lvzformat.txt |
 |
|
|
|
Quote: | The first 8 bytes of every .lvz file:
4-len str Type - Should always be 'CONT'. This varifies you have a .lvz. If not, don't continue on. This string is not NULL ended.
i32 Count - How many compressed sections are in this .lvz. |
What is i32?
An integer? If so, y dont i c the integer in the lvz when i open it in the notepad... let me guess... cuz its not a string?
What exactly does the 32 mean?
What is a NULL ended string?
What is a not NULL endet string?
Quote: | i32 File Time - This can either be a file time, if this compressed section is a file, or it could be 0. If 0, then is a special compressed section. The file time is the standard time_t format used by windows/unix. |
hu???
How does time_t look like at all?
Quote: | i32 Compressed Size - The size of the compressed data in the .lvz. This is how many bytes you'll need to read to get your required data.
Null-end str File Name - This string is always null ended. If no file time, the File Name should be blank (just the 0x00), but do not always count on it. |
What does 0x00 mean?
And again that Null-end string...
And some examples would be nice and helpfull
thx
PS: I use delphi, might be good to know, as u don't need to hammer me with c++ stuff, explanaitons in general would be nice.
At least i found out how to compress and decompress for myself.
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole....[/quote][/b] |
|
Back to top |
|
 |
Mine GO BOOM Hunch Hunch What What

Age:41 Gender: Joined: Aug 01 2002 Posts: 3615 Location: Las Vegas Offline
|
Posted: Mon Jan 06, 2003 1:00 pm Post subject: Re: Lvzformat.txt |
 |
|
|
|
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | What is i32? |
i32 is a way of writting down a 32bit unsigned interger. In C, that means 'int'.
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | An integer? If so, y dont i c the integer in the lvz when i open it in the notepad... let me guess... cuz its not a string? |
Its stored directly as it is in memory, as four bytes, instead of outputed as a string. This keeps the filesize smaller, and it is easier to read (machine wise).
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | What exactly does the 32 mean? |
The 32 bits (4 bytes long; 8 bits = 1 byte). Some other standard ones are u32 (unsigned int), i16 (short), u8 (unsigned char).
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | What is a NULL ended string? |
A string is stored with each character as one byte. When the computer works with this string, it needs to know when it ends. The NULL ending means 0. So in a computer, a string of say "hi" would be:
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | What is a not NULL endet string? |
The only times a not null ended string happens is if the string is always a certain length (like the CONT at the being, though you can read that in as a 32bit interger), or if the string length is given before you read it in.
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | Quote: | i32 File Time - This can either be a file time, if this compressed section is a file, or it could be 0. If 0, then is a special compressed section. The file time is the standard time_t format used by windows/unix. |
hu???
How does time_t look like at all? |
This will be hard to explain since i never worked with Delphi before.
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | Quote: | i32 Compressed Size - The size of the compressed data in the .lvz. This is how many bytes you'll need to read to get your required data.
Null-end str File Name - This string is always null ended. If no file time, the File Name should be blank (just the 0x00), but do not always count on it. |
What does 0x00 mean?
And again that Null-end string... |
Correct, 0x00 is the hexidecimal way of writing 0. In the example before of 'hi', it could be written as 0x68 0x69 0x00. What that means is the file name is still readable as a string safely. Again, hard to explain since i never worked with Delphi before.
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... wrote: | And some examples would be nice and helpfull :)
thx
PS: I use delphi, might be good to know, as u don't need to hammer me with c++ stuff, explanaitons in general would be nice.
At least i found out how to compress and decompress for myself. :-D
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... |
Thats good that you could compress/decompress correctly, since i would be even more lost trying to get you to use zlib. Sorry i can't help explain it more, since i've never work with Delphi before. |
|
Back to top |
|
 |
k0zy Guest
Offline
|
Posted: Tue Jan 07, 2003 5:27 am Post subject: |
 |
|
|
|
THX!
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... |
|
Back to top |
|
 |
k0zy Guest
Offline
|
Posted: Tue Jan 07, 2003 8:04 am Post subject: |
 |
|
|
|
I figured time_t out... its unix time...
i32 is a normal integer in delphi
And I can compress/decompress...
So, the next thing to figure out would be streams (shouldnt be that hard)
And then i'm ready to go
Bob Dole.. Bob Dole... Bob Dole...... bob dole.... bob... dole.... |
|
Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
Software by php BB © php BB Group Server Load: 80 page(s) served in previous 5 minutes.
|