this doesn't compile yet, but have something to peek at

This commit is contained in:
Nicholas Ignoffo 2017-08-14 20:53:42 -07:00
parent 973f1019a5
commit 5fcdd978d7
329 changed files with 3247 additions and 2953 deletions

View file

@ -4,7 +4,7 @@ import WayofTime.bloodmagic.api.util.helper.PlayerHelper;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
import net.minecraft.world.WorldSavedData;
import net.minecraft.world.storage.WorldSavedData;
import java.util.*;

View file

@ -5,7 +5,6 @@ import WayofTime.bloodmagic.api.event.AddToNetworkEvent;
import WayofTime.bloodmagic.api.event.SoulNetworkEvent;
import WayofTime.bloodmagic.api.util.helper.PlayerHelper;
import com.google.common.base.Strings;
import lombok.Getter;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.MobEffects;
import net.minecraft.nbt.NBTTagCompound;
@ -18,7 +17,6 @@ import net.minecraftforge.fml.common.eventhandler.Event;
import javax.annotation.Nullable;
import java.util.UUID;
@Getter
public class SoulNetwork implements INBTSerializable<NBTTagCompound>
{
private BMWorldSavedData parent;
@ -129,7 +127,7 @@ public class SoulNetwork implements INBTSerializable<NBTTagCompound>
if (!user.capabilities.isCreativeMode)
{
user.hurtResistantTime = 0;
user.attackEntityFrom(BloodMagicAPI.getDamageSource(), 1.0F);
user.attackEntityFrom(BloodMagicAPI.damageSource, 1.0F);
}
} else if (syphon >= 100)
@ -139,7 +137,7 @@ public class SoulNetwork implements INBTSerializable<NBTTagCompound>
for (int i = 0; i < ((syphon + 99) / 100); i++)
{
user.hurtResistantTime = 0;
user.attackEntityFrom(BloodMagicAPI.getDamageSource(), 1.0F);
user.attackEntityFrom(BloodMagicAPI.damageSource, 1.0F);
}
}
}
@ -151,7 +149,7 @@ public class SoulNetwork implements INBTSerializable<NBTTagCompound>
if (getParent() != null)
getParent().markDirty();
else
BloodMagicAPI.getLogger().error("A SoulNetwork was created, but a parent was not set to allow saving.");
BloodMagicAPI.logger.error("A SoulNetwork was created, but a parent was not set to allow saving.");
}
@Nullable
@ -184,6 +182,26 @@ public class SoulNetwork implements INBTSerializable<NBTTagCompound>
return this;
}
public BMWorldSavedData getParent() {
return parent;
}
public EntityPlayer getCachedPlayer() {
return cachedPlayer;
}
public UUID getPlayerId() {
return playerId;
}
public int getCurrentEssence() {
return currentEssence;
}
public int getOrbTier() {
return orbTier;
}
// INBTSerializable
@Override