Skip to content

Commit

Permalink
Some documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
Pavel Fedin committed Nov 25, 2016
1 parent 257bb88 commit 2ad9938
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/main/java/ru/wpstuio/amorphine/mcaliases/Region.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,20 @@ public Chunk[][] getChunks() {
return chunks;
}

/**
* Returns a chunk with given local coordinates from region
* @param cords
* @return
*/
public Chunk getChunk(Coordinates2d cords) {
return chunks[cords.getX()][cords.getZ()];
}

/**
* Saves given chunk data to region file;
* @param chunk
* @throws IOException
*/
public void saveChunk(Chunk chunk) throws IOException{

int local_x = chunk.getLocalX();
Expand All @@ -68,7 +78,7 @@ public void saveChunk(Chunk chunk) throws IOException{
}

/**
*
* Saves given tag as a chunk to mca-file;
* @param cords
* @param tag
* @throws IOException
Expand Down

0 comments on commit 2ad9938

Please sign in to comment.