Hey, I'm just wondering if it is possible with the Bukkit API to set up a list in a yml file like so: boosts: - type: Speed cooldown: 10...
I've searched far and wide for an answer, but I haven't come up with a solution. I want to make a simple feature that removes any experience...
This is how I do it: Scoreboard board = Utils.getScoreboardManager().getNewScoreboard(); Objective obj = board.registerNewObjective("board",...
To give metadata to an entity: entity.setMetadata("myMetadata", new FixedMetadataValue(plugin, object)); To retrieve metadata: String value =...
In your saveInventory() method, you need to clear the currently saved inventory through this instead: fc.set(p.getName(), null);
Show me your code, please.
You need to wipe the configuration section before changing it. Add this to the beginning of your saveInventory() method:...
Create a new InventoryCloseEvent and check if the event.getInventory() is the same as your custom inventory. If it is, then save the inventory...
Bukkit.getOnlinePlayers().length;
The code I provided would still work with a custom inventory. The "inv" variable would be your custom inventory. You have to create a method to...
I don't see the problem here.
You would go about saving an inventory like this: for(int x = 0; x <= (inv.getSize() - 1); x++){ if(inv.getItem(x) != null &&...
I'm not completely sure of what you mean by "Chest GUI." I'm going to assume you mean an inventory menu in which players may click items in the...
if(event.getEntity() instanceof Player && event.getDamager() instanceof Arrow){ Arrow arrow = event.getDamager();...
You don't use curly brackets for methods, instead you need to use parentheses. It should be public void onEnable(){ and onDisable(){
Separate names with a comma.