FoodData
Link to fooddata
Импорт класса
Link to импорт-класса
It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.
ZenScript Copyimport crafttweaker.api.food.FoodData;
Методы
Link to методы
Name: addExhaustion
Return Type: void
ZenScript CopyFoodData.addExhaustion(exhaustion as float) as void
Параметр | Тип | Описание |
---|---|---|
Параметр exhaustion | Тип float | Описание No Description Provided |
Name: eat
Return Type: void
ZenScript CopyFoodData.eat(stack as IItemStack) as void
Параметр | Тип | Описание |
---|---|---|
Параметр stack | Тип IItemStack | Описание No Description Provided |
Name: eat
Return Type: void
ZenScript CopyFoodData.eat(foodLevelModifier as int, saturationLevelModifier as float) as void
Параметр | Тип | Описание |
---|---|---|
Параметр foodLevelModifier | Тип int | Описание No Description Provided |
Параметр saturationLevelModifier | Тип float | Описание No Description Provided |
Name: getExhaustionLevel
Return Type: float
ZenScript Copy// FoodData.getExhaustionLevel() as float
myFoodData.getExhaustionLevel();
Name: getFoodLevel
Return Type: int
ZenScript Copy// FoodData.getFoodLevel() as int
myFoodData.getFoodLevel();
Name: getLastFoodLevel
Return Type: int
ZenScript Copy// FoodData.getLastFoodLevel() as int
myFoodData.getLastFoodLevel();
Name: getSaturationLevel
Return Type: float
ZenScript Copy// FoodData.getSaturationLevel() as float
myFoodData.getSaturationLevel();
Name: needsFood
Return Type: boolean
ZenScript Copy// FoodData.needsFood() as boolean
myFoodData.needsFood();
Name: setExhaustion
Return Type: void
ZenScript CopyFoodData.setExhaustion(exhaustionLevel as float) as void
Параметр | Тип | Описание |
---|---|---|
Параметр exhaustionLevel | Тип float | Описание No Description Provided |
Name: setFoodLevel
Return Type: void
ZenScript CopyFoodData.setFoodLevel(foodLevel as int) as void
Параметр | Тип | Описание |
---|---|---|
Параметр foodLevel | Тип int | Описание No Description Provided |
Name: setSaturation
Return Type: void
ZenScript CopyFoodData.setSaturation(saturationLevel as float) as void
Параметр | Тип | Описание |
---|---|---|
Параметр saturationLevel | Тип float | Описание No Description Provided |