Skip to content

Instantly share code, notes, and snippets.

-- For the animation, run with the love2d game engine
-- For the SVG output, run with the standard Lua interpreter
local size = 14 -- This is the number of hexes on the side of the flat rhombus
local base_hex = {}
local s32 = math.sqrt(3)/2
local rad = 1/math.sqrt(3)
for i = 1,6 do
-- For the animation, run with the love2d game engine
-- For the SVG output, run with the standard Lua interpreter
local narrow = false -- Change this to true to fold around the narrow angle instead of the wide one
local size = 14 -- This is the number of hexes on the side of the flat rhombus
local base_hex = {}
local s32 = math.sqrt(3)/2
local rad = 1/math.sqrt(3)
@Castux
Castux / chasers.map
Last active March 14, 2023 08:55
Chasers map
BEGIN WINTER 759 ADJUSTMENTS
COLONIES (COLONIAL) FOO GOL KOB
DARBARATE (DARBARIAN) OCH SAN SER
EMPIRE (IMPERIAL) LEP MOL OBR
FREECITIES (FREE) ARR HOL TWW
GOLIATHS (GOLIATH) ANA CLI IRO
NEWBARTIZAN (BARTIZAN) ADA NEW SNA
ORCS (ORCISH) BLA CAN DUR GAR
local function parse_changes(meta_dir)
local find_cmd = string.format([[cat `find %s \( -name '*.changes' ! -name '_*' \)`]], meta_dir)
local months = {}
for line in io.popen(find_cmd):lines() do
local ts, kind = line:match "^(%d+)\t%S+\t(%w+)"
local hp = require "gumbo"
local b64 = require "base64"
local banner = "_30q-"
local docBody = "_39k5"
local title = "_4lmk"
local bold = "_4yxo"
local italics = "_4yxp"
local emoji = "_47e3"
local hidden = "_7oe"
@Castux
Castux / module.lua
Last active December 14, 2020 13:11 — forked from zach2good/module.lua
-- Original code
tpz = {}
tpz.testMethod = function(a, b, c)
print(a, b, c)
end
-- 'Module' helper
module = {}
module.override = function(t, name, func)
@Castux
Castux / Bison.lud
Last active November 9, 2020 08:59
(define "ToCenter"
(and
(not (is In (to) (sites Top)))
(not (is In (to) (sites Bottom)))
)
)
(game "Bison"
(players 2)
(equipment {
@Castux
Castux / wstest.lua
Last active October 29, 2020 08:10
local sockets = {}
local weblit = require "weblit"
local app = weblit.app
app.bind {host = "0.0.0.0", port = 8080 }
app.use(weblit.logger)
app.use(weblit.autoHeaders)

Multiplayer online board game sandbox

There are a few existing ones, with each their own characteristics. Which means of course I want to make my own.

Some design principles:

  • keep it simple but versatile
  • in browser, no install needed
  • click and drag 2D interface, compatible with mobile
  • no account needed: join rooms by URL or room code
body
skin (of man)
head
forehead
face
eye
eyebrow
eyelid
eyelash
pupil (of eye)