mirror of
https://github.com/Zrips/Jobs.git
synced 2024-12-31 21:37:57 +01:00
do same stuff for leaveall as for regular leave
This commit is contained in:
parent
7feced2529
commit
5414133dc3
@ -812,9 +812,7 @@ public class Jobs {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
||||
for (JobProgression prog : progression) {
|
||||
|
||||
int level = prog.getLevel();
|
||||
JobInfo jobinfo = prog.getJob().getJobInfo(info, level);
|
||||
|
||||
|
@ -308,20 +308,10 @@ public class PlayerManager {
|
||||
* @param jPlayer
|
||||
*/
|
||||
public void leaveAllJobs(JobsPlayer jPlayer) {
|
||||
// synchronized (jPlayer.saveLock) {
|
||||
for (JobProgression job : jPlayer.getJobProgression()) {
|
||||
Jobs.getJobsDAO().quitJob(jPlayer, job.getJob());
|
||||
Jobs.getJobsDAO().recordToArchive(jPlayer, job.getJob());
|
||||
PerformCommands.PerformCommandsOnLeave(jPlayer, job.getJob());
|
||||
Jobs.leaveSlot(job.getJob());
|
||||
|
||||
Jobs.getSignUtil().SignUpdate(job.getJob().getName());
|
||||
Jobs.getSignUtil().SignUpdate("gtoplist");
|
||||
job.getJob().updateTotalPlayers();
|
||||
leaveJob(jPlayer, job.getJob());
|
||||
}
|
||||
|
||||
jPlayer.leaveAllJobs();
|
||||
// }
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user