use of simple.brainsynder.api.ItemBuilder in project SimplePets by brainsynder-Dev.
the class Hang method getItem.
@Override
public ItemBuilder getItem() {
ItemBuilder item = type.getDataItemByName("hang", 0);
if (entityPet instanceof IEntityBatPet) {
IEntityBatPet var = (IEntityBatPet) entityPet;
item.withName(item.getName().replace("%value%", String.valueOf(var.isHanging())));
}
return item;
}
use of simple.brainsynder.api.ItemBuilder in project SimplePets by brainsynder-Dev.
the class Hang method getDefaultItems.
@Override
public List<ItemBuilder> getDefaultItems() {
ItemBuilder item = new ItemBuilder(Material.FEATHER);
item.withName("&6Hanging: &e%value%");
return new ArrayList<>(Collections.singleton(item));
}
use of simple.brainsynder.api.ItemBuilder in project SimplePets by brainsynder-Dev.
the class HorseColor method getItem.
@Override
public ItemBuilder getItem() {
ItemBuilder item = null;
if (entityPet instanceof IEntityHorsePet) {
IEntityHorsePet var = (IEntityHorsePet) entityPet;
HorseColorType typeID = HorseColorType.WHITE;
if (var.getColor() != null) {
typeID = var.getColor();
}
switch(typeID) {
case BLACK:
item = type.getDataItemByName("horsecolor", 0);
break;
case CHESTNUT:
item = type.getDataItemByName("horsecolor", 1);
break;
case CREAMY:
item = type.getDataItemByName("horsecolor", 2);
break;
case BROWN:
item = type.getDataItemByName("horsecolor", 3);
break;
case DARKBROWN:
item = type.getDataItemByName("horsecolor", 4);
break;
case GRAY:
item = type.getDataItemByName("horsecolor", 5);
break;
case WHITE:
item = type.getDataItemByName("horsecolor", 6);
break;
}
}
return item;
}
use of simple.brainsynder.api.ItemBuilder in project SimplePets by brainsynder-Dev.
the class HorseColor method getDefaultItems.
@Override
public List<ItemBuilder> getDefaultItems() {
List<ItemBuilder> items = new ArrayList<>();
ItemBuilder item = ItemBuilder.getColored(simple.brainsynder.utils.MatType.WOOL, 15);
item.withName("&6Black");
items.add(item.clone());
item = ItemBuilder.getColored(simple.brainsynder.utils.MatType.STAINED_CLAY, 8);
item.withName("&6Chestnut");
items.add(item.clone());
item = ItemBuilder.getColored(simple.brainsynder.utils.MatType.WOOL, 4);
item.withName("&6Creamy");
items.add(item.clone());
item = ItemBuilder.getColored(simple.brainsynder.utils.MatType.WOOL, 12);
item.withName("&6Brown");
items.add(item.clone());
item = ItemBuilder.getColored(simple.brainsynder.utils.MatType.STAINED_CLAY, 7);
item.withName("&6Dark Brown");
items.add(item.clone());
item = ItemBuilder.getColored(simple.brainsynder.utils.MatType.WOOL, 7);
item.withName("&6Gray");
items.add(item.clone());
item = ItemBuilder.getColored(simple.brainsynder.utils.MatType.WOOL, 0);
item.withName("&6White");
items.add(item.clone());
return items;
}
use of simple.brainsynder.api.ItemBuilder in project SimplePets by brainsynder-Dev.
the class Johnny method getDefaultItems.
@Override
public List<ItemBuilder> getDefaultItems() {
ItemBuilder item = new ItemBuilder(Material.IRON_AXE);
item.withName("&6Johnny: &e%value%");
return new ArrayList<>(Collections.singleton(item));
}
Aggregations