Difference between revisions of "Talk:Guide to Food"

From Paradise Station Wiki
Jump to navigation Jump to search
(Created page with "= Editing Recipes in the Guide = In order to have recursive dropdowns of ingredients inside the text of other recipes, the Guide to Food uses special templates and formatting....")
 
m
 
(7 intermediate revisions by 2 users not shown)
Line 1: Line 1:
= Editing Recipes in the Guide =
= Editing Recipes in the Guide =
In order to have recursive dropdowns of ingredients inside the text of other recipes, the Guide to Food uses special templates and formatting.  
In order to have recursive dropdowns of ingredients inside the text of other recipes, the Guide to Food uses special templates and formatting.  
Essentially how this works, is that while the name of the food, its image, and any notes about the food are on the [[Guide to Food and Drinks]] page, the recipe itself is on a separate template page.
Essentially how this works, is that while the name of the food, its image, and any notes about the food are on the [[Guide to Food]] page, the recipe itself is on a separate template page.


There are two easy ways to find the template page. While the template pages don't show up normally in wiki search, if you start typing Template:RecursiveFood into the search box, the dropdown will change to a list of the different pages that begin with that. The other option is with the following link: '''[https://www.paradisestation.org/wiki/index.php/Special:PrefixIndex?prefix=RecursiveFood&namespace=10 This is a link to all of the RecursiveFood template pages], i.e. the pages you need to edit in order to make changes to the recipes in the guide.'''
There are two easy ways to find the template page. While the template pages don't show up normally in wiki search, if you start typing Template:RecursiveFood into the search box, the dropdown will change to a list of the different pages that begin with that. The other option is with the following link: '''[https://www.paradisestation.org/wiki/index.php/Special:PrefixIndex?prefix=RecursiveFood&namespace=10 This is a link to all of the RecursiveFood template pages], i.e. the pages you need to edit in order to make changes to the recipes in the guide.'''


== Editing Existing Recipes ==
== Editing Recipes ==
Say you want to edit the recipe for Pastry Dough. The actual recipe itself is found on the page [[Template:RecursiveFood/Pastry Dough]]. Once you find that page and click edit, you'll see the following:
Say you want to edit the recipe for Pastry Dough. The actual recipe itself is found on the page [[Template:RecursiveFood/Pastry Dough]]. Once you find that page and click edit, you'll see the following:
  <nowiki>
  <nowiki>
Line 19: Line 19:
  <nowiki>
  <nowiki>
{{Tooltip|[[#%%%|%%%]]|{{RecursiveFood/%%%}}}}</nowiki>
{{Tooltip|[[#%%%|%%%]]|{{RecursiveFood/%%%}}}}</nowiki>
What if the technical name of the ingredient doesn't match what you want to show? For example, if you want to link to Bun, but your recipe calls for two Bun''s''? You can modify the second instance of the ingredient's name inside the tooltip, as that's what is visible, while the first and third instance are for the actual linking and tooltip. So in our example, you'd write:
<nowiki>
2 {{Tooltip|[[#Bun|Buns]]|{{RecursiveFood/Bun}}}}</nowiki>
in order to show 2 {{Tooltip|[[#Bun|Buns]]|{{RecursiveFood/Bun}}}}
This especially helpful when you want to link to the Fruit and Vegetable Juices tooltip, but you want the text to show the specific juice required:
<nowiki>
{{Tooltip|[[#Fruit and Vegetable Juices|Berry Juice]]|{{RecursiveFood/Fruit and Vegetable Juices}}}}</nowiki>


== Adding New Recipes ==
== Adding New Recipes ==
Line 31: Line 41:
Replace the %%%s with the name of the food (such as Bun), and the *** with the filename of the image of the food that you've uploaded to the wiki (preferably in 64x64, png or gif format), such as bun.png
Replace the %%%s with the name of the food (such as Bun), and the *** with the filename of the image of the food that you've uploaded to the wiki (preferably in 64x64, png or gif format), such as bun.png


The first line creates the row of the table, giving it the right background, and then adds the food's name, and sets up the ability to link
The first line creates the row of the table, giving it the right background, and then adds the food's name, and sets up the ability to jump to the food via links. The second line adds in the image of the food. The third inserts the food's recipe from the template page for the recipe. The fourth is where you can type in notes or comments about the food. The fifth finishes the row of the table.
 
You then need to add the recipe itself. The easiest way is to save the page you were just editing, scrolling down to your new food listing, and clicking on the red link to Template:RecursiveFood/%%%. From there you can add in text and tooltips as above, and whatever you save will appear in the main Guide to Food and Drink page. Please be aware that it may take a few minutes for the main page to update when you're editing the Template page after its initial creation, so don't panic if it doesn't work right away!
 
As an example of how a completed recipe looks, here's the recipe for Amanita Pie:
 
<nowiki>
!style='background-color:#D0F0C0;'|{{anchor|Amanita Pie}}[[#Amanita Pie|Amanita Pie]]
|[[File:amapie.png]]
|{{RecursiveFood/Amanita Pie}}
| '''WARNING''' - poisonous!
|- </nowiki>
 
Which shows up as:
<!-- Additional text below is to create the table and make it align the same way the ones on the Guide do. They are not necessary if you're just adding to an already existing table. -->
{| class="wikitable sortable" style="width:100%; text-align:left; border: 3px solid #A7ED4D; cellspacing=0; cellpadding=2; background-color:white;"
!style='width:150px; background-color:#D0F0C0;'|{{anchor|Amanita Pie}}[[#Amanita Pie|Amanita Pie]]
|style='width:50px;'|[[File:amapie.png]]
|{{RecursiveFood/Amanita Pie}}
| '''WARNING''' - poisonous!
|-
|}
 
== Additional Notes and Tips ==
* Not everything needs a tooltip link, but if the steps to create or acquire it are complex or not obvious, it's probably worth adding it in.
* The recipes are sorted roughly how a menu would sort them, so that if someone wanted to make a thematic kitchen (a breakfast diner, or a meat-only restaurant, etc.) it will be easier to do so.
* The [[Guide to Chemistry]] uses the same recursive template system (Template:RecursiveChem/), so it is possible to tooltip link to a chemistry recipe, though the initial overhaul of this guide didn't do so in case doing so would confuse readers, and instead just linked the chemicals to the Guide to Chemistry as a whole.
* It's generally a good idea to add a warning if the recipe will kill, borg, or majorly poison someone. Stuff that causes lower levels of damage or drugs someone is more flexible.

Latest revision as of 14:28, 9 October 2023

Editing Recipes in the Guide

In order to have recursive dropdowns of ingredients inside the text of other recipes, the Guide to Food uses special templates and formatting. Essentially how this works, is that while the name of the food, its image, and any notes about the food are on the Guide to Food page, the recipe itself is on a separate template page.

There are two easy ways to find the template page. While the template pages don't show up normally in wiki search, if you start typing Template:RecursiveFood into the search box, the dropdown will change to a list of the different pages that begin with that. The other option is with the following link: This is a link to all of the RecursiveFood template pages, i.e. the pages you need to edit in order to make changes to the recipes in the guide.

Editing Recipes

Say you want to edit the recipe for Pastry Dough. The actual recipe itself is found on the page Template:RecursiveFood/Pastry Dough. Once you find that page and click edit, you'll see the following:

Combine 10u {{Tooltip|[[#Flour|Flour]]|{{RecursiveFood/Flour}}}}, 10u Milk, 5u {{Tooltip|[[#Sugar|Sugar]]|{{RecursiveFood/Sugar}}}} 

The Tooltip section is what allows for mouseover to work on the text, linking to the recipe for that ingredient.

For example:

Flour
Grind Wheat in the "all in one grinder"

On the Guide to Food and Drink page itself, this also links to the ingredient, so that clicking on the text instead of mousing over it will jump you to the ingredient in question.

If the recipe you're editing needs a new tooltip added, you can insert the following text, replacing the %%% with the name of the ingredient you're trying to link to (if you have any trouble with this, the ingredient's text specifically needs to be the text that comes after "RecursiveFood/" in the template page for that ingredient)

{{Tooltip|[[#%%%|%%%]]|{{RecursiveFood/%%%}}}}

What if the technical name of the ingredient doesn't match what you want to show? For example, if you want to link to Bun, but your recipe calls for two Buns? You can modify the second instance of the ingredient's name inside the tooltip, as that's what is visible, while the first and third instance are for the actual linking and tooltip. So in our example, you'd write:

2 {{Tooltip|[[#Bun|Buns]]|{{RecursiveFood/Bun}}}}

in order to show 2

Buns
Bake 1
Dough
Combine 15u
Flour
Grind Wheat in the "all in one grinder"
, 10u Water

This especially helpful when you want to link to the Fruit and Vegetable Juices tooltip, but you want the text to show the specific juice required:

{{Tooltip|[[#Fruit and Vegetable Juices|Berry Juice]]|{{RecursiveFood/Fruit and Vegetable Juices}}}}

Adding New Recipes

If you're adding a totally new recipe, begin by adding the following to the relevant section on the Guide to Food and Drinks page:

!style='background-color:#D0F0C0;'|{{anchor|%%%}}[[#%%%|%%%]]
|[[File:***]]
|{{RecursiveFood/%%%}}
|
|- 

Replace the %%%s with the name of the food (such as Bun), and the *** with the filename of the image of the food that you've uploaded to the wiki (preferably in 64x64, png or gif format), such as bun.png

The first line creates the row of the table, giving it the right background, and then adds the food's name, and sets up the ability to jump to the food via links. The second line adds in the image of the food. The third inserts the food's recipe from the template page for the recipe. The fourth is where you can type in notes or comments about the food. The fifth finishes the row of the table.

You then need to add the recipe itself. The easiest way is to save the page you were just editing, scrolling down to your new food listing, and clicking on the red link to Template:RecursiveFood/%%%. From there you can add in text and tooltips as above, and whatever you save will appear in the main Guide to Food and Drink page. Please be aware that it may take a few minutes for the main page to update when you're editing the Template page after its initial creation, so don't panic if it doesn't work right away!

As an example of how a completed recipe looks, here's the recipe for Amanita Pie:

!style='background-color:#D0F0C0;'|{{anchor|Amanita Pie}}[[#Amanita Pie|Amanita Pie]]
|[[File:amapie.png]]
|{{RecursiveFood/Amanita Pie}}
| '''WARNING''' - poisonous!
|- 

Which shows up as:

Amanita Pie Amapie.png Bake 1
Flat Dough
Use your rolling pin on one
Dough
Combine 15u
Flour
Grind Wheat in the "all in one grinder"
, 10u Water
, 1 Amanita
WARNING - poisonous!

Additional Notes and Tips

  • Not everything needs a tooltip link, but if the steps to create or acquire it are complex or not obvious, it's probably worth adding it in.
  • The recipes are sorted roughly how a menu would sort them, so that if someone wanted to make a thematic kitchen (a breakfast diner, or a meat-only restaurant, etc.) it will be easier to do so.
  • The Guide to Chemistry uses the same recursive template system (Template:RecursiveChem/), so it is possible to tooltip link to a chemistry recipe, though the initial overhaul of this guide didn't do so in case doing so would confuse readers, and instead just linked the chemicals to the Guide to Chemistry as a whole.
  • It's generally a good idea to add a warning if the recipe will kill, borg, or majorly poison someone. Stuff that causes lower levels of damage or drugs someone is more flexible.