
Corrections and Notes regarding DMA's GTA technical doument [cds.doc v12.10]

3.1.3
    Door_info_struct (Player position to enter)

    typedef struct {
       Int16 rpy, rpx; // Y is first!  X&Y; are measured from the exact CENTER of the car.
       Int16 object   //unused
       Int16 delta  // unused (sadly the "second" door on many cars will never function)
    } door_info_struct;

    Excluded Vehicle Types:
    9 - Tram
    13 - Boat
    14 - Tank

3.2.1

    About the Char *ptr fields in sprite_info_struct: They are said to be "empty in the file" and are not. In fact they are the only way to 
    find the location of the sprites in the sprite_graphics data.

    8bit: *ptr is a long offset to sprite in sprite_graphics pages
        Page number = ptr intDivide 65536
        Y position of the sprite in the page = Int((ptr Mod 65536) / 256)
        X position of the sprite in the page = (ptr Mod 65536) Mod 256

    24bit: *ptr field is REPLACED with something like the following:
        Int ---- CLUT (to be reindexed by PalIndex)
        Byte ---- x offset in page
        Byte ---- y offset in page
        Int ---- page number in Sprite_Graphics

Jeff's notes:

    Sprites:
        GTA's transparent sprite color is not necessarily black! It is whatever color is used by palette index 0.

    Loading the deltas Pseudo-code
        loop each delta {

                fseek spriteGraphicsBegin + sprite.delta( ).ptr 

                fget size and length

                total_offset=0  
                loop delta( ).size {
                                
                        total_offset+=offset
                        yo = (total_offset intDivide 256)
                        xo = (total_offset MOD 256)

                        loop x =  0 .. length-1 {
                                fget databyte
                                drawpixel xo + x,yo 
                        }

                        total_offset+=length    

                }
        }

    Loading and using the CLUT

    As for the G24 CLUT this is what I have to say...

        It is located in the file at the expected position by 3.8.1 (remember to
        add extra bytes to aux_block per 3.7)
        Imagine the clut in the first of the 64k pages is like this...

        CLUT    0                               1                               ...63
        color   B       G       R       0       B       G       R       0
        0       b0      g0      r0      0       b0      g0      r0      0
        1       b1      g1      r1      0       b1      g1      r1      0
        ...
        255     b255    g255    r255    0       b255    g255    r255    0


        To find the sprites CLUT you offset the sprite_info.clut and offset with
        (tile_clutsize / 1024).   Note: 1024 = 4*256 so tile_clutsize is RGB0 units.

        sprite.RealClut = palIndex(sprite.Clut + tileClutsOffset)

    Exactly how to use PalIndex to remap. - just an array of int16s, used to reindex the sprite.clut to a CLUT.
    How to convert all those relative numbered CarInfos to Absolute Sprite numbers... soon...
    much more...