Files format

    Joined
    Jun 29, 2013
    Messages
    144
    Reaction score
    64
    • Modder
    • Legacy Citizen 4
    • Purchased!
    This thread is for each decoding research arround starmade files, you can found information at
    http://www.starmadewiki.com/wiki/File_format

    I'm currently working on SMDecoder and i've seen new tag since 0.14.
    • Tag 0xF4 (244) can be found inside shop, station and planet entity files. I suppose this is an anonym serial tag but i'm not sure
    • Tag 0xF7 (247) seems to be a vector 3 float, this tag appears in factions.fac
    I need to know if anyone can confirm tag 0xF4 and I want to know if there's some news about tag F1 (241)

    edit:
    After some testes and a better observation I can say 0xF4 is a list tag and I can also suppose than:
    • Tag 0xF9 (249) is for byte array
    • Tag 0xF5 (245) us for vector 3 bytes
    • Tag 0xF2 (242) is for serial
     
    Last edited:
    Joined
    Jun 29, 2013
    Messages
    144
    Reaction score
    64
    • Modder
    • Legacy Citizen 4
    • Purchased!
    Tag 0xF1 is used for 4 float (seen for RGBA of laser)

    Inventory is formated with 3 diffents array, first is for slots position, second is used for items id and the latest array is for items quantity and meta.

    JavaScript:
    "slotsPos": {
        "0": 16,
        "1": 1,
        "2": 12,
        "3": 13,
        "4": 14,
        "5": 17,
        "6": 3,
        "7": 4,
        "8": 15,
        "9": 11,
        "10": 0
    },
    "Items ID": {
        "0": -32,
        "1": 203,
        "2": 24,
        "3": -32,
        "4": -32,
        "5": -12,
        "6": 6,
        "7": 16,
        "8": -32,
        "9": 4,
        "10": 5
    },
    "Qt-Meta":
        "0": {
            "0": 106,
            "1": -32,
            "2": {
                "0": "unmarked",
                "1": "unmarked",
                "2": -9.2233720368548e+18
            },
            "3": 4
        },
        "1": 1,
        "2": 5,
        "3": {
            "0": 107,
            "1": -32,
            "2": {
                "Damage": 10,
                "Speed": 80,
                "Reload": 150,
                "RGBA": {
                    "0": 1,
                    "1": 0.57250094413757,
                    "2": 0.35752841830254,
                    "3": 1
                }
            },
            "3": 1
        },
        "4": {
        "0": 108,
        "1": -32,
        "2": {
            "Power": 5,
            "Speed": 70,
            "2": 150,
            "RGBA": {
                    "0": 1,
                    "1": 1,
                    "2": 0.82362508773804,
                    "3": 1
               }
           },
           "3": 2
        },
        "5": {
           "0": 109,
           "1": -12,
           "2": 0,
           "3": -1
        },
        "6": 1,
        "7": 15,
        "8": {
           "0": 110,
           "1": -32,
               "2": {
               "Power": 50,
               "Speed": 70,
               "2": 150,
               "RGBA": {
                   "0": 1,
                   "1": 0.97409844398499,
                   "2": 0.74082028865814,
                   "3": 1
               }
           },
           "3": 3
        },
        "9": 1,
        "10": 30
    }
    /!\ image is used only to show slot id

    JavaScript:
    slots["0"]    => 16
    id["0"]       => -32 (guns id)
    Qt-Meta["0"]  => "0": 106,    //sub id?
                     "id": -32,
                     "meta": {
                         "0": "unmarked",
                         "1": "unmarked",
                         "2": -9.2233720368548e+18
                     },
                     "3": 4    //sub id?
     
    Last edited:
    Joined
    Jun 29, 2013
    Messages
    144
    Reaction score
    64
    • Modder
    • Legacy Citizen 4
    • Purchased!
    Hello Every body, i'm currently working on the new version of SMDecoder but i've some probleme with a new tag.
    This tag is 0xF0, there's an exemple of this occurence:

    Code:
    0xf0     0x3F 0x80  0x00 0x00 0x00 0x00  0x00 0x00 0x03 0xDD  0xDE 0x7E 0x00 0x00  0x00 0x00 0x00 0x00  0x00 0x00
             0x3F 0x80  0x00 0x00 0x00 0x00  0x00 0x00 0x00 0x00  0x00 0x00 0xB3 0xDD  0x00 0x00 0x00 0x00  0x00 0x00
             0x3F 0x80  0x00 0x00 0x00 0x00  0x00 0x00 0x00 0x00  0x00 0x00 0x00 0x00  0x00 0x00 0x00 0x00  0x00 0x00
             0x3F 0x80  0x00 0x00
    if any one has an idea about what kind of data are encoded here...


    Edit: this tag seems to appear only in entity ship
     
    Last edited:
    Joined
    Jul 21, 2013
    Messages
    2,932
    Reaction score
    460
    • Hardware Store
    probably hp, maxHP and armorHP, in which manner they are stored is beyond me at this point though.
     
    Joined
    Jun 29, 2013
    Messages
    144
    Reaction score
    64
    • Modder
    • Legacy Citizen 4
    • Purchased!
    data does not match with the current ship stats and there's also some new data at the end of the file
     

    alterintel

    moderator
    Joined
    May 24, 2015
    Messages
    869
    Reaction score
    596
    • Likeable
    • Community Content - Bronze 2
    • Legacy Citizen 3
    has there been any progress on this. If you could turn a sment file into a text file, Oh the programs I could write. I could make a core mover, ship editor, a ship editor for a mobile android os. The posibilities are endless. Please Please Please finish this project or let me know how I can help. :)
     
    Joined
    Jun 29, 2013
    Messages
    144
    Reaction score
    64
    • Modder
    • Legacy Citizen 4
    • Purchased!
    ATM there's diffrents problem, I've lost some of my research about this new part (my hard drive was broken). Another thing is that I don't really play starmade actually and to track thoses new data i need help, I need to see how thoses value change in different case and for that I need some tester. To update SMDecoder i've also planned a compete rewrite to implement exception handler.
     

    AtraUnam

    Maiden of crashes
    Joined
    Oct 15, 2013
    Messages
    1,121
    Reaction score
    869
    • Railman Gold
    • Competition Winner - Small Fleets
    • Wired for Logic Gold
    Poke: Prodding the values with CheatEngine and then saving a blueprint suggests that values such as power, shields (so possibly armor) are calculated in real time rather than saved in the BP file.
     
    Joined
    Jul 21, 2013
    Messages
    2,932
    Reaction score
    460
    • Hardware Store
    Poke: Prodding the values with CheatEngine and then saving a blueprint suggests that values such as power, shields (so possibly armor) are calculated in real time rather than saved in the BP file.
    Yup. an easy way to prevent cheating by manipulating those values.
     

    AtraUnam

    Maiden of crashes
    Joined
    Oct 15, 2013
    Messages
    1,121
    Reaction score
    869
    • Railman Gold
    • Competition Winner - Small Fleets
    • Wired for Logic Gold
    Yup. an easy way to prevent cheating by manipulating those values.
    Actually they are calculated client-side and I have successfully used cheat engine to create a ship on a server with 10,000,000 e/sec power regen and had it work. Its actually easier to hack multiplayer this way than it is to do it on SP seeing as you only have to sort between the calculated values while the server handles all the applied values (they are seperate for some reason).

    I recommend the devs apply at least some sort of encryption even if its something simple like multiplying the value by 8 for storage then dividing it again when it is called. (Old versions of flash player used to rely on this).
     
    Joined
    Jul 21, 2013
    Messages
    2,932
    Reaction score
    460
    • Hardware Store
    Actually they are calculated client-side and I have successfully used cheat engine to create a ship on a server with 10,000,000 e/sec power regen and had it work.
    To my knowledge the server calculates those values too, expect it doesn't synch them with the client.
     

    AtraUnam

    Maiden of crashes
    Joined
    Oct 15, 2013
    Messages
    1,121
    Reaction score
    869
    • Railman Gold
    • Competition Winner - Small Fleets
    • Wired for Logic Gold
    To my knowledge the server calculates those values too, expect it doesn't synch them with the client.
    Well I put some guns on the core (which had no power regen blocks on it) and successfully damaged an asteroid which stayed damaged when I relogged.
     
    Joined
    Jun 29, 2013
    Messages
    144
    Reaction score
    64
    • Modder
    • Legacy Citizen 4
    • Purchased!
    Okey, tag 0xf0 is for a serie a of four vector4 (float) maybe used for orientation like transform data
    AtraUnam many data are stored inside *.ent files, you can edit inventorys, shield, power, ai config,... juste take time to look inside thoses files, you'll find cool stuff to edit with CheatEngine I think
     
    Joined
    Jun 29, 2013
    Messages
    144
    Reaction score
    64
    • Modder
    • Legacy Citizen 4
    • Purchased!
    Hey there! My recent work on *.smbpm let me see thoses change for the docking struct

    Code:
    00 00 00 02                                                                  -> (int)        2 blueprint type
    03                                                                           -> (byte)       3 unk
    00 00 00 00                                                                  -> (int)        0 unk
    04                                                                           -> (byte)       4 numDouble
    C188020CC1D0020C                                                             -> (double)    -50348440.2266 unk
    C20801064190020C                                                             -> (double)    -12887050290.0 unk
    4188020C41A0020C                                                             -> (double)     50348424.2031 unk
    0000000000000000                                                             -> (double)     0.0 unk
    00 06                                                                        -> (short)      6 numDock
    00 1E Rail-SuperFighter11/ATTACHED_0                                         -> STR (first of 6 docked entities)
    00 00 01 73 00 00                                                            -> unknown bytes
    F3
        FF    01                                                                 -> (byte)       1
        F3
            F3
                F3
                    F8    00 2D ENTITY_SHIP_Rail-SuperFighter10_1431699396955    -> STR
                    F6    00 00 00 0F  00 00 00 08  00 00 00 0B                  -> (int3)       15, 8, 11    pos
                    FE    02 98                                                  -> (short)      664            block id
                    FF    00                                                     -> (byte)       0
                    FF    01                                                     -> (byte)       1
                    FF    64                                                     -> (byte)       100
                00
                F3
                    F8    00 30 ENTITY_SHIP_Rail-SuperFighter10_1431699396955rl4 -> STR
                    F6    00 00 00 08  00 00 00 08  00 00 00 0B                  -> (int3)       8, 8, 11
                    FE    02 97                                                  -> (short)      663
                    FF    04                                                     -> (byte)       4
                    FF    01                                                     -> (byte)       1
                    FF    64                                                     -> (byte)       100
                00
                F0    3F 7E B3 A3  BD CD FF 14  B3 41 9D 0A  00 00 00 00         -> 4x v4f
                      3D CD FF 14  3F 7E B3 A3  31 B2 8E 12  00 00 00 00
                      33 3E 62 F6  B2 26 B8 F7  3F 80 00 00  00 00 00 00
                      00 00 00 00  00 00 00 00  00 00 00 00  3F 80 20 20
                F0    3F 7A 0E 36  BE 5B 63 C8  00 00 00 00  00 00 00 00         -> 4x v4f
                      3E 5B 63 C8  3F 7A 0E 36  00 00 00 00  00 00 00 00
                      00 00 00 00  00 00 00 00  3F 80 00 00  00 00 00 00
                      00 00 00 00  00 00 00 00  00 00 00 00  3F 80 00 00
                F6    00 00 00 0F  00 00 00 08  00 00 00 0C                      -> (int3)       15, 8, 12
    
                F0    35 10 00 00  BF 7F FF FF  00 00 00 00  00 00 00 00         -> 4x v4f
                      3F 7F FF FF  35 10 00 00  00 00 00 00  00 00 00 00
                      00 00 00 00  00 00 00 00  3F 80 00 00  00 00 00 00
                      00 00 00 00  00 00 00 00  00 00 00 00  3F 80 00 00
                FF    00                                                         -> (byte)       1
                FF    00                                                         -> (byte)       1
                FF    00                                                         -> (byte)       1
            00
        00
    00

    has you can see there's 6 bytes (00 00 01 73 00 00) that i don't understand and it's a recurent patteren, if anyone have a suggestion about this, how to format theme (3 shorts, 6 diffrents bytes or any other possibility)
     
    Last edited: