Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

[SOLVED] Uploading my game to STEAM from Mac

Discussion in 'macOS' started by Aenah, Aug 14, 2019.

  1. Aenah

    Aenah

    Joined:
    Apr 1, 2013
    Posts:
    29
    Good morning, people.

    I come looking for wise tips, because after developing the video game I had in mind, I got stuck in something I didn't expect. The point is I want to publish a first version of the game (to be tested by trusted people) on STEAM. I tell you what I've done so far and where my doubts/problems begin to arise.

    1. I signed up for Steam, filling in everything I was asked and i have the account ready.

    2. I created a new application inside.

    3. I thought that the way to upload my game would be similar to the one they have on Android and iOS, that is, that the Steam website itself would let me upload the necessary files for the execution of the game. But after a lot of searching in the Steam interface and not finding a place to upload binaries, I investigated more carefully online and the conclusion I took is that this whole upload process has to be done through what they call SteamPipe.

    4. I started to investigate how the SteamPipe thing works and the first thing I did was go to the Steam page (developer zone), go to the SteamPipe/repositories section and create a new one.

    5. I downloaded the steam SDK on my computer and searched for the app_build_1000.vdf and depot_build_1001.vdf files. Here I changed the 1000 and 1001 to my app ID and my repository ID respectively.

    6. I opened the files and changed the IDs again.

    7. In depot_build.vdf I changed the LocalPath parameter to point to the place where I was going to paste the mygame.app created by Unity (I'm testing the mac version first).

    Now come my doubts:

    1. Am I in the good way or is there another simpler way to upload my game to Steam?

    2. In case of going well, I know that I have to run the file in the terminal steamcmd.sh but I do not quite know what parameters to pass it. I read on a site that would be the following:

    bash ./builder_osx/steamcmd.sh +login username password +run_app_build .. /scripts/app_build_342980.vdf +quit

    But I have not been able to interpret it (can anyone give an example with real data?).

    3. My game also works under windows. Do I have to do the same but running the steamcmd.exe file? I understand I can't do it since my Mac.

    Well, thank you in advance.
     
  2. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,294
    I seem to remember that last time I was involved in this process, the documentation in the steam developer portal was decent enough, with step-by-steps on how to do this. It might be that it was a bit clunky to find those docs, though.

    Have you looked through the devportal docs? I swear they are... somewhere.
     
  3. Aenah

    Aenah

    Joined:
    Apr 1, 2013
    Posts:
    29
    Hi, Baste.

    Thanks for your reply. Steam has this video:



    from two years ago. On the video, they explain how to do it for windows version, but my doubts are mainly four:

    1. Is there today an easier way to upload binaries?
    2. If not, How works on Mac terminal?
    3. Can I use a Mac for uploading windows versión?
    4. If the answer to the point number 3 is "yes", ¿how can I do it?

    Thanks. I hope someone here can help with his experience.
     
  4. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,294
    I have no idea how to do things on a mac, so I can't help you there. Aslo, I doubt Steam has improved the process since two years ago, they don't move very fast.
     
  5. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    11,847
    It is a pain to initially set up, but it isn't that bad afterward. My game is getting pretty large, and I like that they reduce upload times by only sending new or changed blocks. So all you do after having done it once is delete everything in the content folder, copy your new build there, and run the bat file to upload. Done other than setting the new build to be pushed out to users in the steam publisher site.

    Latest version of the Steam SDK seems to work the same as it did 2 years ago.
     
  6. ShilohGames

    ShilohGames

    Joined:
    Mar 24, 2014
    Posts:
    3,015
    Steampipe is a bit of a pain the first time you set it up, but it works really awesome. I absolutely love it. I build my game, copy it into my Steampipe content folder, run my batch file (to launch Steampipe), and then I select that new build in the web menu. Small updates to a game only take a short period of time to upload this way, because Steampipe only uploads the changes. And it has build in support for managing multiple platforms. When I run my batch file, it automatically and quickly updates PC, Mac, and Linux. Anyway, I really do love Steampipe.
     
    frosted and Joe-Censored like this.
  7. QFSW

    QFSW

    Joined:
    Mar 24, 2015
    Posts:
    2,906
    If your game is small enough you can upload it via their website directly, but honestly I'd get used to steam pipe instead
     
    Joe-Censored likes this.
  8. frosted

    frosted

    Joined:
    Jan 17, 2014
    Posts:
    4,044
    yeah i do the same. Super easy once it's all set up. For other updates you can publish to beta branch for testing within steam.

    Setup was just like changing a few app ids and targeting the depot id.
     
    Joe-Censored likes this.
  9. Aenah

    Aenah

    Joined:
    Apr 1, 2013
    Posts:
    29
    Thanks for your answers. I have some questions:

    1. Can I use a Mac for uploading windows versión?
    2. Do you have an example for the content in steamcmd.sh? Something like this but with "real" data:

    bash ./builder_osx/steamcmd.sh +login username password +run_app_build .. /scripts/app_build_342980.vdf +quit
     
    Last edited: Aug 17, 2019
  10. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    I wish we could have different executbles in different branches on steam. Unity changed naming standard somewhere down the line in 2018. So now it uses the product name for the executable name instead of letting the user set the name like before.

    So in our case VirtualWarfighter.exe now becomes Virtual Warfighter.exe. If we change the exe name on steam the version that is out will break and people will not be able to start the game.

    Actually excutable name should be tied to the steambuild not branch btw. Because when you release a new build it will take some time for all players to get the new version, steam sometimes require a restart for the update to take.

    So potentielly both exe names can exists side by side for hours.
     
  11. BonneCW

    BonneCW

    Joined:
    Jan 22, 2017
    Posts:
    123
    That's not true. You can specify the executable to be launched for every platform, that's absolutely independent from your product name on Steam.
     
  12. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    Were is that option? Unity support does not even know about it since I reported this to them and they said thats how it is.

    upload_2019-8-17_10-40-52.png

    upload_2019-8-17_10-41-36.png
     
  13. BonneCW

    BonneCW

    Joined:
    Jan 22, 2017
    Posts:
    123
    Ah, sorry, I read Steam because that's a Steam thread not a complain about Unity one. I should read more carefully and you shouldn't move the topic to something unrelated.

    Building via script instead of the UI should still be able to name the executable the way you want, I think I did this once with 2019.1.
     
  14. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    Its you that are moving it. I complained about how you pin point executable names in STEAM

    edit: I build my game on a build server, so technically I can rename the Data folder and the exe, but who knows which side effects that will have
     
  15. Aenah

    Aenah

    Joined:
    Apr 1, 2013
    Posts:
    29
    Thanks for your replies, but I am afraid we are moving the point of this thread.

    The questions are:

    1. Can I use a Mac for uploading windows versión?
    2. Do you have an example for the content in steamcmd.sh? Something like this but with "real" data:

    bash ./builder_osx/steamcmd.sh +login username password +run_app_build .. /scripts/app_build_342980.vdf +quit

    Any extra information about uploading a game from a Mac to Steam using steampipe will be great and a big help for me.

    Thanks.
     
  16. Aenah

    Aenah

    Joined:
    Apr 1, 2013
    Posts:
    29
    Well, solved.

    Here the example you need write in Mac terminal:

    bash /Unity3D/STEAM/sdk-2/tools/ContentBuilder/builder_osx/steamcmd.sh +login myCompanyUserName miSecretPassword +run_app_build ../scripts/app_build_XXXXXX.vdf +quit
     
  17. QFSW

    QFSW

    Joined:
    Mar 24, 2015
    Posts:
    2,906
    You could either write a custom build script in Unity (this change doesn't affect their API for making builds, only their included build window) or write a script to change the names after the fact
     
  18. AndersMalmgren

    AndersMalmgren

    Joined:
    Aug 31, 2014
    Posts:
    5,358
    Only way I know of, is to rename the resulting Data folder and exe. And we do not know if there are side effects of doing that
     
  19. DearUnityPleaseAddSerializableDictionaries

    DearUnityPleaseAddSerializableDictionaries

    Joined:
    Sep 12, 2014
    Posts:
    135
    What exactly do you zip via the website? Just the .exe file? So I don't need the SDK if I do it that way?
     
  20. Murgilod

    Murgilod

    Joined:
    Nov 12, 2013
    Posts:
    10,083
    This is a job for Steam's documentation and support, not Unity's.
     
  21. DearUnityPleaseAddSerializableDictionaries

    DearUnityPleaseAddSerializableDictionaries

    Joined:
    Sep 12, 2014
    Posts:
    135
    Thanks! It was easier than I thought, I prefer the command system now over uploading via the website.
     
  22. nico_st_29

    nico_st_29

    Joined:
    Mar 14, 2020
    Posts:
    69
    I did the above but I got the following error. Any idea?

    /Users/nicolas/Desktop/sdk/tools/ContentBuilder/builder_osx/steamcmd.sh: line 37: /Users/nicolas/Desktop/sdk/tools/ContentBuilder/builder_osx/Steam.AppBundle/Steam/Contents/MacOS/steamcmd: No such file or directory

    FAIL: 127
     
  23. syu15

    syu15

    Joined:
    Feb 1, 2021
    Posts:
    4
    If you are getting the same error as above, you need to follow these steps as outlined in the SteamPipe documentation:

    SteamCmd on macOS
    To enable SteamCmd on macOS you must complete the following steps:
    1. From the terminal, browse to the tools\ContentBuilder\builder_osx\osx32 folder
    2. Run chmod +x steamcmd
    3. Browse up to the parent folder (tools\ContentBuilder\builder_osx)
    4. Type bash ./steamcmd.sh
    SteamCmd will then run and update to the latest build, leaving you in the SteamCmd prompt

    Type exit and press return to exit the prompt.
     
    DannyDeer likes this.
  24. InfinityBeard

    InfinityBeard

    Joined:
    Feb 1, 2015
    Posts:
    7
    Sorry to bump an old thread, but I found this on a google search and I'm sure someone else will come across this this in the future. Here's the steps from start to finish to upload from Steam on a Mac:

    1. Download the Steam SDK from here.
    2. Place it where you like, but remember the file path. I placed it in my root user folder for simplicity.
    3. Open up Terminal. (Note: If on Apple Silicon, you may want to check to make sure you're in an x86 terminal. Not sure what support it has for arm processors. This can be determined via uname -m in the shell, which should return x86_64. If not, right click Terminal in your Applications/Utilities folder and click "Get Info". Then, tick "Open using Rosetta" and open.
    4. Next, in Terminal navigate to your sdk folder and execute the following commands:

    Code (Bash):
    1. cd sdk/tools/ContentBuilder/builder_osx/
    2. chmod +x steamcmd
    3. bash ./steamcmd.sh
    This will do its setup and open up the Steamcmd. You'll know if it worked if you see Steam>.

    5. Next, type login <username> <password>, substituting your credentials. You will be prompted for your steam guard code after executing if necessary.
    6. Place all of your build files in the sdk/tools/ContentBuilder/content/ folder. For me, I have both a windows and Mac version of my game, so I put them each in ".../content/content_windows/" and ".../content/content_mac/" respectively.
    7. In the Finder, navigate to the sdk/tools/ContentBuilder/scripts" folder and open simple_app_build.vdf in a text editor. This is going to contain some information you will need to change and should look like so:

    Code (Bash):
    1. "AppBuild"
    2. {
    3.     "AppID" "1000" // your AppID
    4.     "Desc" "This is a simple build script" // internal description for this build
    5.  
    6.     "ContentRoot" "..\content\" // root content folder, relative to location of this file
    7.     "BuildOutput" "..\output\" // build output folder for build logs and build cache files
    8.  
    9.     "Depots"
    10.     {
    11.         "1001" // your DepotID
    12.         {
    13.             "FileMapping"
    14.             {
    15.                 "LocalPath" "*" // all files from contentroot folder
    16.                 "DepotPath" "." // mapped into the root of the depot
    17.                 "recursive" "1" // include all subfolders
    18.             }
    19.         }
    20.     }
    21. }
    8. Change the AppID number to your app ID, Desc to what you want to appear in the build description on steamworks, the number next to DepotID for the depot in question, and then the LocalPath value to where you stored your files (for example, my windows depot was within a subfolder of content, so I entered ./content_windows/* here. If you have additional depots (like a windows and Mac version of your game), copy the "Depots" {...} code and duplicate it, substituting the depot ID and local path values to your other depots.
    9. Save the document as something new, such as your_app_build.vdf.
    10. Go back to the Steam Terminal and execute the following:

    Code (Bash):
    1. run_app_build ..\scripts\your_app_build.vdf
    It should upload it and you should see the new depot in your steamworks page. Check to verify that files were added correctly to each depot before publishing. Viola!!
     
    3dmars, fullerfusion, blutcat and 4 others like this.
  25. michael_unity730

    michael_unity730

    Joined:
    Oct 27, 2020
    Posts:
    1
    This is exactly what I needed. thank you so much!
     
    InfinityBeard and AlterHaudegen like this.
  26. AlterHaudegen

    AlterHaudegen

    Joined:
    Jul 8, 2013
    Posts:
    28
    Viola! :D

    Seriously, this helped a ton. I was just trying to use it in a similar way like I did on Windows, where I had no trouble setting it up, but on Mac it kept complaining about not finding files. Looks like it did not like the absolute paths I was using, but using relative paths like you're suggesting I got it to run finally, so thanks!
     
    InfinityBeard likes this.
  27. samcshum

    samcshum

    Joined:
    Aug 5, 2021
    Posts:
    1
    @InfinityBeard and @AlterHaudegen, how do you prepare the Mac build to be uploaded? I try uploading the file as (for example) MyGame.app file, it wouldn't upload. I tried extracting the contents of MyGame.app into a separate folder and try to upload that folder. That also failed. I have no problem uploading the PC build. Steam terminal just gives me this error: ERROR! Build for depot 2728111 failed : Failure. Any tips on preparing the Mac build would be greatly appreciated. Thank you in advance.