Jump to content

[1.8] Saving data to the save file


AnZaNaMa

Recommended Posts

So, I am making what I call a PipeSystem to transfer energy around using my mod. The problem is, I'm not sure how I can make it so that the pipe system works after the game has been unloaded and then opened again. The PipeSystem is an object-class that is created whenever a lone machine or pipe is placed. Then, when other eligible TileEntities are placed adjacent to TileEntities in the PipeSystem, they get added to the PipeSystem. I want to either save all the PipeSystems to a world NBT file with unique IDs if possible or somehow save it to the TileEntities themselves, but then I would be required to have a controller TileEntity to save the data in or save it to all of them, which would make for a lot of redundant data. I'd like to avoid having one block that controls the whole system. This isn't logisticspipes :P (no offense, I love that mod).

- Just because things are the way they are doesn't mean they can't be the way you want them to be. Unless they're aspen trees. You can tell they're aspens 'cause the way they are.

Link to comment
Share on other sites

yes, but they work in tandem using a PipeSystem and I need to save data from the PipeSystem object.

 

Sorry heres a link to the code:

 

PipeSystem:

https://github.com/AnZaNaMa/EnergyTools/blob/master/src/main/java/com/AnZaNaMa/EnergyTools/api/Tech/PipeSystem.java

 

Pipes:

https://github.com/AnZaNaMa/EnergyTools/blob/master/src/main/java/com/AnZaNaMa/EnergyTools/Entity/TileEntity/TileEntityPipe.java

- Just because things are the way they are doesn't mean they can't be the way you want them to be. Unless they're aspen trees. You can tell they're aspens 'cause the way they are.

Link to comment
Share on other sites

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

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