Skip to content

Commit

Permalink
* Added the "getBaseBlockPageMap", "setBaseBlockPageMap", "setCurrent…
Browse files Browse the repository at this point in the history
…BaseBlockPage", and "getCurrentBaseBlockPage" methods to the "DataPack" interface for the new base-block multi-page system.

Signed-off-by: XZot1K <[email protected]>
  • Loading branch information
XZot1K committed Sep 7, 2020
1 parent 0ecbb4e commit f28a64a
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 24 deletions.
2 changes: 1 addition & 1 deletion API Version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
## API-VERSION 1.1.3 ##
## API-VERSION 1.1.4 ##
23 changes: 0 additions & 23 deletions DisplayShopsAPI.iml

This file was deleted.

33 changes: 33 additions & 0 deletions src/xzot1k/plugins/ds/api/objects/DataPack.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,12 @@
package xzot1k.plugins.ds.api.objects;

import org.bukkit.entity.Player;
import org.bukkit.inventory.ItemStack;
import org.bukkit.scheduler.BukkitTask;
import xzot1k.plugins.ds.api.enums.ChatInteractionType;

import java.util.HashMap;
import java.util.List;

public interface DataPack {

Expand Down Expand Up @@ -139,6 +141,37 @@ public interface DataPack {

void setCurrentChatTask(BukkitTask currentChatTask);

/**
* Gets the player cooldown map for the player.
*
* @return The map itself.
*/
HashMap<String, Long> getCooldownMap();

/**
* Gets the base-block page map for the player if it exists.
*
* @return The map itself.
*/
HashMap<Integer, List<ItemStack>> getBaseBlockPageMap();

/**
* Sets the base-block page map for the player.
*
* @param baseBlockPageMap The map to set it as.
*/
void setBaseBlockPageMap(HashMap<Integer, List<ItemStack>> baseBlockPageMap);

/**
* Gets the current page the player is on from the base block page map.
*
* @return The current page.
*/
int getCurrentBaseBlockPage();

/**
* Sets the current page the player is on from the base block page map.
*/
void setCurrentBaseBlockPage(int currentBaseBlockPage);

}

0 comments on commit f28a64a

Please sign in to comment.