-
Posts
1160 -
Joined
-
Days Won
7
Everything posted by poopoodice
-
[1.15.2] ItemStack NBT not transferred to Block's TileEntity
poopoodice replied to Spyeedy's topic in Modder Support
I wonder if write() is getting called? because you've override @Override public CompoundNBT serializeNBT() { CompoundNBT nbt = new CompoundNBT(); System.out.println("serialize"); return nbt; } @Override public void deserializeNBT(CompoundNBT nbt) { System.out.println("deserialize"); } and before that serializeNBT calles write(), and desrializeNBT calls read(). Not sure if it's related tho -
[Solved] Custom Bow Pullback Animation Only Loading One Frame
poopoodice replied to fracturx's topic in Modder Support
you misunderstood what I mean. if (entity.getActiveItemStack().getItem() instanceof BaseBow) { return 0F; } else { return (float)(stack.getUseDuration() - entity.getItemInUseCount()) / 20F; } } change the 0F to 1F does not matter because what are you trying to do is to change the bow's model correspond to the bow's pulling duration (time pulled), which you've done that in the else statement. But the else statement is never going to be reached because the item you are holding is an instance of the custom bow class so it will always return the value in the if statement -
[Solved] Custom Bow Pullback Animation Only Loading One Frame
poopoodice replied to fracturx's topic in Modder Support
it does? what I mean is { "predicate": { "pulling": 1, "pull": 0.65 }, "model": "otherutilities:item/diamond_bow_pulling_1" }, { "predicate": { "pulling": 1, "pull": 0.9 }, "model": "otherutilities:item/diamond_bow_pulling_2" } ] pull is always 0 which < 0.65 and 0.9 -
[Solved] Custom Bow Pullback Animation Only Loading One Frame
poopoodice replied to fracturx's topic in Modder Support
well.. if the item is your custom bow it will always return 0.... -
[Solved] Custom Bow Pullback Animation Only Loading One Frame
poopoodice replied to fracturx's topic in Modder Support
Yep, you should add 0 since iirc it will fit the criteria when the value given is larger or equal to the predicate value. Anyways, I remember that forge doc has a explanation on this and you might want to have a look at it. -
[Solved] Custom Bow Pullback Animation Only Loading One Frame
poopoodice replied to fracturx's topic in Modder Support
I think you will need to specify the pull value in the first predicate even if it's 0 -
the item models needs to be under models/item and you have them in wood which I dont think they will work unless you specify their position
-
I added them via vanilla command, I'm also pretty sure that they are in the same team because when using /team list it shows both of them
-
Hi, I wonder if there's a way to get player's team on client? I don't know if I've done something wrong but although the players are in the same team, whenever I call entity.getTeam the teams they are in are always different (which entity.isOnSameTeam() returns false). Thanks for any help or tips.
-
get command dispatcher using getCommandDispatcher()
-
"rolls": 1, you also need a name https://mcforge.readthedocs.io/en/1.13.x/items/loot_tables/#overview
-
https://minecraft-el.gamepedia.com/Loot_table
-
that's not enough, you need to actually implement the blockstate you can declare what the default state is by putting this in ur constructor. setDefaultState(getDefaultState() .with(HORIZONTAL_FACING, Direction.NORTH) and override this so it knows that you have the facing as one of your blockstate @Override protected void fillStateContainer(StateContainer.Builder<Block, BlockState> builder) { builder.add(HORIZONTAL_FACING); } and by overriding this @Override public BlockState getStateForPlacement(BlockItemUseContext context) { return this.getDefaultState() .with(HORIZONTAL_FACING, context.getPlacementHorizontalFacing()); } when placed this gets called, and return the state that has the facing corresponds to the player's horizontal facing.
-
world.addParticle