-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Added the ability to make the structure spawn in a flat only zone. (#51). - Added the ability to replace blocks with other blocks when the structure spawns. (#58, #59). - Players can now create schematics using the plugin so it can be used on servers with limited FTP access. (#50). - Removed debug messages from the custom item system.
- Loading branch information
Showing
9 changed files
with
265 additions
and
138 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
58 changes: 58 additions & 0 deletions
58
src/com/ryandw11/structure/structure/properties/BlockLevelLimit.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
package com.ryandw11.structure.structure.properties; | ||
|
||
import org.bukkit.configuration.file.FileConfiguration; | ||
|
||
public class BlockLevelLimit { | ||
private String mode; | ||
|
||
private int x1, z1, x2, z2; | ||
|
||
public BlockLevelLimit(String mode, int x1, int z1, int x2, int z2){ | ||
this.mode = mode; | ||
this.x1 = x1; | ||
this.z1 = z1; | ||
this.x2 = x2; | ||
this.z2 = z2; | ||
} | ||
|
||
public BlockLevelLimit(){ | ||
mode = "NONE"; | ||
} | ||
|
||
public BlockLevelLimit(FileConfiguration fileConfiguration){ | ||
if(!fileConfiguration.contains("StructureLimitations.BlockLevelLimit")){ | ||
mode = "NONE"; | ||
return; | ||
} | ||
|
||
this.mode = fileConfiguration.getString("StructureLimitations.BlockLevelLimit.mode"); | ||
this.x1 = fileConfiguration.getInt("StructureLimitations.BlockLevelLimit.cornerOne.x"); | ||
this.z1 = fileConfiguration.getInt("StructureLimitations.BlockLevelLimit.cornerOne.z"); | ||
this.x2 = fileConfiguration.getInt("StructureLimitations.BlockLevelLimit.cornerTwo.x"); | ||
this.z2 = fileConfiguration.getInt("StructureLimitations.BlockLevelLimit.cornerTwo.z"); | ||
} | ||
|
||
public boolean isEnabled(){ | ||
return mode.equalsIgnoreCase("none"); | ||
} | ||
|
||
public String getMode(){ | ||
return mode; | ||
} | ||
|
||
public int getX1(){ | ||
return x1; | ||
} | ||
|
||
public int getX2(){ | ||
return x2; | ||
} | ||
|
||
public int getZ1(){ | ||
return z1; | ||
} | ||
|
||
public int getZ2(){ | ||
return z2; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.