Merge branch 'master' of ssh://184.154.0.242:7999/min/Mineplex
This commit is contained in:
commit
f28d83cbd7
@ -132,8 +132,8 @@ public class BonusManager extends MiniClientPlugin<BonusClientData> implements I
|
|||||||
private int _visualTick;
|
private int _visualTick;
|
||||||
|
|
||||||
// Streak
|
// Streak
|
||||||
private StreakRecord _dailyStreak;
|
// private StreakRecord _dailyStreak;
|
||||||
private StreakRecord _voteStreak;
|
// private StreakRecord _voteStreak;
|
||||||
|
|
||||||
private ArrayList<String> _voteList;
|
private ArrayList<String> _voteList;
|
||||||
|
|
||||||
@ -220,7 +220,7 @@ public class BonusManager extends MiniClientPlugin<BonusClientData> implements I
|
|||||||
new VoteHandler(this));
|
new VoteHandler(this));
|
||||||
|
|
||||||
updateOffSet();
|
updateOffSet();
|
||||||
updateStreakRecord();
|
// updateStreakRecord();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -240,45 +240,45 @@ public class BonusManager extends MiniClientPlugin<BonusClientData> implements I
|
|||||||
updateOffSet();
|
updateOffSet();
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler
|
// @EventHandler
|
||||||
public void updateStreak(UpdateEvent event)
|
// public void updateStreak(UpdateEvent event)
|
||||||
{
|
// {
|
||||||
if (event.getType() != UpdateType.MIN_16)
|
// if (event.getType() != UpdateType.MIN_16)
|
||||||
return;
|
// return;
|
||||||
|
//
|
||||||
updateStreakRecord();
|
// updateStreakRecord();
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
private void updateStreakRecord()
|
// private void updateStreakRecord()
|
||||||
{
|
// {
|
||||||
_repository.getDailyStreakRecord(new Callback<StreakRecord>()
|
// _repository.getDailyStreakRecord(new Callback<StreakRecord>()
|
||||||
{
|
// {
|
||||||
@Override
|
// @Override
|
||||||
public void run(StreakRecord data)
|
// public void run(StreakRecord data)
|
||||||
{
|
// {
|
||||||
_dailyStreak = data;
|
// _dailyStreak = data;
|
||||||
}
|
// }
|
||||||
});
|
// });
|
||||||
|
//
|
||||||
_repository.getVoteStreakRecord(new Callback<StreakRecord>()
|
// _repository.getVoteStreakRecord(new Callback<StreakRecord>()
|
||||||
{
|
// {
|
||||||
@Override
|
// @Override
|
||||||
public void run(StreakRecord data)
|
// public void run(StreakRecord data)
|
||||||
{
|
// {
|
||||||
_voteStreak = data;
|
// _voteStreak = data;
|
||||||
}
|
// }
|
||||||
});
|
// });
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public StreakRecord getDailyStreak()
|
// public StreakRecord getDailyStreak()
|
||||||
{
|
// {
|
||||||
return _dailyStreak;
|
// return _dailyStreak;
|
||||||
}
|
// }
|
||||||
|
//
|
||||||
public StreakRecord getVoteStreak()
|
// public StreakRecord getVoteStreak()
|
||||||
{
|
// {
|
||||||
return _voteStreak;
|
// return _voteStreak;
|
||||||
}
|
// }
|
||||||
|
|
||||||
public void handleVote(final Player player, final int gemsReceived)
|
public void handleVote(final Player player, final int gemsReceived)
|
||||||
{
|
{
|
||||||
|
@ -160,13 +160,13 @@ public class DailyBonusButton implements GuiItem, Listener
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
StreakRecord streakRecord = _bonusManager.getDailyStreak();
|
// StreakRecord streakRecord = _bonusManager.getDailyStreak();
|
||||||
if (streakRecord != null)
|
// if (streakRecord != null)
|
||||||
{
|
// {
|
||||||
lore.add(" ");
|
// lore.add(" ");
|
||||||
lore.add(C.cYellow + "Record: " + C.cWhite + streakRecord.getPlayerName());
|
// lore.add(C.cYellow + "Record: " + C.cWhite + streakRecord.getPlayerName());
|
||||||
lore.add(C.cYellow + "Streak: " + C.cWhite + streakRecord.getStreak());
|
// lore.add(C.cYellow + "Streak: " + C.cWhite + streakRecord.getStreak());
|
||||||
}
|
// }
|
||||||
|
|
||||||
|
|
||||||
_item = new ShopItem(material, itemName, lore.toArray(new String[0]), 1, false, false);
|
_item = new ShopItem(material, itemName, lore.toArray(new String[0]), 1, false, false);
|
||||||
|
@ -145,13 +145,13 @@ public class VoteButton implements GuiItem, Listener {
|
|||||||
lore.add(" ");
|
lore.add(" ");
|
||||||
lore.add(C.cYellow + "Highest Streak: " + C.cWhite + client.getMaxVoteStreak());
|
lore.add(C.cYellow + "Highest Streak: " + C.cWhite + client.getMaxVoteStreak());
|
||||||
|
|
||||||
StreakRecord streakRecord = _bonusManager.getVoteStreak();
|
// StreakRecord streakRecord = _bonusManager.getVoteStreak();
|
||||||
if (streakRecord != null)
|
// if (streakRecord != null)
|
||||||
{
|
// {
|
||||||
lore.add(" ");
|
// lore.add(" ");
|
||||||
lore.add(C.cYellow + "Record: " + C.cWhite + streakRecord.getPlayerName());
|
// lore.add(C.cYellow + "Record: " + C.cWhite + streakRecord.getPlayerName());
|
||||||
lore.add(C.cYellow + "Streak: " + C.cWhite + streakRecord.getStreak());
|
// lore.add(C.cYellow + "Streak: " + C.cWhite + streakRecord.getStreak());
|
||||||
}
|
// }
|
||||||
|
|
||||||
_item = new ShopItem(material, itemName, lore.toArray(new String[0]), 1, false, false);
|
_item = new ShopItem(material, itemName, lore.toArray(new String[0]), 1, false, false);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user