mirror of
https://github.com/sekwah41/Advanced-Portals.git
synced 2025-01-28 19:12:09 +01:00
part of the prefix update thing
This commit is contained in:
parent
3c93be91e6
commit
e80196062b
@ -63,4 +63,4 @@ UseWarpPrefix: true
|
|||||||
|
|
||||||
UseCustomPrefix: false
|
UseCustomPrefix: false
|
||||||
|
|
||||||
CustomPrefix: '[Test]'
|
CustomPrefix: '&a[&eAdvancedPortals&a]'
|
||||||
|
@ -14,6 +14,10 @@ public class AdvancedPortalsPlugin extends JavaPlugin {
|
|||||||
|
|
||||||
public NMS nmsAccess;
|
public NMS nmsAccess;
|
||||||
|
|
||||||
|
public boolean useCustomPrefix = false;
|
||||||
|
|
||||||
|
public String customPrefix = "\u00A7a[\u00A7eAdvancedPortals\u00A7a]";
|
||||||
|
|
||||||
public void onEnable() {
|
public void onEnable() {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@ -64,7 +68,12 @@ public class AdvancedPortalsPlugin extends JavaPlugin {
|
|||||||
// only copy the file if it doesnt exist!
|
// only copy the file if it doesnt exist!
|
||||||
ConfigAccessor config = new ConfigAccessor(this, "Config.yml");
|
ConfigAccessor config = new ConfigAccessor(this, "Config.yml");
|
||||||
config.saveDefaultConfig();
|
config.saveDefaultConfig();
|
||||||
|
|
||||||
|
this.useCustomPrefix = config.getConfig().getBoolean("UseCustomPrefix");
|
||||||
|
if(useCustomPrefix){
|
||||||
|
this.customPrefix = config.getConfig().getString("CustomPrefix");
|
||||||
|
}
|
||||||
|
|
||||||
ConfigAccessor portalconfig = new ConfigAccessor(this, "Portals.yml");
|
ConfigAccessor portalconfig = new ConfigAccessor(this, "Portals.yml");
|
||||||
portalconfig.saveDefaultConfig();
|
portalconfig.saveDefaultConfig();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user