Posted July 28, 201312 yr Hello there, I am on the Fossils and Archaeology Revival team, mainly doing generation. Currently I am trying to convert our current method of using Java written structures into .schematics, can anyone help with this? Like are their any open source examples? I have the NBT tags all set up but I haven't really done much work with .schematic importing. I'm not asking for all the code to be handed to me, just a few pointers to get me going willhew
July 28, 201312 yr Hi, actually kinda funny. I've been working on a mod to add .schematic support to forge called LibSchematic (github repo: https://github.com/tehbeard/LibSchematic) Several things: [*]Can load .schematic from jar/resource path (if you can get an InputStream to it, it'll load it [*]Supports dynamic block ids (On the fly translation) [*]~98% Certain it doesn't trigger block updates (might trip something already in world, never really tested) [*]Mod block friendly, mods can provide a helper class for blocks to assist rotation and other actions.
July 29, 201312 yr Author Ok, I may just stick with the way it currently is , but aside from that, does anyone know how to generate items in chests inside our Java files? We have the java files and the chests spawn in there but I want to have items generating inside these chests, any thoughts? Thanks, Will
July 29, 201312 yr Ok, I may just stick with the way it currently is , but aside from that, does anyone know how to generate items in chests inside our Java files? We have the java files and the chests spawn in there but I want to have items generating inside these chests, any thoughts? Thanks, Will Fairly easy. When you generate the chest block, also make a new TileEntity. A TileEntityChest to be exact. Then using one of the methods in the class, add items to your generated chest. Oh, make sure the coords for the TileEntity are the EXACT SAME as the chest block. I think its something like: tileEntityChestVariable.addItemStackToSlot(slotID, new ItemStack(Item.diamond, 1)); I think its something like that at least... Don't take my word for it I am Mew. The Legendary Psychic. I behave oddly and am always playing practical jokes. I have also found that I really love making extremely long and extremely but sometimes not so descriptive variables. Sort of like what I just did there
July 29, 201312 yr Author Thanks for that Now I may finally get this done and move onto my next project
July 30, 201312 yr When you generate the chest block, also make a new TileEntity. Don't make a new TileEntity! When the chest block is generated, this already has generated the TileEntity. You'll need to retrieve the TileEntity (with world.getBlockTileEntity()). Author of PneumaticCraft, MineChess, Minesweeper Mod and Sokoban Mod. Visit www.minemaarten.com to take a look at them.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.