mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2024-11-24 19:46:15 +01:00
Made it actually work, lawl
This commit is contained in:
parent
ef24c160ad
commit
dfe92470e5
@ -19,6 +19,7 @@ import net.citizensnpcs.api.util.DatabaseStorage;
|
|||||||
import net.citizensnpcs.api.util.NBTStorage;
|
import net.citizensnpcs.api.util.NBTStorage;
|
||||||
import net.citizensnpcs.api.util.Storage;
|
import net.citizensnpcs.api.util.Storage;
|
||||||
import net.citizensnpcs.api.util.YamlStorage;
|
import net.citizensnpcs.api.util.YamlStorage;
|
||||||
|
import net.citizensnpcs.api.npc.character.Character;
|
||||||
import net.citizensnpcs.command.CommandManager;
|
import net.citizensnpcs.command.CommandManager;
|
||||||
import net.citizensnpcs.command.Injector;
|
import net.citizensnpcs.command.Injector;
|
||||||
import net.citizensnpcs.command.command.AdminCommands;
|
import net.citizensnpcs.command.command.AdminCommands;
|
||||||
@ -168,14 +169,13 @@ public class Citizens extends JavaPlugin {
|
|||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
setupNPCs();
|
setupNPCs();
|
||||||
|
// Run metrics "last"
|
||||||
|
startMetrics();
|
||||||
}
|
}
|
||||||
}) == -1) {
|
}) == -1) {
|
||||||
Messaging.log(Level.SEVERE, "Issue enabling plugin. Disabling.");
|
Messaging.log(Level.SEVERE, "Issue enabling plugin. Disabling.");
|
||||||
getServer().getPluginManager().disablePlugin(this);
|
getServer().getPluginManager().disablePlugin(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Run metrics last
|
|
||||||
startMetrics();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void startMetrics() {
|
private void startMetrics() {
|
||||||
@ -191,8 +191,9 @@ public class Citizens extends JavaPlugin {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
Metrics.Graph graph = metrics.createGraph("Character Type Usage");
|
Metrics.Graph graph = metrics.createGraph("Character Type Usage");
|
||||||
for(Object i : characterManager.getRegistered()){
|
Messaging.log("Starting Metrics");
|
||||||
graph.addPlotter(new Metrics.Plotter(i.toString()) {
|
for(Character character : characterManager.getRegistered()){
|
||||||
|
graph.addPlotter(new Metrics.Plotter(character.getName()) {
|
||||||
@Override
|
@Override
|
||||||
public int getValue() {
|
public int getValue() {
|
||||||
return 1;
|
return 1;
|
||||||
|
Loading…
Reference in New Issue
Block a user