Example #1
0
 public void removeThought(String name) {
   for (Thought t : thoughts)
     if (t.getName().equalsIgnoreCase(name)) {
       thoughts.remove(t);
       plugin.getConfiguration().removeDreamPlayerThought(playerName, t.getName());
       break;
     }
 }
Example #2
0
  public void setWakeInformation(Location wakeLocation, Inventory wakeInventory) {
    this.wakeLocation = wakeLocation;
    if (wakeInventory == null) this.wakeInventory = null;
    else {
      this.wakeInventory = Bukkit.getServer().createInventory(null, InventoryType.PLAYER);
      this.wakeInventory.setContents(wakeInventory.getContents());
    }

    plugin
        .getConfiguration()
        .setDreamPlayerWakeInfo(playerName, this.wakeInventory, this.wakeLocation);
  }
Example #3
0
 public void setDream(Dream dream) {
   this.dream = dream;
   plugin.getConfiguration().setDreamPlayerDream(dream, playerName);
 }
Example #4
0
 public void addThought(Thought thought) {
   thoughts.add(thought);
   plugin.getConfiguration().setDreamPlayerThought(playerName, thought);
 }
Example #5
0
 public void setState(PlayerState state) {
   this.state = state;
   plugin.getConfiguration().setDreamPlayerState(playerName, state);
 }
Example #6
0
 public void clearDream() {
   dream = null;
   plugin.getConfiguration().removeDreamPlayerDream(playerName);
 }