Notice Manually Uploading to Steam workshop with Linux and Mac and Windows

Discussion in 'Starbound Modding' started by The | Suit, Jul 25, 2016.

  1. The | Suit

    The | Suit Agent S. Forum Moderator

    Hi, currently there is no GUI tool for linux and mac, so for those users I created a basic tutorial till a point in time if one ever exists.

    First thing you need to do is download Steam CMD

    Windows: https://steamcdn-a.akamaihd.net/client/installer/steamcmd.zip
    OS X: https://steamcdn-a.akamaihd.net/client/installer/steamcmd_osx.tar.gz
    Linux: https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz

    We do not need to change our files but make sure you have a preview image ready [ The little icon that gets displayed in workshop ]
    I believe the requirements are 512 x 512 upto 1mb - though I am not a 100% sure but anything less than that should work.

    Important note please do note include "< >" in the examples listed below. They are simply to help make a clearer image when file extensions are involved.

    Now create a new text file <yourmodname>.vdf
    and fill it in with this code.

    Code:
    "workshopitem"
    {
    "appid"        "211820"
    "publishedfileid"    "0"
    "contentfolder"    "Location of your mod"
    "previewfile"        "<location of preview image>\preview.jpg"
    "visibility"        "0"
    "title"        "Title"
    "description"        "Description"
    "changenote"        "Initial Release"
    }
    
    • Published Field stands for if the Mod has been published before. Keep it 0 if its the first upload. The published file ID will automatically be changed when successfully uploaded. This will allow you to use the same VDF file to push updates for your mod. If it has been uploaded before - replace it with your Mod ID #.if updating an existing mod.
    • Content Folder The location of your mod - unpacked folder with the metadata file or else make a new folder and rename your pak file contents.pak and place the file inside there. Content folder should point to the empty folder.
    • Visibility 0 = Visible, 1 = Friends only, 2 = Hidden.
    • AppID is the Starbound AppID - which is already provided above
    • Preview File: For OSX and Linux use forward slashes to list the directory. Image can be jpg, gif, png. 512 x 512px and less than 1mb in size.
    Once everything is set - save the file some where. It does not need to be in the mod folder.



    Next you should pak your mod.and rename it contents.pak
    Create a new folder and place only the contents.pak inside.





    Now run Steam CMD and let it finish its initial unpacking and if the window closed run it again.
    If it has not type this in.
    Code:
    login myLoginName myPassword
    
    If you have steam guard on - it will ask you to verify the account by sending you the code to type in afterwards.

    Once you have logged in - type in this code.
    Code:
    workshop_build_item <location of vdf>\<modname>.vdf
    
    Example ( Use forward slashes for OSX \ Linux )
    Code:
    workshop_build_item C:\ws\test.vdf
    If you did everything correct the command line will alert you it is building the file and uploading.
    Finally go to your Steam Workshop page and it will be displayed.

    Capture.JPG




    Need to thank Yukumo for his Quake guide. I wouldn't have been able to write it.
    Thanks @Ev1l0rd - for the corrections.



    A zip file has been added to give you an example.


    Community Tools

     

    Attached Files:

    Last edited: Feb 19, 2019
    YellowApple, Cyel, Ev1l0rd and 2 others like this.
  2. Ev1l0rd

    Ev1l0rd Phantasmal Quasar

    I'm sorry, but the guide is incomplete and seems to be written for Windows, rather than for Linux and Mac. Here are my suggestions:
    • steamcmd is in the default Ubuntu repositories from 16.04+. You only linked the windows version (which isn't even required for this guide). Here are links for the other system versions (including linux, because there are more distros than Ubuntu).
    OS X: https://steamcdn-a.akamaihd.net/client/installer/steamcmd_osx.tar.gz
    Linux: https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz
    • OS X and Linux don't use backslashses (\) in their path, but forward slashes (/). The preview.jpg link is broken due to this. Additionally, I suggest replacing that one entirely with a simple replace path to the image file, as Steam also supports the superior PNG and GIF formats.
    • The visibility flag does not work.
    • The text file has to be saved with a vdf extension. This is not mentioned anywhere in the guide, but steamcmd will refuse to upload the mod if you don't save it with a vdf extension.
    • To do the last step in one command, run it like so (replace the things in <> with the appropriate things). This should be done from a Terminal window.
    Code:
    steamcmd +login <user_name> +workshop_build_item '<path to vdf>' +quit
    • A password is not required for steamcmd, as it should pull it from the normal steam cache. If it is not found, steamcmd will request the password instead. Therefore I suggest removing the password portion of the login command like so:
    Code:
    login <username>
    • If you lose your mod ID, it can be relocated by looking at the address bar for the Workshop page.
    But still, your guide did get me on the right track.
     
  3. The | Suit

    The | Suit Agent S. Forum Moderator

    Glad you filled in the holes.
    Some one asked about an option to contribute mods to workshop for linux and mac and since I owned neither it was basically some guess work and trial and error after an hour of research.

    Even steam's official documentation on Steam CMD doesn't really help, so I had to jerry rig an option from another game.

    Anywho thanks for completing it though!
     
  4. Ev1l0rd

    Ev1l0rd Phantasmal Quasar

    Happy to help. Also, I just discovered another thing, and that is that the mod folder must be in another folder and that folder has to be linked in the VDF file like so:

    Code:
    HUBFOLDER/
    --> ModFolder
    
    (Terrible viewing of how it should look, but anyway)

    And in the VDF file:

    Code:
    "contentfolder"    "PathToHubFolder"
    because otherwise SteamCMD will upload the subfolders of a mod instead.
     
    Telessia and YellowApple like this.
  5. v6ooo

    v6ooo Space Kumquat

    visibility
    0 = visible
    1 = friends-only
    2 = hidden

    You can update a mod without pushing a new name, preview image, description or changenote.
     
    Last edited: Aug 4, 2016
    Cyel likes this.
  6. Febilian

    Febilian Cosmic Narwhal

    Could you please elaborate on this? I'm having a stupid hard time getting a mod uploaded as anything but subfolders. This is my first time trying to use the Steam Workshop, I'm on a Mac, and so far I'm more frustrated than anything.
     
  7. Ev1l0rd

    Ev1l0rd Phantasmal Quasar

    Yeah sure. Here is what the upload folder for one of my mods look like:
    Screenshot from 2016-08-06 12-25-20.png
    The src folder contains a folder called "starbound-classic-glitch-heads" which contains my mods contents. Preview.gif is exactly what it sounds like. README.md is not important.

    uploadfile.vdf contains this (some things blanked for privacy/because they are unrelated):
    Code:
    "workshopitem"
    {
        "appid"        "211820"
        "publishedfileid"        "0"
        "contentfolder"        "/home/ev1l0rd/Desktop/src"
        "previewfile"        "/home/ev1l0rd/Desktop/src/preview.gif"
        "visibility"        "0"
        "title"        ""
        "description"        ""
        "changenote"        ""
    }
    The important thing here is that "contentfolder" is the path to the src folder!

    And when the mod gets downloaded by other users, they get this:
    Screenshot from 2016-08-06 12-31-38.png
    And inside that folder is the mods contents.
     
    Last edited: Aug 6, 2016
    Telessia likes this.
  8. Febilian

    Febilian Cosmic Narwhal

    Thank you! I think I've got it working now. =)
     
  9. agmoyer

    agmoyer Cosmic Narwhal

    Okay so I failed,

    KeyValues Error: LoadFromBuffer: missing { (current key: 'SBAsset6') in file workshopitem [offset: 8]

    ..\tier1\KeyValues.cpp (2609) : Assertion Failed: Error while parsing text KeyValues for resource workshopitem
    ERROR! Failed to parse build config file "C:\Users\Temp-Moyer\Desktop\Warframe_Crossover.pak".


    I feel I am so close... Any help would be awesome.
     
  10. unvonues

    unvonues Void-Bound Voyager

    Really appreciate it mang
     
  11. Monijir

    Monijir Scruffy Nerf-Herder

    Is there any delay between receiving the 'uploading content' response and seeing your mod on the workshop page? I got nothing but confirmation from the steamCMD console but I'm unsure how to proceed from there. Surely the upload confirmation isn't simultaneous with hosting / visibility in the steam client.

    Also, just to clear this up, I was wondering if folders are used instead of .modpaks now because steam workshop scans for malware before hosting and can't be bothered to unpack every little proprietary mod format.

    Should've saved my terminal output. Maybe there's a log somewhere. FWIW I'm running linux/elementaryOS (ubuntu 14.04 based).

    Thanks for the write-up / addends.

    Edit : Everything's fine now, I just had to select view all workshop content rather than sort by newest.
     
  12. Monijir

    Monijir Scruffy Nerf-Herder

    Does anyone know the functional difference between a folder and a .pak being used? I have an issue where only one of my two mods will show up at the same time - whichever wasw subscribed to last. They're perfectly compatible when I just have them in my user folder - but on workshop its something different. Was hoping however people are getting contents.pak would fix it - they do have a single patch file which they both share and maybe that gets messy with folders ?

    IDK pretty big headache though.
     
  13. The | Suit

    The | Suit Agent S. Forum Moderator

    You don't upload pak files to steam. Only the folder - steam paks it at upload.
    Subscribed files are not kept in the mod folder - they are kept in the Steam Workshop folder under the Mod ID number.
     
  14. Monijir

    Monijir Scruffy Nerf-Herder

    Yeah I get that, I meant I moved them to the mod folder so I could test them working outside of the steam/steamapps/workshop/content/21180/ blah blah folders.
    Meaning they worked in concert fiine when using the old .modpak info or dirty edits, but when they were distributed through steam they would conflict with eachother... somwhow? They had separate IDs and pages and all that, but only whichever one was last downloaded would show at once.

    The thing about the packaging is - steam doesn't package my folders. Try downloading the racial hoverbikes mod from workshop and look in its corresponding folder - its just plain files, no paking at all. I'm guessing this is something that comes up with linux because its surprising people when it happens.

    In any case I ended up merging the two after a disastrous attempt to repackage the latter mod ended with a fatal crash on startup. I deleted the latter mod, hopefully it will work out all right for the few who downloaded it. I left instructions for how to remove it manually, because I'm not sure how workshop handles deleted content.
     
  15. Ev1l0rd

    Ev1l0rd Phantasmal Quasar

    Not with the steamcmd method. You will have to pack them manually if you want to use packed files and put the pak file in the upload folder.
     
  16. The | Suit

    The | Suit Agent S. Forum Moderator

    I have never packed any files before using steam command.
    Otherwise the Proof of Concept image at the very top would not be there.
     
  17. Ev1l0rd

    Ev1l0rd Phantasmal Quasar

    Yep. And if you download a mod (take mine for example: http://steamcommunity.com/sharedfiles/filedetails/?id=734399906 ) made with said method and then go to the folder where the mod is downloaded to (which in the aforementioned mod is <steamapps>/workshop/211820/734399906 ) I do not get any pack files. Compare these two:

    Screenshot from 2016-09-13 09-40-10.png
    This one is uploaded with the steamcmd method...
    Screenshot from 2016-09-13 09-40-19.png
    and this one is uploaded through the uploader (this one is FrackinUniverse).


    As you can see, the files aren't packed automatically if you use the steamcmd method. Therefore, we can conclude this: Steam doesn't pak your files on it's own, the Windows uploading tool does.
     
    Monijir likes this.
  18. The | Suit

    The | Suit Agent S. Forum Moderator

    That is really odd -
    I did the test first time with a pak file and all I kept getting were errors on steam cmd.

    I will have to see why is that is.
    I will make the correction for now.

    Thanks
     
  19. Ev1l0rd

    Ev1l0rd Phantasmal Quasar

    That's because you need to create an empty folder, put a prepacked file in there (to make it as close to the 'normal' uploader, name the pak file contents.pak) and then set the content folder to the path of the empty folder. Then you can upload a pak file. Steam just uploads the contentfolder to their servers.
     
    YellowApple likes this.
  20. The | Suit

    The | Suit Agent S. Forum Moderator

    That would explain a lot.
    Alright
     
    Ev1l0rd likes this.

Share This Page