A whole lot of formatting cleanup
Also changes NBTHolder to a standard Constants class with subclasses for each category
This commit is contained in:
parent
f9802900db
commit
34dee6447b
74 changed files with 861 additions and 662 deletions
|
@ -1,14 +1,15 @@
|
|||
package WayofTime.bloodmagic.api.util.helper;
|
||||
|
||||
import WayofTime.bloodmagic.api.NBTHolder;
|
||||
import WayofTime.bloodmagic.api.Constants;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
||||
public class IncenseHelper {
|
||||
|
||||
public static float getCurrentIncense(EntityPlayer player) {
|
||||
NBTTagCompound data = player.getEntityData();
|
||||
if (data.hasKey(NBTHolder.NBT_CURRENT_INCENSE)) {
|
||||
return data.getFloat(NBTHolder.NBT_CURRENT_INCENSE);
|
||||
if (data.hasKey(Constants.NBT.CURRENT_INCENSE)) {
|
||||
return data.getFloat(Constants.NBT.CURRENT_INCENSE);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
@ -16,6 +17,6 @@ public class IncenseHelper {
|
|||
|
||||
public static void setCurrentIncense(EntityPlayer player, float amount) {
|
||||
NBTTagCompound data = player.getEntityData();
|
||||
data.setFloat(NBTHolder.NBT_CURRENT_INCENSE, amount);
|
||||
data.setFloat(Constants.NBT.CURRENT_INCENSE, amount);
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue