Some additional fixes from other branch.

This commit is contained in:
Sebastian Hartte
2020-05-30 22:18:26 +02:00
parent 16d6d55d7f
commit ec3b464655
139 changed files with 1489 additions and 1485 deletions
@@ -344,7 +344,7 @@ public final class ContainerInterfaceTerminal extends AEBaseContainer
}
}
data.setBoolean( "clear", true );
data.putBoolean("clear", true);
for( final Entry<IInterfaceHost, InvTracker> en : this.diList.entrySet() )
{
@@ -376,8 +376,8 @@ public final class ContainerInterfaceTerminal extends AEBaseContainer
if( tag.hasNoTags() )
{
tag.setLong( "sortBy", inv.sortBy );
tag.setString( "un", inv.unlocalizedName );
tag.putLong( "sortBy", inv.sortBy );
tag.putString("un", inv.unlocalizedName);
}
for( int x = 0; x < length; x++ )
@@ -391,7 +391,7 @@ public final class ContainerInterfaceTerminal extends AEBaseContainer
if( !is.isEmpty() )
{
is.writeToNBT( itemNBT );
is.write(itemNBT);
}
tag.setTag( Integer.toString( x + offset ), itemNBT );
@@ -27,7 +27,6 @@ import appeng.api.implementations.guiobjects.INetworkTool;
import appeng.container.AEBaseContainer;
import appeng.container.guisync.GuiSync;
import appeng.container.slot.SlotRestrictedInput;
import appeng.util.Platform;
public class ContainerNetworkTool extends AEBaseContainer
@@ -59,8 +58,8 @@ public class ContainerNetworkTool extends AEBaseContainer
public void toggleFacadeMode()
{
final CompoundNBT data = Platform.openNbtData( this.toolInv.getItemStack() );
data.setBoolean( "hideFacades", !data.getBoolean( "hideFacades" ) );
final CompoundNBT data = this.toolInv.getItemStack().getOrCreateTag();
data.putBoolean("hideFacades", !data.getBoolean( "hideFacades" ));
this.detectAndSendChanges();
}
@@ -90,7 +89,7 @@ public class ContainerNetworkTool extends AEBaseContainer
if( this.isValidContainer() )
{
final CompoundNBT data = Platform.openNbtData( currentItem );
final CompoundNBT data = currentItem.getOrCreateTag();
this.setFacadeMode( data.getBoolean( "hideFacades" ) );
}
@@ -263,8 +263,8 @@ public class ContainerPatternTerm extends ContainerMEMonitorable implements IAEA
encodedValue.setTag( "in", tagIn );
encodedValue.setTag( "out", tagOut );
encodedValue.setBoolean( "crafting", this.isCraftingMode() );
encodedValue.setBoolean( "substitute", this.isSubstitute() );
encodedValue.putBoolean("crafting", this.isCraftingMode());
encodedValue.putBoolean("substitute", this.isSubstitute());
output.setTagCompound( encodedValue );
}
@@ -348,7 +348,7 @@ public class ContainerPatternTerm extends ContainerMEMonitorable implements IAEA
if( !i.isEmpty() )
{
i.writeToNBT( c );
i.write(c);
}
return c;
@@ -123,8 +123,8 @@ public class ContainerQuartzKnife extends AEBaseContainer
{
return AEApi.instance().definitions().materials().namePress().maybeStack( 1 ).map( namePressStack ->
{
final CompoundNBT compound = Platform.openNbtData( namePressStack );
compound.setString( "InscribeName", ContainerQuartzKnife.this.myName );
final CompoundNBT compound = namePressStack.getOrCreateTag();
compound.putString("InscribeName", ContainerQuartzKnife.this.myName);
return namePressStack;
} ).orElse( ItemStack.EMPTY );