Jump to content

Draco18s

Members
  • Posts

    16559
  • Joined

  • Last visited

  • Days Won

    156

Everything posted by Draco18s

  1. "supposed to propagate downwards" -> lets sky light through it. This is clearly not the effect you want. The point wasn't to follow the existing logic to see what the default method returns for your block (because duh, the default logic doesn't work for you), it was to figure out how opaque blocks block skylight.
  2. There are functions that define this. The default checks what kind of item things are and allows or denies various enchantments. TieredItem only allows Unbreaking (because that's the default).
  3. Lets check the original function. "If the block is opaque, return the maximum light value. Otherwise if sky light is supposed to propagate downwards, return 0. Otherwise return 1." 🤔
  4. You do know what that returned int does, right?
  5. Well darn. What is it for, then? I know that the various functions don't do what one expects half the time, looks like I messed that one up again.
  6. Yes, use Capabilities. The NBT system is what vanilla uses and half the functions available don't do what you think they do. getTileData() for instance doesn't let you store data in the tile entity, it is the NBT representation of the tile entity so it can be stored in an ItemStack. NBT is a serialized data format meant to store the (whatever) on disk. Its not meant to be run-time modified left and right. Vanilla uses it for arbitrary data storage on ItemStacks because Mojang doesn't have a better method.
  7. The server would have to do all the same calculations the client did in order to approve.
  8. Note that it counts up towards ItemStack#getMaxDamage, so an undamaged item will return 0 out of X and a fully damaged item will be X out of X (next use breaks it).
  9. Seems pretty self explanatory to me.
  10. Cheating. Player says "let me just modify my recipe files so that cobblestone makes diamonds." Normal server goes "what, no stupid, you can't make diamonds out of cobblestone." You: "OK, diamonds for you! That is a totally legitimate result I believe you're being honest."
  11. So much has changed from 1.12 to 1.16 that very little of your code is going to be usable. You can try importing it and fixing errors, but you're going to have hundreds.
  12. For mods that are yours: Pretty much start from scratch. For mods that aren't yours: Get permission first.
  13. You should probably also use orElseThrow instead of orElse(null).
  14. There isn't one. Documentation (such as there is) is all inside the code itself.
  15. Why the fauk does your renderer change what blocks are in the world? That's not the job of a renderer.
  16. Gasp, you're not on the server.
  17. Why did you create two lazy optionals, then unbox them to pass into the CombinedInvWrapper? (Not to mention using an array to store the local results? Why!?) return LazyOptional.of(() -> (T)new CombinedInvWrapper(getHandler(), new EntityArmorInvWrapper(entity)));
  18. I don't think this gives you water as a below block but rather a block that is waterlogged. Check how lily pads work.
  19. Post your code. My guess is that you're registering an event handler to the wrong bus.
  20. Linked resources are not in your src folder, they're stored elsewhere and referenced in your Project Explorer tab of your IDE.
  21. Yeah I looked at your comments (there were all of about five). Nothing stood out. Start with the mods here, I guess.
  22. In poking around my guess is that you were added as a blocked user. Why? Don't know.
  23. GUIs aren't that difficult. There's dozens of tutorials for them and they haven't really changed all that much in ten years.
  24. Yeah, because you're passing in a height value that's 2.5 times taller than the vanilla Button renderer expects. It expects that all UI buttons are only 20 pixels tall and the sprite sheet reflects that. So what you're seeing is other areas of the UI sprite sheet. (Is the vanilla code broken? Yes. Does Mojang care? No)
×
×
  • Create New...

Important Information

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