Skip 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. Maybe. We don't have enough information to help you, as from the code supplied and the description given, we do not know where you've stored the NBT tag or if that object is available at that point.
  2. Do consider mods like Mystcraft which can created extra dimensions using any biome (including Sky and Hell). If you're doing something like Nether Ore generation, your ores should generate in these dimensions. Especially as some users wish to create "Nether Analogs" for their Ages.
  3. Yeeaahh....start with something simpler.
  4. Yes. Write your own chunk provider.
  5. You want the results to be different (and random) and stack? These two statements do not go together.
  6. Send a PM to Veovis. He's the one who figured it out and has a working codebase.
  7. Sorry, it should be world.getBlockId(x,y,z) But if you can't use your javadoc and Eclipse codehinting properly I'm not going to help you.
  8. HOLY CRAP YOU CAN USE VARIABLES TO SAVE THE RESULTS OF A CALL TO RANDOM. Yes, I'm mocking you:
  9. world.getBlock(x, y, z) ?
  10. This makes no sense. One does not place back a tile entity that shouldn't be there after you remove its parent block.
  11. Because the rest of the time it's just a variable in memory!
  12. Use your block to scan the area around itself and then use magic to change the spawner properties. Like setting the current time (NBTTagCompound.getShort("Delay")) to a number greater than 1.
  13. ASM or Reflections. Or base class editing.
  14. Just to show how unfamiliar I am: I was pretty sure they referred to the same thing. @..@ Oh sweet, how about that.
  15. Taking a look at Thaumcraft's source (JD GUI is awesome) I can't figure out how everything works, but it looks like he has a general look-up function that takes an item ID and checks it against various recipes (arcane, crucible, etc.) and generates a list of essence types (stored as a list of Enum values). For something more like adding "burnable" to it, ASM might be your best bet. Note: the Reflections API is not for the faint of heart.
  16. Gravity is not a globally referenced variable. Every entity handles its own downward movement and acceleration. (Blocks do not obey gravity, in any way, what so ever. "But sand and gravel!" you say. "Entities. EntityFallingSand. Not a block" I reply.)
  17. @Override public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List par3List) { par3List.add("Whatever string you want to display here"); } Which you probably could have figured out by looking at the classes of any item that displays tooltip information. Like ItemRecord.
  18. ByteArrayOutputStream bt = new ByteArrayOutputStream(); DataOutputStream out = new DataOutputStream(bt); out.writeBoolean(true); Packet250CustomPayload packet = new Packet250CustomPayload("MyChannel", bt.toByteArray()); PacketDispatcher.sendPacketToServer(packet);
  19. I would just like to report that mnn's solution works. He got the config syntax wrong, but there is a set method that works for most data types. I wanted to read in an integer array, then sort it, in order to take advantage of reading this array later in a fast method. So I figured I might as well sort the array and save it back to the config. Here's the solution: int[] white = config.get("WorldGen","dimensionWhitelistList", new int[] {0}).getIntList(); //read the values, supplying defaults int[] black = config.get("WorldGen","dimensionBlacklistList", new int[] {-1,1}).getIntList(); Arrays.sort(white); //sort Arrays.sort(black); String a=Arrays.toString(white); String whitestring[]=a.substring(1,a.length()-1).split(", "); //have to convert to a string array in order to write String b=Arrays.toString(black); String blackstring[]=b.substring(1,b.length()-1).split(", "); config.get("WorldGen","dimensionWhitelistList", new int[] {0}).set(whitestring); //default values here are irrelevant, but required in order to retrieve the config Property config.get("WorldGen","dimensionBlacklistList", new int[] {-1,1}).set(blackstring);
  20. IC2 or BuildCraft. I know IC2 has an API; BC should have one.
  21. IChunkProvider is either not all you're using or you're using something else entirely. IChunkProvider does not contain that method.
  22. I am sorry but I do not see how that would work seeing that I need the server to be able to read and write to the same file. You only need to read at one point: When the server starts You only need to write at one point: When the server stops (There's one additional write operation: if the file to read doesn't exist, initialize it). There's no reason to be reading and writing to the same file at the same time (although you can). That said: Take a look at this post. It will allow you to create and read an arbitrary NBT data file.
  23. A source code base you can peek at: https://github.com/Draco18s/Decaying-World Mind I didn't make any armor, but armor should use the same basic functions.
  24. It's still a thought worth checking: disable the tick handler and see what happens.

Important Information

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

Account

Navigation

Search

Search

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.