1. Please be advised of a few specific rules and guidelines for this section.

WIP Save Editor discussion

Discussion in 'Other' started by ThisGuy, Dec 6, 2013.

  1. AgentOrange0x78

    AgentOrange0x78 Void-Bound Voyager

    Sweet. I tossed 2 files at you. The older of the two crashed it with an unpack error (SBWparam.class.php on line 99). "311f7b0c5a6a7e0dffdc9ef4345a785a.player" Thats probably because it was from the initial release I think.

    Looks good though ! :D
     
  2. Gear

    Gear Subatomic Cosmonaut

    yeah, older saves will break
     
  3. Ephemerality

    Ephemerality Scruffy Nerf-Herder

    Nice little interface, worked fine for my new save.
     
  4. Phaze

    Phaze Pangalactic Porcupine

    [​IMG]

    1B4FB656958BEEEB4670C8ED74E0C06D.player
     
  5. AureliusO

    AureliusO Aquatic Astronaut

    Gear, if you want to fix the save reader for old AND new saves, make it branch at the version. The game can still read "old" saves.
    Code:
    //53 42 50 46 56 31 00 00 01 A2                      SBPFV1
    //53 42 50 46 56 31 2e 31 00 00 01 A7     SBPFV1.1
    
    It might be interesting just to see what you get. Also, since the first stream size VLQ is length including itself, but not the version, that does not need adjustment.
     
  6. Gear

    Gear Subatomic Cosmonaut

    yeah i know it can read the old saves if i wanted to, but i'm not going to bother.

    I've updated the app to give a notice with an incompatible save
     
  7. AureliusO

    AureliusO Aquatic Astronaut

    I suppose my only argument for compatibility would have been forward-compatibility, but that doesn't exactly help without being to move planets, shipworlds, etc. as well.
     
  8. Gear

    Gear Subatomic Cosmonaut

    The format might probably be pretty volatile during the beta, i'm just going to try to keep up with the changes to support the most recent versions. I want to try to put some focus on the front end.
     
  9. Anonymous

    Anonymous Forum Bot

    Would it be possible to change the skin color of a character to a non-standard color by editing the save? (I.E. Change a human's skin to green)
    I'm pretty sure they use hex code colors for it, but I can't figure out which one does it- editing the saves makes them unusable by the game, with Wordpad.
     
  10. affonso100

    affonso100 Orbital Explorer

    Should be, i've tried changing around with the ?Replace stuff at the beginning of the file, but only to the colors already defined up there
     
  11. Gear

    Gear Subatomic Cosmonaut

    Try editing it with a hex-editor, wordpad is probably messing with characters you cant see.

    I also added support for the older version of the save, woo!
     
  12. Anonymous

    Anonymous Forum Bot

    Just tried that, gave me an exception error. Maybe I should just wait for an official editor, but jeez, I really do want to have a human with weird skin.
     
  13. affonso100

    affonso100 Orbital Explorer

    upload_2013-12-10_17-17-42.png

    From what i understand, the ?replace seems to change a set color from the main image files of each species, to another one, so

    2?replace;d9c189=65000b;

    changes the color d9c189 to 65000b, just keep the left side there, and change the right side, seems to work fine everytime
     
  14. Anonymous

    Anonymous Forum Bot

    Just tried that- the game launched this time, but when I went to choose my character, it crashed without an error to desktop. Tried using a7b4ae to replace all the colors on the right. Is Notepad++ safe for editing this?
     
  15. Gear

    Gear Subatomic Cosmonaut

    What might be happening is that slight modifications to the file bytes are messing things up. There are sections in the save file telling the game how many bytes to expect and what kind. It is very orderly, things that look like whitespace in notepad are often values that are very important (theres just no symbol for that value). Make sure ypu're saving the file in UTF-8 without BOM format and that you are very careful about which characters get replaced. You also cant add more characters unless you change the section that tells SB what to expect.
     
  16. Phaze

    Phaze Pangalactic Porcupine

    For changing colors, the game directly replaces the color hex codes found in the ?replace strings on the sprite that the replace strings are for. This is done for each color required, like the outlines and fill colors.

    Each sprite is made with a color that gets replaced using this method. For example I just made a human character with male hair style 7. The sprite for that looks like this:

    [​IMG]

    Found in /assets/humanoid/human/hair/

    So the source hex codes for it as found using Photoshop are as follows:

    Fill Color: #d9c189
    Outline: #a38d59
    Outline2: #735e3a (the 3 pixels in the lower left)

    In my save, the ?replace string is as follows:

    ?replace;d9c189=425879;a38d59=343965;735e3a=242247

    You can see each of the source hex values from the base sprite in the string and the value to change it to after it. So changing the color is just simply changing these values. My character looks like this currently:

    [​IMG]

    On changing the colors in my save, it looks like this:

    [​IMG]
     
  17. Ephemerality

    Ephemerality Scruffy Nerf-Herder

    Oh, also the last 2 objects listed in the file are what were currently being held (ie I logged out with a flashlight and alien meat dual-wielded).
     
  18. MERRON

    MERRON Space Hobo

    How about source code?
     
  19. Gear

    Gear Subatomic Cosmonaut

    We'll see, If i decide to stop maintaining it I will definitely release it though
     
  20. jospor

    jospor Void-Bound Voyager

    Does anybody know where your location in the universe is stored and how to read it? The X and Y etc.
     

Share This Page