Sorry, I thought the ItemMeta#getLore() method returned a String array, it actually returns an ArrayList. Change: String[] lore = ((Player)...
I apologise if what I write is not what you want to do at all, but here it is: As you've most likely seen in interfaces, methods are empty...
I'd just create a method that returns an integer and takes an ItemStack within it's parameters. To get the blood value, let's say that it is...
This should help you.
Argh. Beaten to it! You are initialising the variable once outside of any method, this means once it has generated the value it will never...
If the problem is that the display name is not appearing, it is because you did not set the ItemStack's meta again once you had changed it. You...
Oh, simply keep track of your players inside an ArrayList once they have typed /join. Instead of going through the online players, simply change...
Just check the length of the array returned by the getOnlinePlayers() method inside the Bukkit class: if(Bukkit.getServer().getOnlinePlayers() <...
Sure. This isn't tested, but hopefully there no syntax errors and so on. @EventHandler public void onPlayerHitPlayer(EntityDamageByEntityEvent...
If you are creating teams through ArrayLists etc., then you'll need to cancel events that is fired in combat yourself. You could check in the...
(Replying to thread owner) Sorry, my mistake. The foor loop probably would not have run because the first number was already bigger than the...
If you want to spawn a wall along the x co-ordinate, you'd do the following: for(double i = player.getLocation().getX(); i < 10; i++) {...
This code here should work as an example to show you how to begin building a wall (straight line of one block here): for(double i = 0; i < 10;...
I can't see a reason that would be causing an error. Did you try the other solutions that were given?
I believe the code is throwing a NullPointerException because you are assuming that the ItemStack has an ItemMeta and a display name. To solve...
Separate names with a comma.