类 FoodData
java.lang.Object
net.minecraft.world.food.FoodData
-
字段概要
字段修饰符和类型字段说明private float
private int
private float
private int
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明private void
add
(int p_335153_, float p_332105_) void
addAdditionalSaveData
(CompoundTag p_38720_) void
addExhaustion
(float p_38704_) void
eat
(int p_38708_, float p_38709_) void
eat
(FoodProperties p_345472_) int
float
boolean
void
readAdditionalSaveData
(CompoundTag p_38716_) void
setFoodLevel
(int p_38706_) void
setSaturation
(float p_38718_) void
tick
(ServerPlayer p_369401_)
-
字段详细资料
-
foodLevel
private int foodLevel -
saturationLevel
private float saturationLevel -
exhaustionLevel
private float exhaustionLevel -
tickTimer
private int tickTimer
-
-
构造器详细资料
-
FoodData
public FoodData()
-
-
方法详细资料
-
add
private void add(int p_335153_, float p_332105_) -
eat
public void eat(int p_38708_, float p_38709_) -
eat
-
tick
-
readAdditionalSaveData
-
addAdditionalSaveData
-
getFoodLevel
public int getFoodLevel() -
needsFood
public boolean needsFood() -
addExhaustion
public void addExhaustion(float p_38704_) -
getSaturationLevel
public float getSaturationLevel() -
setFoodLevel
public void setFoodLevel(int p_38706_) -
setSaturation
public void setSaturation(float p_38718_)
-