Starbound

Starbound

bk3k's Inventory
 This topic has been pinned, so it's probably important
bk3000  [developer] Mar 17, 2017 @ 11:44pm
Why you character doesn's work and what to do about it.
Your characters fall into 2 groups
  • 1. Characters made without this mod installed
  • 2. Characters made with this mod installed

Group 1 characters won't work with this mod installed.
Group 2 characters won't work without this mod installed.

I can't change this.

Group 1
I'll put it like this.
  • I add 80 slots to the vanilla's 40(120 total per bag/tab).
  • If the game expects 120 slots - then when reading Group 1 characters - it gets to slot 41... hey where's my data?
  • If the game expects a bag named "armoryBag" - then when reading Group 1 characters... hey where's my data?

Group 2
I'll put it like this
  • Characters made with this mod installed will require it to work.
  • If you remove the mod, these characters will have data that the game doesn't know how to handle.
  • If the game reads a Group 2 character's data and sees the "armoryBag" that it doesn't expect (because you removed the mod)... hey what is this?

Solutions
Nothing currently. Potentially a 3rd party program (like a character editor) could fix your old characters, but I don't currently know of any that actually do.

If I find something that does - or cook it up myself - I'll update this thread. You may want to subscribe to this thread in that case.

What you can do for now is ask the devs to address this. I don't know if they currently have such plans. They should do this -

  • Sanitize the data. They already sanitize the items and objects themselves (aka "perfectlygenericitem"). Just need another check before that.
  • A bag/grid/slot that the .player file has no reference to gets added/defaulted to an empty bag/grid/slot.
  • .player file references to bags/grids/slots that shouldn't exist get removed (when/if they can't be ignored).
  • The same can be said of action bars
  • This should happen during the early startup checks.
  • They already sort of do this for action bar count, but in this case they hide the invalid characters - rather than sanitizing the data to make the players valid again.

I probably can eventually craft a migration tool for character data. That will always be an inferior solution compared to proper native support.
  • I can't host that on Steam nor the SB forums.
  • Not sure I'm even allowed to link it in either location - probably a rule violation.
  • I don't love the idea of promoting people to run random scripts or programs someone tells them to run. The concept itself is a bad idea.
  • People may find it difficult to mess with.
  • Most won't notice it exists anyhow.
  • This really shouldn't even be necessary to start with.

edit: Manually converting old characters
fabio.capela made left instructions below on converting your old characters
http://steamcommunity.com/workshop/filedetails/discussion/882900100/133259956011112917/#c2132869574268909855

LittleHero also made this video with similar instructions
http://www.youtube.com/watch?v=T8iutR3H2X0

edit 2: Engine changes
The engine WILL now properly handle me adding things like "armoryBag" and will add that into character data. However it won't tolerate extra slots on characters that didn't originally have them.

It seems to tolerate FEWER slots but that might not be the case if you filled up before hand. More testing needed to confirm that bit.

After adding something like "armoryBag" you can't uninstall the mod and still hope to use the character. Even a formerly vanilla character will now need the mod. Plus formerly vanilla characters require an extra patch from me - that I haven't put out at the point I write this but will soon.

So that's still an improvement in the situation, but that's a one-way trip! Unless you intend to manually edit your files.

edit 3: Automatic Conversion.
Mana made a python script to automate the process - https://github.com/Manaball123/starbound-bk3k-s-inventory-character-convertion-tool/

But there's also now the Open Starbound project, which is overhauling the Starbound engine itself, and handles the conversion in-game (among many other improvements) - https://github.com/OpenStarbound/OpenStarbound/releases
I've only glanced at it, but it seems to be an impressive project.

And apparently, Open Starbound got forked as xStarbound:
https://github.com/xStarbound/xStarbound/releases
I don't really know the difference/reason for the fork. But it's also an option.

Keep in mind that I haven't personally tried any of those solutions (yet), but I wanted to highlight them for those who may need them.
Last edited by bk3000; Oct 24, 2024 @ 8:52am
< >
Showing 1-15 of 99 comments
question : would it be possible to multiplayer between group 1 & 2 ?
e.g. between characters with & without the mod ?
perhaps with "allow mismatch asset" enabled ?

the point would be :
-since I can't migrate the char, maybe I could transfer objects & also planet locations ?
bk3000  [developer] May 7, 2017 @ 9:44pm 
Originally posted by DBH*Whismerhill*{SSgt}:
question : would it be possible to multiplayer between group 1 & 2 ?
e.g. between characters with & without the mod ?
perhaps with "allow mismatch asset" enabled ?

the point would be :
-since I can't migrate the char, maybe I could transfer objects & also planet locations ?

Moving stuff
That shouldn't require multiplayer to accomplish. I would (before installing the mod) take your stuff to a planet somewhere. Take down the coordinates for that planet in notepad etc(probably save it to a file just in case). After that, install the mod.

Then with your new character(once you can travel), put those coordinates in your navigation. That world should be how you left it(thus with your stuff).

Alternatively it would probably work to make a new character, delete their (brand new) shipworld, copy the old character's shipworld file but rename it to the new name the (deleted) world had. You could experience some weirdness from this method (I don't know for sure what would happen when you upgrade). Maybe better to just do the first idea aka put it on a planet.

Backup
Just in case back up your characters though - its always fine advice but especially with things like this.
Multiplayer
I don't play multiplayer so I can't verify this. I'd assume that this would work as long as asset mismatch was allowed. The inventory functions are hard-coded(no custom scripting possible), and I'd have to strongly assume it is all client side. It isn't like this mod adds new items/objects/etc so I wouldn't assume any issues. I'm just making the most of the hard-coded functionality available.

At the very least, no one has told me it doesn't work. Try it and let me know.

Also, I'm currently hoping the devs silently fix the migration issue. I've seen no mention of this for the next update, but you never know with how tight-lipped they are now with the finer details(and the lack of a real nightly build).
Last edited by bk3000; May 7, 2017 @ 9:48pm
wow, thanks a lot for your detailed response :)
hats off :)
zyk Jul 3, 2017 @ 6:05am 
I got a group #1 character to work with this mod after a workshop sync disaster.
Might work the other way too. (#2 -> #1)

Had a vanilla save on one computer and on another computer, the big ~264 mod collection (which included this mod).

Steam synced the mods... and the vanilla save got corrupt upon starting the game. Last backup - ~25 game hours old.. :|


What I did:

Opened both saves using 010 binary editor and by using this template with it[github.com],

I could copy-paste the itemBags values part from the modded one onto the vanilla one. (copy pasting as hex).

Result: A _lot_ of green generic items (eg missing mod items) in the bags but everything else seems to work.

It might be possible to use a working vanilla save file instead and copy those bags onto a modded one, to migrate #2 -> #1. Combined with dumping all items on a planet before the write, nothing should disappear?

I really disliked the mod collection because of all imbalance between all the different mods, everything went EZ mode..

But this mod is a must-have :)
bk3000  [developer] Jul 3, 2017 @ 7:45am 
I'll check that out, thanks
zimberzimber Jul 22, 2017 @ 5:58am 
For group 1 issue - Can't the inventory data be regenerated in case the game reached a non-existing slot?
bk3000  [developer] Jul 22, 2017 @ 9:35am 
Originally posted by zimberzimber:
For group 1 issue - Can't the inventory data be regenerated in case the game reached a non-existing slot?
If the game where programmed to do, yes. Also if there was a modder's version of the versioning scripts to modify player data, then I could also do this.

Neither is true at the current time.
fabio.capela Jul 23, 2017 @ 7:40am 
2
2
2
You can convert a character using the tools provided by the devs in the Starbound\win32 folder (or the equivalent for other OS). It's a bit complex for those that never saw a command line, but it's doable:

1. First, empty your inventory. No need to remove the equipped items, but leaving anything in the bags will not only make it harder to find the piece of data you need to replace, anything left in the bags will also be lost after this procedure is done.

2. Go to the Starbound\storage\player folder and find which of the files ending in .player is the one you want to convert. If you just emptied the character's bags it should be the newest file. Just to be safe, make a backup of the file.

3. Use the dump_versioned_json.exe tool in the Starbound\win32 folder to generate a plain text version of your character file. It's a command line tool, so double-clicking it isn't going to work; one way to do this on Windows is to open the "Run" window (press <windows button>+R); delete anything in the "Open" field; drag to that window the file dump_versioned_json.exe, the player file you found in the previous step twice; go to the end of the line you see and change ".player" to ".json"; then, finally, press enter. You should now have a file ending in .json inside your Starbound\storage\player folder.

4. Open the .json file on your favorite text editor (I recommend Notepad++), then find the following json structure in the file:

"itemBags" : { "materialBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "objectBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "foodBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "reagentBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "mainBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null] },

Replace it with:

"itemBags" : { "armoryBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "objectBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "foodBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "farmBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "reagentBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "mainBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "objectBag2" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "materialBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null], "hobbyBag" : [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null] },

(This is why you should empty your bags first, we are replacing all bags at once with empty ones.)

5. Use the make_versioned_json.exe tool in the Starbound\win32 folder to recreate your .player file. It's also a command line tool. You can do that by opening a Run window, clearing the "Open" field, then dragging to it in sequence the make_versioned_json.exe file, the .json file you just edited, and the .player file. I might use the chance to remind again about backups, as this is the step where the original file is lost; if you didn't make a backup and did anything wrong with the procedure, your character might be lost.

6. Install the mod and enjoy your old character with the new bags.

The procedure to remove this mod is about the same, just the bits of json code for what you find and what you replace it with will be reversed.
Last edited by fabio.capela; Jul 23, 2017 @ 7:41am
sumuvaris Aug 1, 2017 @ 7:52am 
I just followed fabio.capela's instructions and it works. I had to copy the player files to the desktop and convert them from there though, because the original file-path seemed to be too long for the Run window to handle
Cipher97 Aug 7, 2017 @ 5:37pm 
I saw some errors in the command line when I tried to run the make_versioned_json.exe (I haven't done step 6, yet). That normal? (also, I had to create the json file on the desktop then move it into the folder due to the character limits in the run window)

I wonder if my problem was when I did step 3 with a copy of the player file I made on the desktop (I was gonna use that as a backup, but as mentioned earlier, the run command has a character limit for some reason) and moved the json file into the player folder in order to do step 5.
Last edited by Cipher97; Aug 7, 2017 @ 5:45pm
Enzo1403 Sep 18, 2017 @ 2:12pm 
Could it work to add more space/extra bags by consuming an item ingame?
And that item would also undo the changes if needed.
This way, characters always start with a normal inventory, therefore every character is compatible.
And to make them compatible again, after uninstalling this mod, you just have to reset the inventory. And this will also make you save the items that would be lost otherwise.
if you could alter this stuff while in game, then you could write patching code to convert chars between different inventory sizes. so no @Enzo1403
recent blog posts by chucklefish point out to yet again workshop/modding improvements so maybe there is hope in that for 1.4, however I wouldn't expect it before at least 6 month.
Last edited by [DBH].Whismerhill.{SSgt}; Sep 19, 2017 @ 2:13am
bk3000  [developer] Sep 19, 2017 @ 3:15pm 
Things like editing character data of that nature are beyond the modding api. If we had a modders versioning script i could easily modify existing data.

There does exist a backpack mod, but that's an active item which you equip and it brings up a container interface, rather than a true inventory expansion. Kinda neat, but not the same thing at all.
Last edited by bk3000; Sep 19, 2017 @ 3:16pm
A Block of Jelly Sep 21, 2017 @ 10:50am 
Originally posted by bk3000:
Things like editing character data of that nature are beyond the modding api. If we had a modders versioning script i could easily modify existing data.

There does exist a backpack mod, but that's an active item which you equip and it brings up a container interface, rather than a true inventory expansion. Kinda neat, but not the same thing at all.
is my character lost then?
I dowlaoded this mod then unintalled it and now if i pick and item the game closes itself
bk3000  [developer] Sep 21, 2017 @ 12:34pm 
Originally posted by LordSlime:
is my character lost then?
I dowlaoded this mod then unintalled it and now if i pick and item the game closes itself

What does your log say when that happens? Well it might not matter, I'm just curious.

If you can open your inventory without crashing, try to empty it into containers to keep your stuff. Then try fabio.capela's direction above.

If you can't open the inventory either, call your stuff a loss and follow those directions anyhow. It won't look extact as your stuff isn't null.

Either way you are replacing the entirety of "itemBags" with what they provided there. Notepad++'s bracket match highlighting is pretty useful there so you can know where it starts and ends.

And reinstall the mod after converting the character.
< >
Showing 1-15 of 99 comments
Per page: 1530 50