FoodProperties
Link to foodproperties
Импорт класса
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.FoodProperties;
Static Methods
Link to static-methods
Name: create
Return Type: FoodProperties
ZenScript CopyFoodProperties.create(nutrition as int, saturationModifier as float) as FoodProperties
Параметр | Тип | Описание |
---|---|---|
Параметр nutrition | Тип int | Описание No Description Provided |
Параметр saturationModifier | Тип float | Описание No Description Provided |
Методы
Link to методы
Name: addEffect
Return Type: FoodProperties
ZenScript CopyFoodProperties.addEffect(effect as MobEffectInstance, probability as float) as FoodProperties
Параметр | Тип | Описание |
---|---|---|
Параметр effect | Тип MobEffectInstance | Описание No Description Provided |
Параметр probability | Тип float | Описание No Description Provided |
Name: canAlwaysEat
Return Type: boolean
ZenScript Copy// FoodProperties.canAlwaysEat() as boolean
myFoodProperties.canAlwaysEat();
Name: getEffects
Return Type: stdlib.List<Pair<MobEffectInstance,float?>>
ZenScript Copy// FoodProperties.getEffects() as stdlib.List<Pair<MobEffectInstance,float?>>
myFoodProperties.getEffects();
Name: getNutrition
Return Type: int
ZenScript Copy// FoodProperties.getNutrition() as int
myFoodProperties.getNutrition();
Name: getSaturationModifier
Return Type: float
ZenScript Copy// FoodProperties.getSaturationModifier() as float
myFoodProperties.getSaturationModifier();
Name: isFastFood
Return Type: boolean
ZenScript Copy// FoodProperties.isFastFood() as boolean
myFoodProperties.isFastFood();
Name: isMeat
Return Type: boolean
ZenScript Copy// FoodProperties.isMeat() as boolean
myFoodProperties.isMeat();
Name: removeEffect
Return Type: FoodProperties
ZenScript CopyFoodProperties.removeEffect(effect as MobEffectInstance) as FoodProperties
Параметр | Тип | Описание |
---|---|---|
Параметр effect | Тип MobEffectInstance | Описание No Description Provided |
Name: setCanAlwaysEat
Return Type: FoodProperties
ZenScript CopyFoodProperties.setCanAlwaysEat(canAlwaysEat as boolean) as FoodProperties
Параметр | Тип | Описание |
---|---|---|
Параметр canAlwaysEat | Тип boolean | Описание No Description Provided |
Name: setIsFastFood
Return Type: FoodProperties
ZenScript CopyFoodProperties.setIsFastFood(fastFood as boolean) as FoodProperties
Параметр | Тип | Описание |
---|---|---|
Параметр fastFood | Тип boolean | Описание No Description Provided |
Name: setIsMeat
Return Type: FoodProperties
ZenScript CopyFoodProperties.setIsMeat(isMeat as boolean) as FoodProperties
Параметр | Тип | Описание |
---|---|---|
Параметр isMeat | Тип boolean | Описание No Description Provided |
Name: setNutrition
Return Type: FoodProperties
ZenScript CopyFoodProperties.setNutrition(nutrition as int) as FoodProperties
Параметр | Тип | Описание |
---|---|---|
Параметр nutrition | Тип int | Описание No Description Provided |
Name: setNutrition
Return Type: FoodProperties
ZenScript CopyFoodProperties.setNutrition(saturationModifier as float) as FoodProperties
Параметр | Тип | Описание |
---|---|---|
Параметр saturationModifier | Тип float | Описание No Description Provided |
Свойства
Link to свойства
Название | Тип | Имеет Getter | Имеет Setter | Описание |
---|---|---|---|---|
Название canAlwaysEat | Тип boolean | Имеет Getter true | Имеет Setter true | Описание No Description Provided |
Название effects | Тип stdlib.List<Pair<MobEffectInstance,float?>> | Имеет Getter true | Имеет Setter false | Описание No Description Provided |
Название isFastFood | Тип boolean | Имеет Getter true | Имеет Setter true | Описание No Description Provided |
Название isMeat | Тип boolean | Имеет Getter true | Имеет Setter true | Описание No Description Provided |
Название nutrition | Тип int | Имеет Getter true | Имеет Setter true | Описание No Description Provided |
Название saturationModifier | Тип float | Имеет Getter true | Имеет Setter true | Описание No Description Provided |