All New

user:thomas gists created by user

title:mygist gists with given title

filename:myfile.txt gists having files with given name

extension:yml gists having files with given extension

language:go gists having files with given language

topic:homelab gists with given topic

Register

Login


All New Register Login

All gists

Recently created
Least recently created
Recently updated
Least recently updated
yumaikas's Avatar

yumaikas / mechanistic_pumpkin_bread_recipe.nv

0 likes
0 forks
1 files
Last active 1734870777
1 |_| Pumpkin Bread Recipe
2
3 || start oven, gather equipment, gather ingredients
4
5 | start oven, imperial | oven fahrenhiet:375
6 | start oven, metric | oven celcius:190
7
8 | gather equipment |
9 fetch medium bowl, fetch large bowl,
10 fetch half teaspon,
yumaikas's Avatar

yumaikas / Recursive Mira Pattern Match

0 likes
0 forks
1 files
Last active 1734816968
1 --[[
2 |
3 lightning struck [x] [y]
4 , [something] is at [x] [y]?
5 , [something] has inventory [inventory]?
6 , [inventory] has item [item]?
7 , [item] is [class]?
8 , [class] is conductive?
9 |
10 [something] is struck by lightning
capitalex's Avatar

capitalex / timers.nv

0 likes
0 forks
1 files
Last active 1734459742
1 |_| Stateful actions in the host system
2 |#port, on create new timer
3 , needs, @create new timer
4 , takes, @timer duration ms, @timer started, @timer once|
5 , @new timer id
6
7 |#port, on destroy timer
8 , needs, @destroy timer, takes, @timer id|
9
10 |#port, on tick timer
yumaikas's Avatar

yumaikas / html_calc.nv

0 likes
0 forks
5 files
Last active 1734365264
1 | # meta code status | Untested, uncompiled
2 | #include, strings.nv, slots.nv, DOM.nv |
3
4 | #strings, br, app, button, calc-output, div,
5 AC, All Clear, C, Clear,
6 0,9,8,7,6,5,4,3,2,1,
7 +,/,*,-,.,=,
8 ,Press 7, Press 8, Press 9, Press Divide
9 ,Press 4, Press 5, Press 6, Press Multiply
10 ,Press 1, Press 2, Press 3, Press Subtract
capitalex's Avatar

capitalex / linear-multiset-catlang.txt

0 likes
0 forks
3 files
Last active 1738998538
1
2 function run_rules(state)
3 if state["flour"] >= 1 and state["sugar"] >= 1 and state["apples"] >= 1 then
4 emit(state, "apple cake")
5 return run_rules(state)
6 elseif state["apples"] >= 1 and state["oranges"] >= 1 and state["cherries"] >= 1 then
7 emit(state, "fruit salad")
8 return run_rules(state)
9 elseif state["fruit salad"] >= 1 and state["apple cake"] >= 1 then
10 emit(state, "fruit cake")
capitalex's Avatar

capitalex / hello-lvera.lua

0 likes
0 forks
1 files
Last active 1734243656
1 local min, max, huge = math.min, math.max, math.huge
2 local machine = {state = {}}
3
4 machine.counters = {
5 ["run main loop"] = 1,
6 ["show message"] = 0,
7 ["@step timer"] = 0,
8 ["present current frame"] = 0,
9 ["sleep for 1ms"] = 0,
10 ["run current frame"] = 0,
capitalex's Avatar

capitalex / state.lua

0 likes
0 forks
4 files
Last active 1734158250
1 -- circle game --
2 machine.state = {
3 ["last_key_pressed"] = "",
4 ["event_args"] = {},
5 ["dt"] = 0,
6 ["default_font"] = love.graphics.getFont(),
7 ["circles"] = {},
8 ["large_font"] = love.graphics.newFont(64),
9 }
capitalex's Avatar

capitalex / movement.lua

0 likes
0 forks
1 files
Last active 1734124994
1 |#state, player|
2 {x = 400, y = 300, r = 10, health = 5}
3
4 |#port, on draw player, needs, @draw player|
5 |#port body, on draw player, Lua|
6 local player = self.state.player
7 love.graphics.circle("fill", player.x, player.y, player.r)
8
9 |#port, on move player, needs, @move player
10 , takes, @dir up, @dir down, @dir left, @dir right|
capitalex's Avatar

capitalex / main-loop.nv

0 likes
0 forks
1 files
Last active 1734110021
1 |_| Ports for reading and writing events
2 |#state|
3 { event_args = {}
4 , dt = 0
5 }
6
7 |#port, on start polling, needs, @start polling|
8 |#port body, on start polling, Lua|
9 love.event.pump()
10 self.state.event_iter = love.event.poll()
capitalex's Avatar

capitalex / tabulacrum_test.gd

0 likes
0 forks
1 files
Last active 1734057676
1 extends Node2D
2 var world = Tabulacrum.new()
3
4 @onready var window_title = get_window().title
5 func _ready() -> void:
6 for _i in range(1000):
7 world.conjure_entity() \
8 .it_is_a(["circle"]) \
9 .give_it(
10 { position = Vector2(randi_range(100, 500), randi_range(100, 500))
Newer Older

Powered by Opengist ⋅ Load: 216ms⋅

English
Čeština Deutsch English Español Français Magyar Italiano 日本語 Polski Português Русский Türkçe Українська 中文 繁體中文