Getting Started - Your First Project
This page is a work in progress - contributions are encouraged! See notes for details.
This is supposed to be a beginner-friendly walkthrough, as a lot of the content here assumes prior knowledge.
Welcome to S&box!
Formalities over; it's time you started doing something with this opportunity! Roll up those sleeves and get knuckle deep in the mosh pit.
Choosing the right IDE
Visual Studio 2022
An IDE you're comfortable with is a must. We suggest Visual Studio 2022 as the Community-Edition is free and you can open your Code-Base inside S&box right away.
Follow this external guide to help you get set up for C# development.
JetBrains Rider
This is a commercial product, depending on your workflow this might be your preferred choice.
See here, how to get started with Jetbrains Rider
Visual Studio Code
Another Code-Editor. This might your preference due it's performance or simplicity.
See here, how to get started with Visual Studio Code
S&box Game Editor
Next up, start the S&box Game Editor through Steam
Adjusting the Launch Settings
Chances are, you'll be opening this most of the time. If you wish, you can enforce to start the Game Editor by default.
- View the properties of S&box
- Set the Options
Creating a Project
Don't get overwhelmed. There's lots to look at here, but we can work our way through it. You can check out the Editor overview for more information about the different sections of the editor.
First things first, create a project.
Leave the Project Type for this one as Game. Fill in the Project Title and then hit OK.
Opening your project in Visual Studio
Head back to Steam, and open S&box's local files.
Then, open up s&box.sln
Any projects loaded in the S&box Game Editor will appear in this solution.
Just find your_fantastic_gamemode inside of the Games folder. This will appear under the Solution Explorer panel, on the right side of your screen by default.
If you don't see this panel, try clicking on this tab on the right:
Editing the Code
If you don't know what you're looking at now, you're in for a ride and a half.
Get creative! Check out our picks of CSharp Learning Resources to help get you started.
S&box will automatically compile your gamemode whenever you Save (ctrl + s).
Here would be a great place to demonstrate how to playtest your code edits ingame through the Game Editor
Uploading your new Gamemode
Check out the CreatingProjects page.
This page is a work in progress - contributions are encouraged! See notes for details.
This is supposed to be a beginner-friendly walkthrough, as a lot of the content here assumes prior knowledge.