Skip to content

Conversation

@Arcaratus
Copy link
Contributor

@Arcaratus Arcaratus commented Mar 11, 2018

Also nuked BlockStack and ItemStackWrapper usage in the tools.

New textures are needed for the bound tools. (textures not included except for the pick)

Did I do it right this time? :D

Also nuked BlockStack and ItemStackWrapper usage in the tools
for (ItemStack stacks : itemDrops)
drops.add(ItemStackWrapper.getHolder(stacks));
NonNullList<ItemStack> itemDrops = NonNullList.create();
blockState.getBlock().getDrops(itemDrops, world, blockPos, world.getBlockState(blockPos), fortuneLvl);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why query the world again? Use the state you already have.

for (ItemStack stacks : itemDrops)
drops.add(ItemStackWrapper.getHolder(stacks));
NonNullList<ItemStack> itemDrops = NonNullList.create();
blockState.getBlock().getDrops(itemDrops, world, blockPos, world.getBlockState(blockPos), fortuneLvl);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here.


public class ItemBoundTool extends ItemTool implements IBindable, IActivatable {
public final int chargeTime = 30;
public final int MAX_CHARGE_TIME = 30;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

static

setCreativeTab(BloodMagic.TAB_BM);
setHarvestLevel(name, 4);

addPropertyOverride(new ResourceLocation("bloodmagic", "activated"), new IItemPropertyGetter()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BloodMagic.MODID

}
});

addPropertyOverride(new ResourceLocation("bloodmagic", "charge"), new IItemPropertyGetter()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BloodMagic.MODID


while (count >= maxStackSize) {
world.spawnEntity(new EntityItem(world, posToDrop.getX(), posToDrop.getY(), posToDrop.getZ(), stack.toStack(maxStackSize)));
ItemStack s = stack.copy();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ItemStack s = ItemHandlerHelper.copyStackWithSize(stack, maxStackSize);

if (count > 0)
world.spawnEntity(new EntityItem(world, posToDrop.getX(), posToDrop.getY(), posToDrop.getZ(), stack.toStack(count)));
if (count > 0) {
ItemStack s = stack.copy();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here.

@TehNut
Copy link
Collaborator

TehNut commented Mar 15, 2018

Going to wait until I or somebody else has time to create the rest of the textures needed. Don't know when we're building a new release, and I'd rather not ship anything without those.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants