mirror of
https://github.com/Zrips/Jobs.git
synced 2025-01-06 16:27:59 +01:00
Fixed issue when used 1.12 and lower versions then some materials not work correctly (#550)
This commit is contained in:
parent
f0ce3fcdc4
commit
0057bd3aba
@ -1,19 +1,11 @@
|
|||||||
package com.gamingmesh.jobs.commands.list;
|
package com.gamingmesh.jobs.commands.list;
|
||||||
|
|
||||||
import java.lang.reflect.InvocationTargetException;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import org.bukkit.block.Block;
|
|
||||||
import org.bukkit.command.CommandSender;
|
|
||||||
import org.bukkit.enchantments.Enchantment;
|
|
||||||
import org.bukkit.entity.EntityType;
|
|
||||||
import org.bukkit.entity.Player;
|
|
||||||
import org.bukkit.inventory.ItemStack;
|
|
||||||
|
|
||||||
import com.gamingmesh.jobs.Jobs;
|
|
||||||
import com.gamingmesh.jobs.CMILib.ItemManager.CMIEntityType;
|
import com.gamingmesh.jobs.CMILib.ItemManager.CMIEntityType;
|
||||||
import com.gamingmesh.jobs.CMILib.ItemManager.CMIMaterial;
|
import com.gamingmesh.jobs.CMILib.ItemManager.CMIMaterial;
|
||||||
import com.gamingmesh.jobs.CMILib.ItemReflection;
|
import com.gamingmesh.jobs.CMILib.ItemReflection;
|
||||||
|
import com.gamingmesh.jobs.CMILib.RawMessage;
|
||||||
|
import com.gamingmesh.jobs.CMILib.VersionChecker.Version;
|
||||||
|
import com.gamingmesh.jobs.Jobs;
|
||||||
import com.gamingmesh.jobs.commands.Cmd;
|
import com.gamingmesh.jobs.commands.Cmd;
|
||||||
import com.gamingmesh.jobs.commands.JobCommand;
|
import com.gamingmesh.jobs.commands.JobCommand;
|
||||||
import com.gamingmesh.jobs.container.ActionType;
|
import com.gamingmesh.jobs.container.ActionType;
|
||||||
@ -22,9 +14,16 @@ import com.gamingmesh.jobs.container.Job;
|
|||||||
import com.gamingmesh.jobs.container.JobInfo;
|
import com.gamingmesh.jobs.container.JobInfo;
|
||||||
import com.gamingmesh.jobs.stuff.ChatColor;
|
import com.gamingmesh.jobs.stuff.ChatColor;
|
||||||
import com.gamingmesh.jobs.stuff.PageInfo;
|
import com.gamingmesh.jobs.stuff.PageInfo;
|
||||||
import com.gamingmesh.jobs.CMILib.RawMessage;
|
|
||||||
import com.gamingmesh.jobs.stuff.Util;
|
import com.gamingmesh.jobs.stuff.Util;
|
||||||
import com.gamingmesh.jobs.CMILib.VersionChecker.Version;
|
import org.bukkit.block.Block;
|
||||||
|
import org.bukkit.command.CommandSender;
|
||||||
|
import org.bukkit.enchantments.Enchantment;
|
||||||
|
import org.bukkit.entity.EntityType;
|
||||||
|
import org.bukkit.entity.Player;
|
||||||
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
|
import java.lang.reflect.InvocationTargetException;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
public class editjobs implements Cmd {
|
public class editjobs implements Cmd {
|
||||||
|
|
||||||
@ -485,7 +484,7 @@ public class editjobs implements Cmd {
|
|||||||
material = CMIMaterial.REDSTONE_ORE;
|
material = CMIMaterial.REDSTONE_ORE;
|
||||||
}
|
}
|
||||||
id = material.getId();
|
id = material.getId();
|
||||||
type = material.toString();
|
type = material.getMaterial().toString();
|
||||||
} else if (actionT == ActionType.KILL || actionT == ActionType.TAME || actionT == ActionType.BREED || actionT == ActionType.MILK) {
|
} else if (actionT == ActionType.KILL || actionT == ActionType.TAME || actionT == ActionType.BREED || actionT == ActionType.MILK) {
|
||||||
|
|
||||||
// check entities
|
// check entities
|
||||||
|
@ -401,7 +401,7 @@ public class editquests implements Cmd {
|
|||||||
material = CMIMaterial.REDSTONE_ORE;
|
material = CMIMaterial.REDSTONE_ORE;
|
||||||
}
|
}
|
||||||
id = material.getId();
|
id = material.getId();
|
||||||
type = material.toString();
|
type = material.getMaterial().toString();
|
||||||
} else if (actionT == ActionType.KILL || actionT == ActionType.TAME || actionT == ActionType.BREED || actionT == ActionType.MILK) {
|
} else if (actionT == ActionType.KILL || actionT == ActionType.TAME || actionT == ActionType.BREED || actionT == ActionType.MILK) {
|
||||||
|
|
||||||
// check entities
|
// check entities
|
||||||
|
@ -18,17 +18,15 @@
|
|||||||
|
|
||||||
package com.gamingmesh.jobs.config;
|
package com.gamingmesh.jobs.config;
|
||||||
|
|
||||||
import java.io.File;
|
import com.gamingmesh.jobs.CMILib.CMIEnchantment;
|
||||||
import java.io.FileInputStream;
|
import com.gamingmesh.jobs.CMILib.ItemManager.CMIEntityType;
|
||||||
import java.io.FileNotFoundException;
|
import com.gamingmesh.jobs.CMILib.ItemManager.CMIMaterial;
|
||||||
import java.io.IOException;
|
import com.gamingmesh.jobs.CMILib.VersionChecker.Version;
|
||||||
import java.io.InputStreamReader;
|
import com.gamingmesh.jobs.ItemBoostManager;
|
||||||
import java.io.UnsupportedEncodingException;
|
import com.gamingmesh.jobs.Jobs;
|
||||||
import java.util.ArrayList;
|
import com.gamingmesh.jobs.container.*;
|
||||||
import java.util.HashMap;
|
import com.gamingmesh.jobs.resources.jfep.Parser;
|
||||||
import java.util.List;
|
import com.gamingmesh.jobs.stuff.ChatColor;
|
||||||
import java.util.UUID;
|
|
||||||
|
|
||||||
import org.apache.commons.lang.StringEscapeUtils;
|
import org.apache.commons.lang.StringEscapeUtils;
|
||||||
import org.bukkit.Bukkit;
|
import org.bukkit.Bukkit;
|
||||||
import org.bukkit.OfflinePlayer;
|
import org.bukkit.OfflinePlayer;
|
||||||
@ -40,27 +38,11 @@ import org.bukkit.inventory.ItemStack;
|
|||||||
import org.bukkit.inventory.meta.EnchantmentStorageMeta;
|
import org.bukkit.inventory.meta.EnchantmentStorageMeta;
|
||||||
import org.bukkit.inventory.meta.SkullMeta;
|
import org.bukkit.inventory.meta.SkullMeta;
|
||||||
|
|
||||||
import com.gamingmesh.jobs.ItemBoostManager;
|
import java.io.*;
|
||||||
import com.gamingmesh.jobs.Jobs;
|
import java.util.ArrayList;
|
||||||
import com.gamingmesh.jobs.CMILib.CMIEnchantment;
|
import java.util.HashMap;
|
||||||
import com.gamingmesh.jobs.CMILib.ItemManager.CMIEntityType;
|
import java.util.List;
|
||||||
import com.gamingmesh.jobs.CMILib.ItemManager.CMIMaterial;
|
import java.util.UUID;
|
||||||
import com.gamingmesh.jobs.container.ActionType;
|
|
||||||
import com.gamingmesh.jobs.container.BoostMultiplier;
|
|
||||||
import com.gamingmesh.jobs.container.CurrencyType;
|
|
||||||
import com.gamingmesh.jobs.container.DisplayMethod;
|
|
||||||
import com.gamingmesh.jobs.container.Job;
|
|
||||||
import com.gamingmesh.jobs.container.JobCommands;
|
|
||||||
import com.gamingmesh.jobs.container.JobConditions;
|
|
||||||
import com.gamingmesh.jobs.container.JobInfo;
|
|
||||||
import com.gamingmesh.jobs.container.JobItems;
|
|
||||||
import com.gamingmesh.jobs.container.JobLimitedItems;
|
|
||||||
import com.gamingmesh.jobs.container.JobPermission;
|
|
||||||
import com.gamingmesh.jobs.container.Quest;
|
|
||||||
import com.gamingmesh.jobs.container.QuestObjective;
|
|
||||||
import com.gamingmesh.jobs.resources.jfep.Parser;
|
|
||||||
import com.gamingmesh.jobs.stuff.ChatColor;
|
|
||||||
import com.gamingmesh.jobs.CMILib.VersionChecker.Version;
|
|
||||||
|
|
||||||
public class ConfigManager {
|
public class ConfigManager {
|
||||||
|
|
||||||
@ -303,7 +285,7 @@ public class ConfigManager {
|
|||||||
}
|
}
|
||||||
// END HACK
|
// END HACK
|
||||||
|
|
||||||
type = material.toString();
|
type = material.getMaterial().toString();
|
||||||
id = material.getId();
|
id = material.getId();
|
||||||
} else if (actionType == ActionType.KILL || actionType == ActionType.TAME || actionType == ActionType.BREED || actionType == ActionType.MILK) {
|
} else if (actionType == ActionType.KILL || actionType == ActionType.TAME || actionType == ActionType.BREED || actionType == ActionType.MILK) {
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user