Dang it, now it's right

This commit is contained in:
Ellpeck 2016-05-10 19:00:35 +02:00
parent 1c9038d703
commit a7a76cc861

View file

@ -42,7 +42,8 @@ public class TileEntitySmileyCloud extends TileEntityBase implements IStringReac
public void updateEntity(){
super.updateEntity();
if(!this.worldObj.isRemote){
if(((this.nameBefore == null && this.name != null) || !this.nameBefore.equals(this.name)) && this.sendUpdateWithInterval()){
boolean nameChanged = this.name != null ? !this.name.equals(this.nameBefore) : this.nameBefore != null;
if(nameChanged && this.sendUpdateWithInterval()){
this.nameBefore = this.name;
this.markDirty();
}