Participant List fix.
This commit is contained in:
parent
68e402cf78
commit
de41e4bde3
Binary file not shown.
@ -1,6 +1,6 @@
|
|||||||
name: TwosideKeeper
|
name: TwosideKeeper
|
||||||
main: sig.plugin.TwosideKeeper.TwosideKeeper
|
main: sig.plugin.TwosideKeeper.TwosideKeeper
|
||||||
version: 3.8.2r1
|
version: 3.8.2r2
|
||||||
commands:
|
commands:
|
||||||
money:
|
money:
|
||||||
description: Tells the player the amount of money they are holding.
|
description: Tells the player the amount of money they are holding.
|
||||||
|
@ -74,6 +74,7 @@ public class EliteMonster {
|
|||||||
BossBar bar = null;
|
BossBar bar = null;
|
||||||
|
|
||||||
List<Player> targetlist = new ArrayList<Player>();
|
List<Player> targetlist = new ArrayList<Player>();
|
||||||
|
List<Player> participantlist = new ArrayList<Player>();
|
||||||
//Contains all functionality specific to Elite Monsters.
|
//Contains all functionality specific to Elite Monsters.
|
||||||
//These are checked every 5 ticks, so have very high control over the monster itself.
|
//These are checked every 5 ticks, so have very high control over the monster itself.
|
||||||
EliteMonster(Monster m) {
|
EliteMonster(Monster m) {
|
||||||
@ -277,6 +278,9 @@ public class EliteMonster {
|
|||||||
if (!targetlist.contains(damager) && (damager instanceof Player)) {
|
if (!targetlist.contains(damager) && (damager instanceof Player)) {
|
||||||
targetlist.add((Player)damager);
|
targetlist.add((Player)damager);
|
||||||
}
|
}
|
||||||
|
if (!participantlist.contains(damager) && (damager instanceof Player)) {
|
||||||
|
participantlist.add((Player)damager);
|
||||||
|
}
|
||||||
if (damager instanceof Player) {
|
if (damager instanceof Player) {
|
||||||
Player p = (Player)damager;
|
Player p = (Player)damager;
|
||||||
p.addPotionEffect(new PotionEffect(PotionEffectType.WEAKNESS,20*2,9),true);
|
p.addPotionEffect(new PotionEffect(PotionEffectType.WEAKNESS,20*2,9),true);
|
||||||
@ -494,6 +498,10 @@ public class EliteMonster {
|
|||||||
return targetlist;
|
return targetlist;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public List<Player> getParticipantList() {
|
||||||
|
return participantlist;
|
||||||
|
}
|
||||||
|
|
||||||
public void randomlyTeleport() {
|
public void randomlyTeleport() {
|
||||||
Location l = getNearbyFreeLocation(m.getLocation(),24);
|
Location l = getNearbyFreeLocation(m.getLocation(),24);
|
||||||
m.teleport(l);
|
m.teleport(l);
|
||||||
|
@ -4658,7 +4658,7 @@ public class TwosideKeeper extends JavaPlugin implements Listener {
|
|||||||
dropmult+=50;
|
dropmult+=50;
|
||||||
EliteMonster em = GenericFunctions.getEliteMonster(m);
|
EliteMonster em = GenericFunctions.getEliteMonster(m);
|
||||||
//For each target, drop additional loot and exp.
|
//For each target, drop additional loot and exp.
|
||||||
List<Player> participants = em.getTargetList();
|
List<Player> participants = em.getParticipantList();
|
||||||
StringBuilder participants_list = new StringBuilder();
|
StringBuilder participants_list = new StringBuilder();
|
||||||
for (int i=0;i<participants.size();i++) {
|
for (int i=0;i<participants.size();i++) {
|
||||||
Player pl = participants.get(i);
|
Player pl = participants.get(i);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user