-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Remove metrics * Refactoring, huge changes to code * Clean up, refactoring * Move AreaStyle class to a separate file * Package rename * Fix package name * Fixed OfflinePlayers UUID conversion, updated to 1.16.4
- Loading branch information
1 parent
713c5ea
commit c686740
Showing
17 changed files
with
421 additions
and
1,337 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
30 changes: 30 additions & 0 deletions
30
src/main/java/jahan/khan/jdynmapgriefprevention/AreaStyle.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,30 @@ | ||
package jahan.khan.JDynmapGriefPrevention; | ||
|
||
import org.bukkit.configuration.file.FileConfiguration; | ||
|
||
class AreaStyle { | ||
final String strokecolor; | ||
|
||
final double strokeopacity; | ||
final int strokeweight; | ||
final String fillcolor; | ||
final double fillopacity; | ||
String label; | ||
|
||
AreaStyle(FileConfiguration cfg, String path, AreaStyle def) { | ||
this.strokecolor = cfg.getString(path + ".strokeColor", def.strokecolor); | ||
this.strokeopacity = cfg.getDouble(path + ".strokeOpacity", def.strokeopacity); | ||
this.strokeweight = cfg.getInt(path + ".strokeWeight", def.strokeweight); | ||
this.fillcolor = cfg.getString(path + ".fillColor", def.fillcolor); | ||
this.fillopacity = cfg.getDouble(path + ".fillOpacity", def.fillopacity); | ||
this.label = cfg.getString(path + ".label", null); | ||
} | ||
|
||
AreaStyle(FileConfiguration cfg) { | ||
this.strokecolor = cfg.getString("regionstyle" + ".strokeColor", "#FF0000"); | ||
this.strokeopacity = cfg.getDouble("regionstyle" + ".strokeOpacity", 0.8D); | ||
this.strokeweight = cfg.getInt("regionstyle" + ".strokeWeight", 3); | ||
this.fillcolor = cfg.getString("regionstyle" + ".fillColor", "#FF0000"); | ||
this.fillopacity = cfg.getDouble("regionstyle" + ".fillOpacity", 0.35D); | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package jahan.khan.jdynmapgriefprevention; | ||
package jahan.khan.JDynmapGriefPrevention; | ||
|
||
import java.util.UUID; | ||
|
||
|
Oops, something went wrong.