Jump to content

viveleroi

Members
  • Posts

    18
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

viveleroi's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. I have a custom 1.16.5 modpack with 150 mods. I see a red X for a multiplayer server and the reason is because the list was truncated: [ne.mi.fm.ne.FMLStatusPing/]: Heuristically truncating mod and/or network channel list in server status ping packet. Compatibility report in the multiplayer screen may be inaccurate Yet this doesn't happen for packs twice as large like ATM6 with 250+ mods. Is there something I can be doing?
  2. I installed eclipse 2021-03 and downloaded the forge-1.16.5-36.1.16-mdk. When running the genEclipseRun inside eclipse, and running it directly in the folder via command line, I always get the following error. https://pastebin.com/BFcu7gqi I can't progress and don't understand what it's telling me or what's causing the error. I haven't changed any files. EDIT: Apparently it's because it's Java 11. I need to use Java 8.
  3. I'm trying to add a block with a little transparency - (10% reduction of the texture's alpha). The "isOpaqueCube" and "isTranslucent" methods are deprecated, but I can't find what they're supposed to be replaced by. @Override public boolean isOpaqueCube(IBlockState state) { return false; } @Override public boolean isTranslucent(IBlockState state) { return true; } @Override public BlockRenderLayer getBlockLayer() { return BlockRenderLayer.TRANSLUCENT; } These deprecated methods "work" (the blocks behind mine render correctly now), except I have a new issue where the faces between two of these blocks double up and create ugly faces. Advice on both problems appreciated.
  4. Taking out the check for world.isRemote doesn't solve this either. The code runs twice, both on the logical client and server but the grass/flowers grown don't appear except for the single block clicked. I'll have to study the original further, something is missing or I'm doing it wrong. Even just simplifying it, using the other recommended method, etc. @Override public EnumActionResult onItemUse(EntityPlayer player, World worldIn, BlockPos pos, EnumHand hand, EnumFacing facing, float hitX, float hitY, float hitZ) { ItemDye.applyBonemeal(player.getHeldItem(hand), worldIn, pos, player, hand); return EnumActionResult.PASS; }
  5. I thought that any world changes had to be made server-side and it would then update the client. The docs say "Applying game logic to the logical client can cause desynchronization issues" and running logic like this on both sides in another project lead to "doubling" of the all the logic which I was then directed to run on the logical server only. The docs aren't clearly explaining why some things need to happen when the world isRemote. Clearly one block is sent to the client, but not the others? If I run this on the logical client too, how does the growth produce the same results?
  6. I've designed a custom bonemeal item, which onItemUse calls "applyBonemeal": @Override public EnumActionResult onItemUse(EntityPlayer player, World worldIn, BlockPos pos, EnumHand hand, EnumFacing facing, float hitX, float hitY, float hitZ) { // Run only on logical server if (worldIn.isRemote) { return EnumActionResult.PASS; } // Copy the item so we give garbage to applyBonemeal - it does // things to the item damage we don't like ItemStack phantomBonemeal = player.getHeldItem(hand).copy(); if (ItemDye.applyBonemeal(phantomBonemeal, worldIn, pos)) { player.getHeldItem(hand).damageItem(1, player); } else { player.sendMessage(new TextComponentTranslation("text.scroll.incorrect_poison")); // Curse them Curses.applyMinorPoisonCurse(player); } return EnumActionResult.FAIL; } It works as intended, except when used on grass I've noticed that the client doesn't render all updated blocks. The clicked block updates fine (a grass/flower appears) but the grass/flowers which appear in a radius don't show up until I save and quit and re-open the game. I'm not sure if I've done something or there's an issue?
  7. EDIT: Solved. NBT on the item stack is what I wanted. Here's a tutorial that solved it for me: https://emxtutorials.wordpress.com/adding-nbt-data-to-items/ I'm new and maybe I have my terminology wrong, but I'd like to give items a bit/flag, a "quality" that really doesn't affect anything other than my mod's logic. I'd add a tooltip that identifies the quality for the user, but I don't need a custom texture or anything else. Do I need to go through and create item subtypes? That feels like overkill for a simple bit but I also don't fully understand the structure. The docs aren't entirely clear.
  8. Ok, I'm new to this so it took me a while to understand it all but the example they spelled out solved my issue. Thanks for pointing me in the right direction.
  9. I will, but the side aspect now seems unrelated to my issue, unless I have to get way more complex and split these up into logical client/server methods and have them communicate, which I hope is unnecessary..
  10. I'm defining custom logic for an item via onItemUse. While debugging I'm noticing that the method is actually called twice - once from the main thread and once from the server thread. This wasn't noticeable until I sent a message to the player - it shows twice. player.sendMessage(new TextComponentTranslation("text.scroll.backfire_poison")); I'm not sure what to do - I'm making block changes (right click a block to change it...) so this needs to run on the server but setting @SideOnly(Side.SERVER) doesn't work here. I need to find a way to prevent this from running twice.
  11. EDIT: I was trying this in creative... trying it in survival works as expected. Oops I need an item to be usable a set number of times. I'm using "setMaxDamage(8)", but I don't see a way to decrease it on each successful use. Older API examples passed the ItemStack as an arg to the onItemUse method, but it's not there in 1.12. I tried using "player.getHeldItemMainhand().damageItem(1)" but that didn't seem to have an effect. @Override public EnumActionResult onItemUse(EntityPlayer player, World worldIn, BlockPos pos, EnumHand hand, EnumFacing facing, float hitX, float hitY, float hitZ) { if (worldIn.getBlockState(pos).getBlock() == Blocks.COAL_ORE) { // Damage item ??? return super, , , , , , , ;
  12. Ok, I can reproduce this with just forge. Thanks for your help! Here's the issue I've filed: https://github.com/MinecraftForge/MinecraftForge/issues/4386
  13. I'd like to get an issue filed on forge but am not sure I know enough to describe it well. So to reproduce, all you need to do is cause a chunk reload after it's been unloaded? Am I correct in saying that it causes "tile entities to stop working"? I've noticed it also affects forestry beehives, botania endoflames, etc. It's literally everything.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.