Changes between Version 10 and Version 11 of SC2ReplayFormat


Ignore:
Timestamp:
Apr 13, 2010, 9:10:35 PM (10 years ago)
Author:
mseifert
Comment:

Added information on time offsets

Legend:

Unmodified
Added
Removed
Modified
  • SC2ReplayFormat

    v10 v11  
    2121||string||One byte that represents the length of the following string. The string has as many characters, as the byte's value||
    2222||bytesX||A number of bytes whose functions and grouping are unknown, where X represents the number of bytes.||
    23 ||time offset||''Definition yet to be provided.''||
    2423
    2524All types are Big-Endian.
     25
     26There is another type that will be called time offset. It is of variable length and describes the amount of time that has passed since the last action has occured. Time seems to be measured in something I will call time frames or just frames. 25 frames give a real second. Say you read a byte. If this byte has the flag 0b00000001 set, the time offset is followed by another byte. If the flag 0b00000010 set, it followed by another two bytes (not tested yet). It is likely that the time offset consists of two byte, if any of the 8 bits are set, though. Let ''a'' be the first byte you read that contains the flags and ''b'' be the second byte, then the value of the time offset ''t'' is calculated:
     27{{{
     28  t = b + (a >> 2) * 255
     29}}}
    2630
    2731=== replay.info ===