测试版
This commit is contained in:
parent
9389a76b0a
commit
e507cb033d
|
@ -72,6 +72,9 @@ public class GameListener implements Listener {
|
|||
if(p.isSneaking()){
|
||||
RepairGiftGui.OpenGui(p);
|
||||
} else {
|
||||
if (p.getGameMode() == GameMode.CREATIVE) {
|
||||
p.setGameMode(GameMode.SPECTATOR);
|
||||
}
|
||||
Main.gameData.refreshTheNonBlankBlockOfMiningArea(); // 刷新矿区当前块数量
|
||||
}
|
||||
e.setCancelled(true);
|
||||
|
|
|
@ -18,7 +18,7 @@ public class GiftListener implements Listener {
|
|||
@EventHandler
|
||||
public void onGfit(LiveGiftEvents e) {
|
||||
Player zhubo = e.getPlayer();
|
||||
String userName = ""+ RandomUtil.getRandomInt(999,10000);
|
||||
String userName = ""+ RandomUtil.getRandomInt(10000,90000);
|
||||
boolean butt = false;
|
||||
if(e.getUser().nickName() != null) {
|
||||
userName = e.getUser().nickName();
|
||||
|
@ -35,11 +35,8 @@ public class GiftListener implements Listener {
|
|||
}
|
||||
GiftData giftData = configYml.getGiftData(giftName);
|
||||
giftData.OutCompleEvent(amount);
|
||||
String show_userName = GameUtil.HideName(userName);
|
||||
for (Player player : Bukkit.getOnlinePlayers()){
|
||||
player.sendMessage("§a礼物: §e"+show_userName+" §d送来了 §e"+giftName+"x"+amount);
|
||||
}
|
||||
String eventName = giftData.getEvent();
|
||||
String show_userName = GameUtil.HideName(userName);
|
||||
if(GameUtil.specialGiftEffectTriggers(zhubo,eventName,show_userName,amount)){
|
||||
return;
|
||||
}
|
||||
|
@ -65,5 +62,8 @@ public class GiftListener implements Listener {
|
|||
}, (long) i * dadey);
|
||||
}
|
||||
}
|
||||
for (Player player : Bukkit.getOnlinePlayers()){
|
||||
player.sendMessage("§a礼物: §e"+ show_userName+" §d送来了 §e"+giftName+"x"+amount);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user