2.2 KiB
| layout | title | description | image | date | categories | published | |||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| blog | Godot .NET with SpacetimeDB | First post. |
|
2026-1-22 |
|
false |
I've been on and off again experimenting with Godot since the great Unity controversy of 2023. At the time Godot came up pretty quickly as the open-source alternative, I'll spare you the history lesson we are here to talk SpacetimeDB! If you found this article I assume you already know what SpacetimeDB is.
Setting up our workspace
Before we get into any programming we are going to do some setup on our project workspace to help things along, we will be thankful for this later! I'm going to be painfully explicit in the details here so bare with me.
Create a project directory
We are going to sidestep creating the root project directory with Godot, this will become apparent as to why later but for now just trust me! 😉
mkdir massive
Init Git
git init
Set tool version with mise
We are going to use mise-en-place to handle our tool versions at the project level, this is a great tool that I now use by default for any new project Im working on. It allows us to keep our tool versions independent of our global settings.
mise use dotnet@8 bun@latest
This will generate a
mise.tomlfile in our project root.
The first tool is obvious, we are writing in C# so of course we need dotnet! Using bun however, let me explain.
Create a new Godot project
Create docker-compose
services:
spacetime:
image: clockworklabs/spacetime
ports:
- 3000:3000
command: start
Create package.json
{
"name": "massive",
"scripts": {
"database:up": "docker compose up -d",
"database:down": "docker compose down",
"database:publish": "spacetime publish --project-path server massive",
"database:generate": "spacetime generate --lang csharp --out-dir client/module_bindings --project-path server"
},
"devDependencies": {
"@types/bun": "latest"
}
}
.editorconfig
root = true
[*]
charset = utf-8