From bebbe65f7dfe276521fec438b70d77800bf98d18 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Sun, 14 Jul 2024 18:05:55 +0200 Subject: add mochi recipe --- data/recipes/default.ts | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) (limited to 'data/recipes') diff --git a/data/recipes/default.ts b/data/recipes/default.ts index e95d4d04..662b6817 100644 --- a/data/recipes/default.ts +++ b/data/recipes/default.ts @@ -16,7 +16,7 @@ */ -//? Is is a good idea? Probably not. +//? Is this a good idea? Probably not. export interface Recipe { tile?: string, @@ -97,16 +97,16 @@ function cut(s: Item, two?: boolean): Item { out({ action: "active", inputs: [s], outputs: [o, two ? o : null], tile: "cuttingboard", duration: 2 }) return o } -function cook(s: Item): Item { +function cook(s: Item, duration = 20): Item { const o = new Item(`cooked-${s.name}`, s.container) - out({ action: "passive", duration: 25, tile: "stove", inputs: [s], outputs: [o] }) - out({ action: "passive", duration: 15, revert_duration: 20, tile: "stove", inputs: [o], outputs: [new Item("burned", POT)], warn: true }) + out({ action: "passive", duration, tile: "stove", inputs: [s], outputs: [o] }) + out({ action: "passive", duration: duration / 3, revert_duration: 20, tile: "stove", inputs: [o], outputs: [new Item("burned", POT)], warn: true }) return o } -function bake(s: Item): Item { +function bake(s: Item, duration = 25): Item { const o = new Item(`sliced-${s.name}`, s.container) - out({ action: "passive", duration: 25, tile: "oven", inputs: [s], outputs: [o] }) - out({ action: "passive", duration: 15, revert_duration: 20, tile: "oven", inputs: [o], outputs: [new Item("burned")], warn: true }) + out({ action: "passive", duration, tile: "oven", inputs: [s], outputs: [o] }) + out({ action: "passive", duration: duration / 2, revert_duration: 20, tile: "oven", inputs: [o], outputs: [new Item("burned")], warn: true }) return o } function freeze(s: Item): Item { @@ -207,15 +207,21 @@ edible(nigiri) const strawberry_puree = process(strawberry.tr(FP)).as("strawberry-puree") const milk = process(coconut.tr(FP)).as("milk") const strawberry_shake = either( - process(container_add(milk, strawberry).as("coconut-strawberry-puree-milk")).as("strawberry-shake"), + process(container_add(milk, strawberry).as("coconut-strawberry-puree")).as("strawberry-shake"), process(container_add(strawberry_puree, coconut).as("milk-strawberry")).as("strawberry-shake") ) -// icecream +// Icecream const strawberry_icecream = freeze(strawberry_shake).as("strawberry-icecream").tr(PL) edible(strawberry_icecream) -// drinks +// Mochi +const rice_flour = process(rice.tr(FP)).as("rice-flour") +const mochi_dough = cook(rice_flour.tr(POT), 5).as("mochi-dough") +const strawberry_mochi = container_add(strawberry, mochi_dough).as("strawberry-mochi") +edible(strawberry_mochi) + +// Drinks edible( strawberry_shake.tr(GL), sink_fill(GL) -- cgit v1.2.3-70-g09d2