Skip to content

Instantly share code, notes, and snippets.

View hlysine's full-sized avatar

Henry Lin hlysine

View GitHub Profile
@hlysine
hlysine / README.md
Created May 8, 2025 08:56
Setting up a Screeps:World private server on Ubuntu (WSL) (Last updated May 2025)

The Screeps:World server uses pretty outdated technologies which is a huge headache when you want to set up a private server at the present day. This is a documentation of how I managed to get the server up and running without relying on the Steam GUI version.

1. Set up your environment

I am using Ubuntu in Windows Subsystem Linux for this server. Install the following prerequisites for the server and take note of the exact versions needed since they are mostly outdated.

  • Node v10.24.1 (I recommend nvm for this: https://github.com/nvm-sh/nvm)
  • Python v2.7.18 (I recommend pyenv for this: https://github.com/pyenv/pyenv)
  • build-essential v12.9ubuntu3 (Newer/older versions might be fine, but beware of compile errors due to different gcc versions) (Install with sudo apt install build-essential)
@hlysine
hlysine / BH-banners.md
Last active June 19, 2024 15:13
Rotating BH banners for mods with more than one author

Last updated: June 2024

This is a guide on how to create your own rotating BH banner (or another other image) which can be used in mod description pages and anywhere else that supports loading images with URLs. This is especially useful if you have more than one author on a mod and want to split the BH ad traffic.

Example: BisectHosting

This banner will change periodically depending on how long the image is being cached for. It also redirects you to a random partner link when it is clicked.

Requirements

@hlysine
hlysine / elevator-saga.d.ts
Created May 4, 2024 13:55
Elevator Saga Type Definitions
/**
* Type definitions for the Elevator Saga programming game at https://play.elevatorsaga.com/
*/
declare module 'elevator-saga' {
export interface ElevatorEvents {
/**
* Triggered when the elevator has completed all its tasks and is not doing anything.
*/
(event: 'idle', fn: () => void): void;
/**
@hlysine
hlysine / README.md
Last active April 17, 2024 06:36
Responsive Sidebar on Discord

Responsive Discord

Inspired by https://github.com/samuelthomas2774/bd-hide-sidebars

A BetterDiscord theme that collapses the Discord sidebars and tweaks large elements when your window is too small. Hover over the collapsed area to access the sidebars.

Install BetterDiscord, then import the following file as a theme. (You can download the file by clicking Raw, and then right-click and select Save as...)

Download file