Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Draco18s

Members
  • Joined

  • Last visited

Everything posted by Draco18s

  1. Particles are weird. You need a whole class for them. http://jabelarminecraft.blogspot.com/p/minecraft-forge-1721710-modding-tips.html
  2. You can, but the better question is why? (Usually people want to know how to prevent the drops)
  3. In order to send the data from server to client (getDescriptionPacket) and to save the data to the hard drive and load it back again.
  4. I do believe this is why particles were invented.
  5. Unrelated, please do not center your posts. It's annoying as fuck to read. Thanks.
  6. You could also have used instanceof . But worldObj.isRemote is probably the best method.
  7. It can be done. Look at XCompWiz's Looking Glass mod.
  8. EnumChatFormatting
  9. Just FYI, if you plan on using biome data (temperature and rainfall), make sure to clamp the values so you don't cause array index bounds errors when another mod modified those values (say...by making the nether hotter than a desert, etc)
  10. This is not true. Check Vec3i. Sorry, I was basing off the fact that it didn't work (implying that BlockPos was not overriding those functions).
  11. Long story short: BlockPos does not override Equals and HashCode, so it isn't (usefully) hashtableable. While this will return a value, this is not useful, because this fails: BlockPos pos = new BlockPos(0, 0, 0); currentRespawnLocs.put(pos, true); pos = new BlockPos(0, 0, 0); currentRespawnLocs.get(pos);
  12. Entities don't have NBT. NBT is their compressed save file format.
  13. Create your own recipe list. It's just a class that holds the relevant information, which you would then call an addRecipe function for, just like vanilla.
  14. Define "later needs this data."
  15. Warning about pure ASM: While this is possible, be aware that Clay almost certainly does not have its own updateTick and onNeighborChanged methods, meaning that requesting them will cause a null return. These functions are instead handled by the Block superclass, which if you ASM those methods, will be called for all blocks. You will want to insert an static function call which lets you discriminate between blocks without having to write huge chunks of code in bytecode. That call can also fire Forge events. This repo is out of date, massively, and doesn't compile/run properly, but it shows what I mean by inserting a static function call. https://github.com/Draco18s/HarderStuff/blob/master/main/java/com/draco18s/cropcore/asm/CropPatcher.java#L85-99 I later had issues with the event call, and ended up calling the event constructor with Reflection. If you do that, just let your static function throw the exceptions; the try...catch block weirdly lags the simulation (Forge tps says "20 ticks per second" but it visibly takes closer to 20 seconds per tick*). *I'd love a good explanation as to why.
  16. Careful with using ASM. Too much of it and you turn into a mere husk, housing something dark and evil.
  17. #HereBeDragons Or: You've wandered too far off your known map of programming. You're exploring deep into territory you don't understand and which few people will help you with because it's violating a principle of how Minecraft works. You can do it, but you're going to be largely on your own to figure out how. A different approach would be to use Forge Multipart and have your cables be a "subpart" that can be added to every block.
  18. You don't need NBT data here. Just use a private float property.
  19. You can use ASM to modify the silverfish to recognize additional blocks. Is not clean or easy, but you can.
  20. Well, you should use one of those and pass a type of damage and the entity repainted (the player, null with throw errors).
  21. My factory is random, but it doesn't have to be. The important part is the Item class translating from NBT to effect.
  22. This class may be of some help https://github.com/Draco18s/Artifacts/blob/master/main/java/com/draco18s/artifacts/item/ItemArtifact.java
  23. block == Blocks.log
  24. Your code is a mess. Remove this: private static final String __OBFID = "CL_00001777"; That line is for Forge to reobfuscate vanilla class. Remove: IIcon[] iconArray1; You're not using it. As for your actual problem: CaSe maTteRs. double check that your file names match eXacTLy.

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.