@EventHandler public void onPlayerInteractEntity(PlayerInteractEntityEvent event) { if (event.getRightClicked() instanceof Player) {...
Can't you just set the correct time on your servers? If for some reason not, try using CURRENT_TIMESTAMP as the default value in your MySQL table.
Location.getWorld() already returns a World, no need for typecasting. Make sure loc is a Location and not null.
Store an index for each player which tells what player the player previously teleported to, then increase the number and teleport to that index,...
You could pass your plugin instance in the constructor of your GameManagment
ItemStack wool = new ItemStack(Material.WOOL, 1); wool.setDurability(5); menu.setOption(4, wool, "Green Team", "");
I think System.currentTimeMillis() is independent of timezones.
PizzaPixel Why not? Just put "wool" instead of "new ItemStack(Material.WOOL, 1)" where ever you need it.
You can check the distance between two locations. // I'm not sure where you get these variables from Block block; Player player; // This is...
ItemStack wool = new ItemStack(Material.WOOL); wool.setDurability(1);
Any help would be greatly appreciated :)
The issue might be that the chest is in an unloaded chunk.
Hmm, didn't know that. So would it be for (Player player : Bukkit.getOnlinePlayers()) { if...
Cancel the chat event, loop through all players, check distance, send separate message if the player is within a radius.
That is very nice, I wouldn't dream that something like that would actually work. Bookmarking this for future reference :)
Separate names with a comma.