Skip to content

Instantly share code, notes, and snippets.

@TrueBrain
TrueBrain / backport-languages.py
Last active January 27, 2023 23:03
Backporting of PRs and language changes
"""
Put this file in a master checkout under .github/.
It should be next to backport.py.
"""
import argparse
import glob
import subprocess
import shlex
@TrueBrain
TrueBrain / presets.md
Last active April 28, 2024 06:54
Presets

Introduction

If you have played OpenTTD without NewGRFs and GSes for a bit, with the default settings, you get interested in spicing up your game. Currently this requires some pretty good knowledge of all kinds of things:

  • What NewGRFs are good and which work good together?
  • What settings make the game more interested (cargodist) and which should you never touch (inflation)?
  • What GS increases the fun of a game, and in what climate does it work best?

To get answers to these questions is difficult. You need access to any OpenTTD community, and other people need to help you out to piece everything together.

@TrueBrain
TrueBrain / quick-howto-guide.md
Last active July 17, 2021 17:39
Quick how-to guide in setting up development setup for game coordinator

This guide is build for WSL2 / Linux. For Windows it is also possible, but I can never remember Powershell syntax.

The beginning (one-time effort)

Get Python3.8+. Create a venv (for Debian, install python3-virtualenv package first):

python3 -m venv venv
@TrueBrain
TrueBrain / network-debug-levels.md
Created July 11, 2021 10:33
Network debug levels

It now follows very simple rules:

  • 0 - Fatal, user should know about this
  • 1 - Error, but we are recovering
  • 2 - Warning, wrong but okay if you don't know
  • 3 - Info, information you might care about
  • 4 -
  • 5 - Debug #1 - High level debug messages
  • 6 - Debug #2 - Low level debug messages
  • 7 - Trace information
[SDT_OMANY]
var = game_creation.landscape
type = SLE_UINT8
from = SLV_97
guiflags = SGF_MULTISTRING | SGF_NEWGAME_ONLY
def = 0
max = 3
full.LT_TEMPERATE = temperate, 0
full.LT_ARCTIC = arctic, 1, subartic
full.LT_TOPIC = tropic, 2, subtropic
@TrueBrain
TrueBrain / checklist.md
Last active July 18, 2021 17:39
Checklist for master -> main

Few things happening for each repository:

  • Rename "master" into "main"
  • Cleanup workflows to use the new centralized versions (instead of custom shell-scripts copied everywhere)
  • Enable the "check annotation" step
  • Ensure "default" branch can be anything configured

Repositories left to do:

  • aws
@TrueBrain
TrueBrain / network-todo.md
Last active August 10, 2021 20:13
Network TODO list

GC = Game Coordinator

Cleanup

  • ✓ Server name not empty (or default to "playername's server"?)

Client Info

  • 9114 Add GAME_INFO to TCP and use it for lobby
  • 9469 Sync NetworkGameInfo from server with all clients, so clients locally know the server they are on (and sync servername changes when they happen); possibly only sync information client doesn't already know via a Command packet.
  • 9469 Show server name in GUI
@TrueBrain
TrueBrain / integration.md
Last active March 26, 2023 14:50
Steam / Discord integration (Rich Presence)

To start with, few things to keep in mind:

  • I am not a lawyer.
  • Neither are you.
  • 1000 people 1000 opinions; this is not so much about opinions, but about facts, options, and risk.
  • I did a morning of searching the web to gather this information, just so we have something to talk about. To bring this a bit more into facts rather than opinions we all have on what GPL is and isn't :D

Problem description

With us going to Steam, the request for Steam integration has increased.

@TrueBrain
TrueBrain / redesign.md
Last active February 13, 2025 18:41
OpenTTD UI redesign

Intro

image

New game

image

New game - Advanced

@TrueBrain
TrueBrain / workflow.md
Last active February 2, 2021 18:44
Title game competition
  • Organiser announces title game competition, and give an end-date for entries.
  • After end-date, organiser adds all savegames + metadata to git repo (say, OpenTTD/title-game-competition).
  • GitHub Actions generates the required screenshots + Markdown for it, and publishes this in another branch (say, "output"), which is published via GitHub Pages (read: available via https).

  • Organiser creates a "QA" Discussion thread for Title Game Competition.
  • Each entry will be its own reply.
  • People can upvote the reply if they like it.
  • After closing, we have a winner.