Cooking Idea

YiKwang
23 Feb 2022, 09:27I have some notes here for a cooking idea where you can discover recipes by combining 2 ingredients correctly, and then cook those recipes from memory later, i have rough notes with fake script and messy notations, any ideas or notes on any part of it would be appreciated:
COOKING IDEAS
---
CHOOSE OVEN OPTION EXPERIMENT:
Choose ingredient A and B
Move ingredients into invisible container GRUBMIX
If (contains, (game.GRUBMIX, object HASATTRIBUTE "ISaFISH")
then
- If (contains, (game.GRUBMIX, object HasAttribute "ISaTUBER")
- then
- - msg "You have cooked up some Fish 'n' Chips!"
- - [setvariable] Learned_Fish_n_Chips = true
- - [remove and destroy GRUBMIX contents]
- - [give the fish n chips item]
---
CHOOSE OVEN OPTION COOK FROM MEMORY:
ShowMenu
Menu Options dependant on whether game progress item (i use the STARTROOM room where players choose a charcter)
IE
If (StartROOM.Learned_Fish_n_Chips = true)
then
- [add Split option "Fish 'n' Chips" to the Cook from Memory Menu]
mrangel
23 Feb 2022, 10:02I shared a system something like this quite a while ago.
I think a crafting system is quite a good thing to make, to really get your head around the engine. And it looks like you know how to go about it :)
For my one, I gave all the craftable items a recipe
attribute, and looped over them comparing each recipe to the contents of the pot rather than using individual if statements for each recipe; but that made the code quite complex; so it might be better to work with a simple solution.