Should fix #186
This commit is contained in:
parent
90f0b0ae5b
commit
13383bd2a9
1 changed files with 3 additions and 3 deletions
|
@ -15,7 +15,7 @@ public class TileIDSU extends TilePowerAcceptor {
|
|||
|
||||
@Override
|
||||
public double getEnergy() {
|
||||
if(ownerUdid == null){
|
||||
if(ownerUdid == null && !this.ownerUdid.isEmpty()){
|
||||
return 0;
|
||||
}
|
||||
return IDSUManager.INSTANCE.getSaveDataForWorld(worldObj, ownerUdid).storedPower;
|
||||
|
@ -23,7 +23,7 @@ public class TileIDSU extends TilePowerAcceptor {
|
|||
|
||||
@Override
|
||||
public void setEnergy(double energy) {
|
||||
if(ownerUdid == null){
|
||||
if(ownerUdid == null && !this.ownerUdid.isEmpty()){
|
||||
return;
|
||||
}
|
||||
IDSUManager.INSTANCE.getSaveDataForWorld(worldObj, ownerUdid).storedPower = energy;
|
||||
|
@ -98,7 +98,7 @@ public class TileIDSU extends TilePowerAcceptor {
|
|||
|
||||
public void writeToNBT(NBTTagCompound nbttagcompound) {
|
||||
super.writeToNBT(nbttagcompound);
|
||||
if(this.ownerUdid == null){
|
||||
if(this.ownerUdid == null && !this.ownerUdid.isEmpty()){
|
||||
return;
|
||||
}
|
||||
nbttagcompound.setString("ownerUdid", this.ownerUdid);
|
||||
|
|
Loading…
Reference in a new issue