Saving blocks/chest/signs to a file.

Discussion in 'Plugin Development' started by Paxination, Dec 27, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    Paxination

    How would I go about saving this info to a file. I am familiar with blockstate, and it would make my life so much easier if it saved chest contents and sign text correctly but it doesnt. So how should I go about saving chest contents and sign text to a file? All of this is in a given radius.

    I am trying to make a plugin that lets a player basically MOVE their house. Minus landscaping. So the blocks used in your house cant be stone, dirt, grass, sand, gravel. Normal building blocks that people use in houses.

    Any ideas on the best way to do this?
     
  2. Offline

    maciekmm

    Paxination move house? Where? If on thesame server you can save it in HashMap<String,ArrayList<Block>> where String is player's name.
     
  3. Offline

    CubieX

    How about using WorldEdit/WorldGuard to create a region containing the players house and then save and cut this region and paste it somewhere else?
    This way you would not have to wory about how it is saved or loaded.
    Reading through the WorldGuard API is surely easier and faster than developing this from scratch.

    Or do you mean this different from that?
     
  4. Offline

    Paxination

    Yeah WorldEdit isnt really much of an option as I am trying to make this an option to purchase in game with igm. For players to move their house around on the server. I know I can use its API, but I dont want to save the terrain, just the house itsself.

    Saving the blocks isnt the issue at the moment. What im looking for is how should I go about doing chest/contents and signs/text. And im considering saving it all to disk as well in case of server crash and they dont lose everything.
     
Thread Status:
Not open for further replies.

Share This Page