add_eat_effect |
Discworld food help |
add_eat_effect |
Name
add_eat_effect - Adds an eat effect.
Syntax
void add_eat_effect(string effect, int number);
Description
Adds an eat effect to the food. This will be executed when the food is eaten.
The effect is added with a number as the argument. The number is based on the amount which is eaten multiplied by the number passed into the add_eat_effect_func, multiplied by the first element of the query_weight_unit and then divided by the section element of the query_weight_unit.
ie:
eff_num = (amount * number * weight_unit[0]) / weight_unit[1]
Where number is the the number passed into the add_eat_effect function.
See also
query_eat_effects, set_eat_effects, query_weight_unit, set_weight_unit, remove_eat_effect