Skip to content

Instantly share code, notes, and snippets.

View arachonteur's full-sized avatar

victoria lacroix arachonteur

View GitHub Profile
@arachonteur
arachonteur / shoot.lua
Created February 12, 2018 16:17
A quick bullet-velocity demo for my good friend Jade
-- title: shoot test
-- author: vriska done it
-- desc: hope this helps
-- script: lua
-- input: mouse
t=0
entities = {}
-- This function returns a 2d vector
@arachonteur
arachonteur / TinyDungeon-Cart.lua
Created May 13, 2018 17:15
Tiny Dungeon TIC-80 Cartridge & Source
-- title: Tiny Dungeon
-- author: team slime
-- desc: a dashing dungeon game
-- saveid: td
local a={}_mget=mget;_mset=mset;_btn=btn;_btnp=btnp;_sfx=sfx;local b=0;function sfx(...)if game.flags.sound then return _sfx(...)else return false end end;function mget(c,d)return _mget(Camera.x+c,Camera.y+d)end;function btn(...)local e=_btn(...)if e then game.moved=true end;return e end;function btnp(...)local e=_btnp(...)if e then game.moved=true end;return e end;function mset(c,d,f)if b==0 then a[c..","..d]={x=c,y=d,id=mget(c,d)}end;return _mset(Camera.x+c,Camera.y+d,f)end;t=0;lt=0;dt=0;dts={}avg_dt=0;game={qs=0,timer=0,width=240,height=138,roomWidth=30,roomHeight=17,collapse=0,shutter=0,buttons=0,broken=false,drawMap=false,orbs={},flagOrder={{"has_g","has_b","has_m","has_r"},{"sound","music","loaded","opened_final_zone"}},flags={has_r=false,has_b=false,has_g=false,has_m=false,sound=true,music=true,loaded=false,opened_final_zone=false},save=function(self)for g,h in ipairs(self.flagOrder)do local i=""for j,k in pairs(
@arachonteur
arachonteur / camera.lua
Created May 29, 2018 04:46
a lua camera
--
--
--
--
--
local camera = {
TWEEN = 1,
SET = 2,
@arachonteur
arachonteur / sokobangarang.lua
Created February 5, 2019 18:04
sokobangarang, a pretty mediocre prototype for something i instantly realized i didn't want to make
-- title: sokobangarang
-- author: victoria lacroix
-- desc: a pretty mediocre prototype for something i instantly realized i didn't want to make
-- script: lua
t = 0
lt = 0
dt = 0
dts = {}
avg_dt = 0
@arachonteur
arachonteur / rexpaint.lua
Created March 16, 2019 16:03
A lightweight REXPaint .xp file reader for LOVE2D.
--
--
--
--
--
local exp = {
version_bytes = 4,
layer_count_bytes = 4,
@arachonteur
arachonteur / rexpaint.lua
Created March 16, 2019 16:09
A lightweight REXPaint .xp file reader for LOVE2D.
--
-- A lightweight REXPaint .xp reader for LOVE2D.
-- By Vriska Serket / @arachonteur
--
-- Output table looks like this.
--[[
{
version = 0,
layerCount = 0,
layers = {
@arachonteur
arachonteur / psd_export.py
Created October 22, 2022 01:10
Python script for exporting layers from a PSD file
from psd_tools import PSDImage
import sys, os
def parse_layers(group, current_dir = ""):
for layer in group:
if layer.is_group():
target_dir = (current_dir + "\\" + layer.name).replace(chr(0), "")
if not os.path.isdir(target_dir):
os.mkdir(target_dir)
parse_layers(layer, current_dir + "/" + layer.name)
@arachonteur
arachonteur / make_gifs.py
Created October 14, 2024 14:18
Python script for processing a directory of frame sequences, and using Gifski to turn them into GIFs. Recurses nicely, exports consistently.
import os
import subprocess
import sys
import shutil
# CHANGE THESE TO YOUR FRAME SEQUENCES AND OUTPUT FOLDER
base_input_folder = "frame sequences"
output_folder = "gifs"
def pngs_to_gif(input_folder, output_folder, fps=15):