Raise your hand if you thought pumpkins should be used as food.

This Article is up to date with Custom Stuff 2 CS2

Food is a type of item available in Minecraft. As the name would imply, food is eaten to replenish Hunger, which is in turn used to regenerate health. With Custom Stuff, you can input your favorite foods into Minecraft, giving you more variety in the sustenance available to you.

Adding new food to the game is mostly a matter of aesthetics, although you can create foods that are either easier or harder to obtain than the defaults making them effectively functional or interesting. Even if you just want to make foods that you like there are many, many item IDs available for use so adding a lot of fun items like food just to flesh out the feeling of your minecraft worlds to your own personal tastes (no pun intended) can hardly be considered wasteful.

In Custom Stuff 2, Food is an otherwise ordinary item that has properties such as alwaysEdible set to true. Typically the "hunger" and "saturation" attributes are also set to 1 or more, though this isn't necessary is you're using the food for a seperate function such as a potion effect. In these cases, the alwaysEdible attribute is set to true; something that is not the case for a normal food item like bread.

Food Example (CS2 0.10.2 and above)


config.addItemIdProperty("appleSauceID", 5011);
mod.addAlias(260, "apple");
mod.addAlias(281, "bowl");
mod.addAlias(config.getItemId("appleSauceID"), "appleSauce");
mod.addItem("appleSauce.js", "food");
mod.addRecipe("appleSauce 1", 1, 2, "apple", "bowl");


id = config.getItemId("appleSauceID");
name = "appleSauce";

maxStack = 16;
full3d = false;
creativeTab = "food";

displayName[0] = "Apple Sauce";
textureFile[0] = "appleSauce.png";
addToCreative[0] = true;
alwaysEdible[0] = false;
hunger[0] = 3;
saturation[0] = 2;
onEaten[0] = "player.add(281, 1, 0);"; //returns a bowl

Potion Example (CS2 0.10.2 and above)


mod.addItem("drink.js", "food");


id = config.getItemId("instaColaID");
name = "InstaCola";
displayName[0] = "InstaCola";

textureFile[0] = "instaCola.png";
maxStack = 10;
full3d = false;
addToCreative[0] = true;
creativeTab = "food";

alwaysEdible[0] = true;
potion[0] = "regeneration";
potionDuration[0] = 60;
potionAmplifier[0] = 255;
potionProbability[0] = 1.0;
usingAction[0] = "drink";

leaveContainerItem = true;
containerItem = config.getItemId("emptyCanID") + " 1";
onEaten[0] = "player.addPotionEffect('moveSpeed',1800,5);\
    player.add(config.getItemId('emptyCanID'), 1, 0);";

Food Item Attributes

Required Attributes

Optional Attributes

textureFile and textureIndex
In CS2 versions for 1.4.7 and below, CS2 0.9.9 or below, textureFile was used to specify the texture sheet and textureIndex was used for identifying the specific icon within the texture sheet. If using CS2 0.9.9 or lower, make sure to use both of these attributes.

Older Examples and Information for Custom Stuff 1.

Example Food Item

name="Pumpkin Cookie";
saturation=0.3; //How 'filling' the food item is.
healamount=2;   //How many units of food is healed. 1 = 1/2 'drumstick'.

Food Item Attributes

Below is a table of attributes available to food-type items, including information on notable attributes.

Required Attributes

Optional Attributes

This must be set to 'food' for the item to be edible by the player.

This is an integer value. Each point heals half a 'drumstick' on the hunger bar. You can set this value as high as you like.

The saturation of the food represents how 'filling' the item is. Valid values for saturation are decimal numbers (0.1, 0.2, etc.) greater than zero. The higher the value the longer it takes to get hungry.

CS 1 Bugs


Why, that watermelon is as big as my pickaxe!


Why does my cookie taste like "11"?

  • In the current version (2.3.4) the particles that come from a food item when eaten are drawn from /gui/items.png regardless of which iconfile is chosen. The iconindex will determine which sprite is used, however. This may be a bug in Forge, and not a problem with Custom Stuff, as evidenced by how other Forge mods also seem to exhibit this problem.
  • When in third person view, food items will seem to be very large because the game renders them with the same size and orientation of tools. This bug is still present in CS 2.3.4.
Community content is available under CC-BY-SA unless otherwise noted.