use of eidolons.libgdx.gui.panels.dc.inventory.datasource.EquipDataSource in project Eidolons by IDemiurge.
the class RingSlotsPanel method afterUpdateAct.
// @Override
// public void clear() {
//
// }
@Override
public void afterUpdateAct(float delta) {
if (getUserObject() == null)
return;
clear();
super.afterUpdateAct(delta);
final List<InventoryValueContainer> rings = ((EquipDataSource) getUserObject()).rings();
int a = 0;
for (int i = 0; i < 8; i++) {
if (i % 2 == (left ? 1 : 0)) {
continue;
}
a++;
ValueContainer valueContainer = rings.get(i);
if (valueContainer == null) {
valueContainer = new ValueContainer(getOrCreateR(CELL_TYPE.RING.getSlotImagePath()));
}
add(valueContainer).expand(0, 0);
if ((a) % 2 == 0) {
row();
}
}
}
use of eidolons.libgdx.gui.panels.dc.inventory.datasource.EquipDataSource in project Eidolons by IDemiurge.
the class InventoryPanel method updateAct.
@Override
public void updateAct(float delta) {
if (getUserObject() == null)
return;
clear();
super.updateAct(delta);
final EquipDataSource source = (EquipDataSource) getUserObject();
mainWeapon.setActor(source.mainWeapon());
offWeapon.setActor(source.offWeapon());
avatarPanel.setActor(source.avatar());
armorSlot.setActor(source.armor());
amuletSlot.setActor(source.amulet());
}
Aggregations