new-1
This commit is contained in:
parent
39e85f5c69
commit
6eaa298fb1
BIN
lib/API-1.0.jar
BIN
lib/API-1.0.jar
Binary file not shown.
|
@ -19,8 +19,16 @@ public class LuckyBlockEffect extends GameGiftEffect {
|
||||||
private static List<ItemStack> itemStacks = new ArrayList<>();
|
private static List<ItemStack> itemStacks = new ArrayList<>();
|
||||||
|
|
||||||
static {
|
static {
|
||||||
|
itemStacks.add(new ItemStackBuilder(Material.TURTLE_HELMET).setDisplayName("§2§l绿帽子").addEnchant(Enchantment.PROTECTION, 2).build());
|
||||||
itemStacks.add(new ItemStackBuilder(Material.ENDER_PEARL).setAmount(16).build());
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_PEARL).setAmount(16).build());
|
||||||
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
||||||
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
||||||
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
||||||
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
||||||
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
||||||
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
||||||
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
||||||
|
itemStacks.add(new ItemStackBuilder(Material.ENDER_EYE).setAmount(16).build());
|
||||||
itemStacks.add(new ItemStackBuilder(Material.DIAMOND_BLOCK).setAmount(16).build());
|
itemStacks.add(new ItemStackBuilder(Material.DIAMOND_BLOCK).setAmount(16).build());
|
||||||
itemStacks.add(new ItemStackBuilder(Material.DIAMOND).setAmount(64).build());
|
itemStacks.add(new ItemStackBuilder(Material.DIAMOND).setAmount(64).build());
|
||||||
|
|
||||||
|
|
|
@ -30,24 +30,20 @@ public class GameListener implements Listener {
|
||||||
EnderDragonWar.game.quitGame(event.getPlayer());
|
EnderDragonWar.game.quitGame(event.getPlayer());
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* 死亡后游戏时间 +5分钟
|
|
||||||
* */
|
|
||||||
@EventHandler
|
@EventHandler
|
||||||
public void onDeath(PlayerDeathEvent event) {
|
public void onDeath(PlayerDeathEvent event) {
|
||||||
event.setDeathMessage(null);
|
event.setDeathMessage(null);
|
||||||
Player p = event.getEntity();
|
Player player = event.getEntity();
|
||||||
new BukkitRunnable() {
|
new BukkitRunnable() {
|
||||||
private int i = 0;
|
private int i = 0;
|
||||||
|
|
||||||
public void run() {
|
public void run() {
|
||||||
if (i == 1) {
|
if (i == 1) {
|
||||||
p.spigot().respawn();
|
player.spigot().respawn();
|
||||||
}
|
}
|
||||||
// 增加游戏时间5分钟
|
|
||||||
if (i == 3) {
|
if (i == 3) {
|
||||||
EnderDragonWar.game.addLiveTime(5);
|
EnderDragonWar.game.addLiveTime(5);
|
||||||
p.sendTitle("§4你嘎了", "§e加播5分钟!");
|
player.sendTitle("§4你嘎了", "§e加播5分钟!");
|
||||||
cancel();
|
cancel();
|
||||||
}
|
}
|
||||||
i++;
|
i++;
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
name: EnderDragonWar
|
name: EnderDragonWar
|
||||||
version: 1.0
|
version: 1.0
|
||||||
api-version: 1.20
|
api-version: 1.20
|
||||||
main: com.yaohun.enderdragonwar.Main
|
main: com.yaohun.enderdragonwar.EnderDragonWar
|
||||||
depend: [PixelLiveAPI]
|
depend: [PixelLiveAPI]
|
||||||
commands:
|
commands:
|
||||||
enderdragonwar:
|
enderdragonwar:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user