new-frontiers-14 / frontier-station-14

A multiplayer game about paranoia and chaos on a space station. Remake of the cult-classic Space Station 13.
https://spacestation14.io
GNU Affero General Public License v3.0
79 stars 463 forks source link

Add 'Server/Client (Release)' build for VSCode #1678

Closed arimah closed 1 month ago

arimah commented 1 month ago

About the PR

This PR adds a new build target specifically to the VSCode config: "Server/Client (Release)".

Why / Balance

Over the past many months of mapping for Frontier and helping others map for Frontier, I've noticed one recurring problem: people map in debug mode, and get annoyed or discouraged when the game keeps crashing. Unlike Visual Studio, the very popular and generally easier-to-use VSCode does not have any easy way of forcing a release build. Visual Studio has a Debug/Release dropdown, VSCode has nothing. "Run Without Debugging" still creates a debug build and just doesn't attach a debugger to it. To run a server in release mode, additional hoops must be jumped through, making mapping needlessly complicated for non-coders.

To help people have a better time whilst mapping, this is my solution: just add the thing people actually want. What could be easier than a single button press? It's also easier to shut down the server by pressing a nice stop button than remembering to use the unintuitive key combination Ctrl+C inside the terminal.

"You should upstream this"

Upstream has way fewer active mappers. Those who develop for the game generally want to test in debug mode to catch errors and such. I believe this change is more meaningful to Frontier than to upstream. In practical terms, these files basically never change and conflicts are likely to be rare and easily resolved.

How to test

  1. Set up Frontier in VSCode.
  2. The 'Run and debug' dropdown should have a new option: "Server/Client (Release)".
  3. Run with and without debugging. Verify that it starts in release mode. One way of doing that is to make note of whether the lobby screen appears: in debug mode, you get thrown straight into the game (unless you've specifically set the cvar game.lobbyenabled to true).

Media

image

Breaking changes

Nopers.

Changelog N/A, developer-facing change

dvir001 commented 1 month ago

Based