GenRecipe

From CoffeeMud Wiki
Revision as of 00:27, 25 February 2021 by Loki (talk | contribs) (→‎Recipe Data)
Jump to navigation Jump to search
CoffeeMUD
Administrator                                                  Builder                                                              Player
=CoffeeMUD Builder Information=
Basics Praetor     Player Support     Commands     Zapper Masks Advanced Races     Classes     Abilities     Socials     Scripting    
Building Behaviors     Properties     Areas     Rooms     Exits     Items     Mobs Systems Achievements     Crafting     Help Info     Ships     Planes of Existence     Quests     Triumphs    

A GenRecipe is a sub-type of GenReadable that contains one or more custom recipes from a single crafting skill. Players who have a GenRecipe in their immediately accessible inventory (inventory, or a container with accessible contents flag) will be able to craft items from this GenRecipe if they meet the level requirements. The recipes will appear on their skill's LIST command, and will be subject to their skill's INFO command, as if the recipe was part of the skill. Dropping the recipe, or putting it in a non-accessible container, will result in all recipes from the GenRecipe no longer appearing on the skill's LIST.

Creating a GenRecipe

GenRecipes can be created from the Command Line with the command CREATE GENRECIPE or from the MUDGrinder in a room or mob's inventory.

Recipe Data

This field contains the information unique to recipes.

  • Skill ID : This should be the crafting skill name that the GenRecipe will add new recipes to the owner
  • Maximum Recipe Count : A GenRecipe may hold 1 or more recipes. Be conservative with this value, as players will use any remaining slot to create their own recipe books from your GenRecipe.
  • Recipe data: From the command line, you may edit existing recipes or add a new one by selecting the appropriate number (1 for a new recipe on a blank GenRecipe, for example)
    • After selecting the recipe number, you must enter a valid comma-delimited recipe code. The number of fields varies by the crafting skill selected. If you select "?", it will return a string valid for that crafting skill.
    • Each field in the comma-delimited recipe code has a specific purpose, and some fields have multiple purposes depending on other fields. The fields with the or (||) operands are fields whose purpose is derived from another field, most likely the Item_Class_ID field.
:: For Example, at the time of this entry, the blacksmithing comma-delimited recipe code reads: 

ITEM_NAME,ITEM_LEVEL,BUILD_TIME_TICKS,MATERIALS_REQUIRED,ITEM_BASE_VALUE,ITEM_CLASS_ID,STATUE||RIDE_BASIS||CONTAINER_TYPE_OR_LIDLOCK||CODED_WEAR_LOCATION,CONTAINER_CAPACITY||LIQUID_CAPACITY||MAX_WAND_USES||LIGHT_DURATION||DICE_SIDES,CODED_SPELL_LIST

Breaking that up into individual fields:

ITEM_NAME,
ITEM_LEVEL,
BUILD_TIME_TICKS,
MATERIALS_REQUIRED,
ITEM_BASE_VALUE,
ITEM_CLASS_ID,
STATUE||RIDE_BASIS||CONTAINER_TYPE_OR_LIDLOCK||CODED_WEAR_LOCATION,
CONTAINER_CAPACITY||LIQUID_CAPACITY||MAX_WAND_USES||LIGHT_DURATION||DICE_SIDES,
CODED_SPELL_LIST

::
      • ITEM_NAME - This field should be the simple name of the item. Avoid adding color or other special text to item names, since this may confuse players on how to actually create the item. For example, "a ^rred^? hat" is a poor name for a hat since the ^r is parsed as the color red in the LIST command for the crafting ability, but is REQUIRED in commands to get INFO or craft the item.
      • ITEM_LEVEL - This is the base level of the item, before any material modifiers or expertises are applied.
      • BUILD_TIME_TICKS - This is the bse time in Ticks (~4 seconds) required to build the item. This is reduced by a number of factors, such as how many levels over the recipe level the crafter is, or certain expertises.

Balancing Recipes

Items should be balanced with your other items from your MUD. You may need to use Appendix C in the Archon's Guide, or your own scale. Recipes may be intentionally overbalanced due to scarcity, prop_itembinders or how to obtain them (GenShopkeepers requiring a special faction rating, a specific tattoo, etc).

Recipe Testing

It is highly recommended that you test your recipe to ensure it properly generates each item on the page. Some properties of the item may be ill-defined in the initial recipe code. You can use the CODED_SPELL_LIST to provide additional key field information (like damage=5).

Reverse Engineering

If you are having difficulties creating a genrecipe for a specific item, consider making the item by hand, copying the item, then creating a blank GenRecipe with the appropriate skill type of the item you want the recipe to make. Then SkillName LEARN ItemName to create a recipe (have spares of the item you are trying to build in case something goes wrong). Once you have "learned" the item, you can edit the GenRecipe and look at the resultant recipe code, and modify it to meet your needs.

Notes

.