tModLoader v2023.01
A mod to make and play Terraria mods
Terraria.Recipe.ConsumptionRules Class Reference

Static Public Attributes

static ConsumeItemCallback Alchemy
 Gives 1/3 chance for every ingredient to not be consumed, if used at an alchemy table. (!) This behavior is already automatically given to all items that can be made at a placed bottle tile. More...
 

Member Data Documentation

◆ Alchemy

ConsumeItemCallback Terraria.Recipe.ConsumptionRules.Alchemy
static
Initial value:
= (Recipe recipe, int type, ref int amount) => {
if (!Main.LocalPlayer.alchemyTable) return;
int amountUsed = 0;
for (int i = 0; i < amount; i++) {
if (!Main.rand.NextBool(3))
amountUsed++;
}
amount = amountUsed;
}

Gives 1/3 chance for every ingredient to not be consumed, if used at an alchemy table. (!) This behavior is already automatically given to all items that can be made at a placed bottle tile.