1
0
mirror of https://github.com/Zrips/Jobs.git synced 2024-11-29 14:05:25 +01:00

Lets simplify it even more

Version increment for future release
This commit is contained in:
Zrips 2018-12-25 12:58:17 +02:00
parent edb943be11
commit d9a48b5b97
2 changed files with 12 additions and 11 deletions

View File

@ -449,27 +449,28 @@ public class Placeholder {
if (values.isEmpty())
return "";
Job j = getJobFromValue(values.get(0));
if (j == null)
return "";
// Global placeholders by jobname
switch (placeHolder) {
case name_$1:
return j == null ? "" : j.getName();
return j.getName();
case shortname_$1:
return j == null ? "" : j.getShortName();
return j.getShortName();
case chatcolor_$1:
return j == null ? "" : j.getChatColor().toString();
return j.getChatColor().toString();
case description_$1:
return j == null ? "" : j.getDescription();
return j.getDescription();
case maxdailyq_$1:
return j == null ? "" : String.valueOf(j.getMaxDailyQuests());
return String.valueOf(j.getMaxDailyQuests());
case maxlvl_$1:
return j == null ? "" : String.valueOf(j.getMaxLevel());
return String.valueOf(j.getMaxLevel());
case maxviplvl_$1:
return j == null ? "" : String.valueOf(j.getVipMaxLevel());
return String.valueOf(j.getVipMaxLevel());
case totalplayers_$1:
return j == null ? "" : String.valueOf(j.getTotalPlayers());
return String.valueOf(j.getTotalPlayers());
case maxslots_$1:
return j == null ? "" : String.valueOf(j.getMaxSlots());
return String.valueOf(j.getMaxSlots());
default:
break;
}

View File

@ -1,7 +1,7 @@
name: Jobs
description: Jobs Plugin for the BukkitAPI
main: com.gamingmesh.jobs.Jobs
version: 4.9.4
version: 4.9.5
api-version: 1.13
website: https://www.spigotmc.org/resources/4216/
author: phrstbrn