Configurations now properly support lists of serializable objects, and ItemStack is properly serializable. Big thanks to GICodeWarrior for the PR. This fixes BUKKIT-425
By: Nathan Adams <dinnerbone@dinnerbone.com>
This commit is contained in:
@@ -7,6 +7,7 @@ import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.util.BlockVector;
|
||||
import org.bukkit.util.Vector;
|
||||
|
||||
@@ -21,6 +22,7 @@ public class ConfigurationSerialization {
|
||||
static {
|
||||
registerClass(Vector.class);
|
||||
registerClass(BlockVector.class);
|
||||
registerClass(ItemStack.class);
|
||||
}
|
||||
|
||||
protected ConfigurationSerialization(Class<? extends ConfigurationSerializable> clazz) {
|
||||
@@ -250,4 +252,4 @@ public class ConfigurationSerialization {
|
||||
|
||||
return clazz.getName();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user