Search in sources :

Example 1 with BigIntEnergyStack

use of com.cjm721.overloaded.storage.stacks.bigint.BigIntEnergyStack in project Overloaded by CJ-MC-Mods.

the class BlockTrueInfiniteCapacitor method sendPlayerStatus.

@Override
protected void sendPlayerStatus(World world, BlockPos pos, PlayerEntity player) {
    BigIntEnergyStack stack = ((TileTrueInfiniteCapacitor) world.getBlockEntity(pos)).getStorage().bigStatus();
    player.displayClientMessage(new StringTextComponent(String.format("Energy Amount: %,d Bits: %,d", stack.getAmount(), stack.getAmount().bitLength())), false);
}
Also used : StringTextComponent(net.minecraft.util.text.StringTextComponent) BigIntEnergyStack(com.cjm721.overloaded.storage.stacks.bigint.BigIntEnergyStack)

Aggregations

BigIntEnergyStack (com.cjm721.overloaded.storage.stacks.bigint.BigIntEnergyStack)1 StringTextComponent (net.minecraft.util.text.StringTextComponent)1