sociallydistant/README.md

107 lines
4.1 KiB
Markdown
Raw Normal View History

NPCs, Chat, UI polish, and Spring Cleaning - Fix issue where whitespace doesn't get skipped at the start of parsing the next shell instruction in script parser - Add support for importing chat scripts into Unity - Add dev tools for chat scripts - Add support for shrugging in a chat script - Allow NPCs to send messages through chat scripts - Add support for observing chat branch updates in the UI - Add support for clicking chat branch choices - Hide chat branch list when the message input isn't in focus - Visually polish the Interact menu - Add player typing animation in chat - Fix NPC typing delays - Add support for starting NPC interactions without dev tools - Add support for chat script conditions - Add support for tracking completed NPC interactions - Add support for MissionComplete, InteractionComplete, WorldFlag, and Lifepath interaction conditions - Add support for relationship-based encounter conditions - Add support for witness conditions and skill level conditions - Add support for generating mention links - Add Typer data to channels in World - Add support for typing indicators - Add support for interaction condition policies - Remove script execution time logging - Add better support for world tables with Narrative IDs - Fix handling of drag selection in the Terminal - Optimize desktop layout - Add support for loading content from Asset Bundles. - Move websites and missions to asset bundles - Use AssetBundles to store and load GUI programs - Convert GameManager into a singleton - Convert MailManager into a singleton - Convert MissionManager into a singleton - Cobvert WorldManager to a singleton - Fix ContentManager erroneously unloading asset bundles - Move exploits and payloads to Asset Bundles - Move all Command assets to Asset Bundles - Optimize various UI issues with Terminal - Fix chat auto-scroll not reaching the bottom - Add support for typing-based choices in chat - Add support for new message animations in chat - Cache interaction script syntax trees during game load - Cache mission script ASTs on game load - Fix chat not unsubscribing from backend observables - Add support for loading and saving the world from another thread - Fix major performance issues with desktop login - Polish style of chat UI - Revert support for StaticWidgetList pooling - Fix issue where Unity hangs if importing too complex of a chat script - Add support for generating NPCs via script - Finish NPC generation scripts - Use toggle switches in settings instead of checkboxes - Retexture the Input Field - Add minor tweaks to SectionWidget and window icons - Add various audio effect toggles for later use - Add various UI sounds - Replace typing sound - Add support for loading network assets from Asset Bundles - Add input field border animation - Finish animating Input Fields - Properly theme dropdowns - Add animations to dropdown interactions - Switch from Trixel-Creative/TrixelAudio to our own fork - Port audio code to acidic-audio - Remove all obsolete TrixwelAudioSource objects - Remove all references to TrixelAudioSource in code - Remove all missing script references - Remove old Settings Widgets and Graphic Picker - Change how the game boots - Add support for changing the game's initialization flow via UI - Add various settings for controlling game boot - Add support for case/esac statements in sdsh - Merge ChatImporter with ShellScriptImporter - Allow player to disable the glitch bands effect - Properly theme buttons - Fix glitch bands not applying their settings at game start - Replace missing close button texture with shitty programmer art - Add support for generated default avatars - Improve anti-aliasing of the person in the default avatar - Add support for MSAA - Use new AvatarWidget in all Chat UI - Use new Avatar Widget in main menu
2024-04-30 22:37:25 -04:00
## Socially Distant
This is the open-source base framework for Socially Distant, an up-coming hacking game for PC on Steam. This repository doesn't contain the game's Career mode or any assets related to it.
You should not treat this version of the game as a trial/demo of Socially Distant, it does not contain enough of the actual game to be used as such. You can, however, use it as a launchpad for building community mods and Steam Workshop assets.
### Getting started
To get the game running:
1. Install Unity 2021.3.12f1.
2. Install a .NET IDE
3. Clone the repository and open it in Unity Hub.
4. Wait.
When Unity Editor launches, navigate to "Quick Actions" -> "Enter Bootstrap Scene" to load the initial bootstrap scene. This will boot you into the in-game OS with a fresh, temporary world for testing. Only the filesystem of the player's computer will be saved, as well as the game's global settings in the Registry.
### Career mode?
If you are a core maintainer of the Steam version of Socially Distant, you should be both a member of this organization and the game's Steamworks app. You should have access to a private repository containing the game's Career Mode data.
To set up a Career-enabled development environment:
1. Follow the Getting Started section above to get Unity running.
2. Open a terminal to the game's repository, then `/Assets/GameModes`.
3. Run: `git clone https://github.com/alkalinethunder/SociallyDistantCareer Career`.
4. Wait for Unity to see the new `/Assets/GameModes/Career` folder and import its assets.
You will then see a new entry in the Quick Actions menu to "Enter Career Bootstrap". This will load the Career Bootstrap scene, which will bootstrap Steamworks integration and other core systems needed for a paid version of Socially Distant. You will need to be signed into Steam and own the game.
### Programming conventions
All code in Socially Distant must follow these conventions, or I will crush you.
#### Prefer properties over public fields
Unless you are working in a `struct`, use public properties in place of public fields - i.e:
```csharp
// Bad
public class MyClass
{
public int RamUsage;
}
// Good
public class MyClass
{
public int RamUsage { get; set; }
}
```
Public properties allow for explicit access control, allowing writes to be restricted and validated.
#### Nullable reference types
Use them.
#### Public Inspector fields
**Do not** use them. Use private fields marked with `[SerializeField]` instead. If needed, expose the serialized value as a public get-only property.
```csharp
// Bad
public class GameBootstrap : MonoBehaviour
{
public GameManagerHolder gameManager = null1;
}
// Good
public class GameBootstrap : MonoBehaviour
{
[SerializeField]
private GameManagerHolder gameManager = null!;
}
```
This prevents unintentional modification of serialized values, you almost will never intentionally do it.
#### Getting components
Use `MustGetComponent` instead of `GetComponent()` when the component is mandatory for the script's functionality. This will retrieve the required component and assert in the console if no such component could be found. Saves you a bunch of repetitive null-checks.
This, and other helper functions, are provided by our lovely friends at Trixel Creative as part of their core libraries. We're lucky to have them, they make our lives easier, so use them.
#### Non-nullable serialized references
Use `this.AssertAllFieldsAreSerialized()` to check all mandatory serialized references and assert on any that are missing or null. It will print an error to the console saying which serialized references are invalid.
Example:
```cs
public class GameBootstrap : MonoBehaviour
{
[SerializedField]
private GameManagerHolder gameManager = null!; // Mandatory
[SerializeField]
private string? gameName; // Optional
private void Awake()
{
this.AssertAllFieldsAreSerialized(typeof(GameBootstrap));
}
}
```
2023-02-20 15:42:04 -05:00
This will skip over any fields marked as nullable references.