public class BuffEffect
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
int |
duration
The duration of the effect in ticks.
|
int |
power
The strength of this effect.
|
| Constructor and Description |
|---|
BuffEffect(Buff buff,
int duration,
int power)
Constructs a new BuffEffect.
|
| Modifier and Type | Method and Description |
|---|---|
Buff |
getBuff()
Provides the buff used in this BuffEffect.
|
java.lang.String |
getDuration()
Retrieves the duration as a string.
|
static BuffEffect |
readFromNBT(net.minecraft.nbt.NBTTagCompound nbt)
Reads a BuffEffect from an NBTTagCompound.
|
java.lang.String |
toString() |
void |
writeToNBT(net.minecraft.nbt.NBTTagCompound nbt)
Writes this BuffEffect to an NBTTagCompound so that it can be saved.
|
public int duration
public int power
public BuffEffect(Buff buff, int duration, int power)
buff: - The buff to create the effect for.duration: - The duration of the effect.power: - The strength of the effect.public void writeToNBT(net.minecraft.nbt.NBTTagCompound nbt)
nbt: - The NBTTagCompound to write to.public static BuffEffect readFromNBT(net.minecraft.nbt.NBTTagCompound nbt)
nbt: - The NBTTagCompound to read from.public Buff getBuff()
public java.lang.String getDuration()
public java.lang.String toString()
toString in class java.lang.Object