Enable disarming already armed equipment
This commit is contained in:
BIN
data.mv.db
BIN
data.mv.db
Binary file not shown.
@@ -2,11 +2,14 @@ package com.bartlomiejpluta.demo.gui;
|
|||||||
|
|
||||||
import com.bartlomiejpluta.base.api.context.Context;
|
import com.bartlomiejpluta.base.api.context.Context;
|
||||||
import com.bartlomiejpluta.base.api.gui.*;
|
import com.bartlomiejpluta.base.api.gui.*;
|
||||||
|
import com.bartlomiejpluta.base.api.input.Key;
|
||||||
|
import com.bartlomiejpluta.base.api.input.KeyAction;
|
||||||
|
import com.bartlomiejpluta.base.api.input.KeyEvent;
|
||||||
|
import com.bartlomiejpluta.base.lib.gui.HOptionChoice;
|
||||||
import com.bartlomiejpluta.base.lib.gui.Label;
|
import com.bartlomiejpluta.base.lib.gui.Label;
|
||||||
import com.bartlomiejpluta.base.lib.gui.VGridOptionChoice;
|
import com.bartlomiejpluta.base.lib.gui.VGridOptionChoice;
|
||||||
import com.bartlomiejpluta.base.lib.gui.VOptionChoice;
|
import com.bartlomiejpluta.base.lib.gui.VOptionChoice;
|
||||||
import com.bartlomiejpluta.demo.entity.Player;
|
import com.bartlomiejpluta.demo.entity.Player;
|
||||||
import com.bartlomiejpluta.demo.runner.DemoRunner;
|
|
||||||
import com.bartlomiejpluta.demo.world.item.Item;
|
import com.bartlomiejpluta.demo.world.item.Item;
|
||||||
import com.bartlomiejpluta.demo.world.item.Useable;
|
import com.bartlomiejpluta.demo.world.item.Useable;
|
||||||
import com.bartlomiejpluta.demo.world.potion.Medicament;
|
import com.bartlomiejpluta.demo.world.potion.Medicament;
|
||||||
@@ -14,7 +17,7 @@ import com.bartlomiejpluta.demo.world.weapon.MeleeWeapon;
|
|||||||
import com.bartlomiejpluta.demo.world.weapon.RangedWeapon;
|
import com.bartlomiejpluta.demo.world.weapon.RangedWeapon;
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.function.Consumer;
|
import java.util.function.BiConsumer;
|
||||||
|
|
||||||
import static java.lang.String.format;
|
import static java.lang.String.format;
|
||||||
|
|
||||||
@@ -22,20 +25,26 @@ import static java.lang.String.format;
|
|||||||
public class EquipmentWindow extends DecoratedWindow {
|
public class EquipmentWindow extends DecoratedWindow {
|
||||||
private final Player player;
|
private final Player player;
|
||||||
|
|
||||||
private final Window eqItemMenuWindow;
|
private final Window popupMenuWindow;
|
||||||
private final Button useBtn;
|
private final Button useBtn;
|
||||||
private final Button dropBtn;
|
private final Button dropBtn;
|
||||||
private final Button cancelBtn;
|
private final Button cancelBtn;
|
||||||
private final VOptionChoice eqItemMenu;
|
private final VOptionChoice popupMenu;
|
||||||
|
|
||||||
@Ref("eq")
|
@Ref("layout")
|
||||||
private VGridOptionChoice eqGrid;
|
private HOptionChoice layout;
|
||||||
|
|
||||||
|
@Ref("equipment")
|
||||||
|
private VGridOptionChoice equipment;
|
||||||
|
|
||||||
|
@Ref("inventory")
|
||||||
|
private VGridOptionChoice inventory;
|
||||||
|
|
||||||
@Ref("weapon")
|
@Ref("weapon")
|
||||||
private ItemIconView weapon;
|
private ItemIconView weaponSlot;
|
||||||
|
|
||||||
@Ref("ammo")
|
@Ref("ammo")
|
||||||
private ItemIconView ammo;
|
private ItemIconView ammoSlot;
|
||||||
|
|
||||||
@Ref("item-name")
|
@Ref("item-name")
|
||||||
private Label nameLbl;
|
private Label nameLbl;
|
||||||
@@ -43,14 +52,26 @@ public class EquipmentWindow extends DecoratedWindow {
|
|||||||
@Ref("item-details")
|
@Ref("item-details")
|
||||||
private Label detailsLbl;
|
private Label detailsLbl;
|
||||||
|
|
||||||
|
|
||||||
public EquipmentWindow(Context context, GUI gui, Map<String, Component> refs) {
|
public EquipmentWindow(Context context, GUI gui, Map<String, Component> refs) {
|
||||||
super(context, gui, refs);
|
super(context, gui, refs);
|
||||||
this.player = context.getGlobal("player", Player.class);
|
this.player = context.getGlobal("player", Player.class);
|
||||||
this.eqItemMenuWindow = gui.inflateWindow(A.widgets.eq_item_menu.uid);
|
this.popupMenuWindow = gui.inflateWindow(A.widgets.eq_item_menu.uid);
|
||||||
this.eqItemMenu = eqItemMenuWindow.reference("menu", VOptionChoice.class);
|
this.popupMenu = popupMenuWindow.reference("menu", VOptionChoice.class);
|
||||||
this.useBtn = eqItemMenuWindow.reference("use", Button.class);
|
this.useBtn = popupMenuWindow.reference("use", Button.class);
|
||||||
this.dropBtn = eqItemMenuWindow.reference("drop", Button.class);
|
this.dropBtn = popupMenuWindow.reference("drop", Button.class);
|
||||||
this.cancelBtn = eqItemMenuWindow.reference("cancel", Button.class);
|
this.cancelBtn = popupMenuWindow.reference("cancel", Button.class);
|
||||||
|
|
||||||
|
addEventListener(KeyEvent.TYPE, this::handleKey);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void handleKey(KeyEvent event) {
|
||||||
|
if (event.getKey() == Key.KEY_TAB && event.getAction() == KeyAction.PRESS) {
|
||||||
|
layout.selectNext();
|
||||||
|
layout.focus();
|
||||||
|
updateItemDetails(((VGridOptionChoice) layout.getSelectedComponent()).getSelectedComponent());
|
||||||
|
event.consume();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -58,41 +79,53 @@ public class EquipmentWindow extends DecoratedWindow {
|
|||||||
super.onOpen(manager, args);
|
super.onOpen(manager, args);
|
||||||
|
|
||||||
cancelBtn.setAction(manager::close);
|
cancelBtn.setAction(manager::close);
|
||||||
eqGrid.setOnSelect(this::updateItemDetails);
|
inventory.setOnSelect(this::updateItemDetails);
|
||||||
|
equipment.setOnSelect(this::updateItemDetails);
|
||||||
|
|
||||||
updateEquipment();
|
updateEquipment();
|
||||||
|
|
||||||
eqGrid.select(0, 0);
|
layout.select(1);
|
||||||
eqGrid.focus();
|
layout.focus();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onClose(WindowManager manager) {
|
||||||
|
super.onClose(manager);
|
||||||
|
layout.blur();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void updateEquipment() {
|
private void updateEquipment() {
|
||||||
var i = 0;
|
var i = 0;
|
||||||
for (var child : eqGrid.getChildren()) {
|
for (var child : inventory.getChildren()) {
|
||||||
var slot = (ItemIconView) child;
|
var slot = (ItemIconView) child;
|
||||||
slot.setItem(player.getEquipmentItem(i++));
|
slot.setItem(player.getEquipmentItem(i++));
|
||||||
slot.setAction(handleClick(slot));
|
slot.setAction(this::handleInventoryClick);
|
||||||
}
|
}
|
||||||
|
|
||||||
weapon.setItem(player.getWeapon());
|
weaponSlot.setItem(player.getWeapon());
|
||||||
ammo.setItem(player.getAmmunition());
|
weaponSlot.setAction(handleEquipmentClick(() -> {
|
||||||
|
player.setWeapon(null);
|
||||||
|
updateEquipment();
|
||||||
|
manager.close();
|
||||||
|
}));
|
||||||
|
|
||||||
|
ammoSlot.setItem(player.getAmmunition());
|
||||||
|
ammoSlot.setAction(handleEquipmentClick(() -> {
|
||||||
|
player.setAmmunition(null);
|
||||||
|
updateEquipment();
|
||||||
|
manager.close();
|
||||||
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
private Consumer<Item> handleClick(ItemIconView slot) {
|
private BiConsumer<ItemIconView, Item> handleEquipmentClick(Runnable deequip) {
|
||||||
return item -> {
|
return (slot, item) -> {
|
||||||
useBtn.setText(getButtonTitle(item));
|
useBtn.setText("Disarm");
|
||||||
eqItemMenu.select(0);
|
popupMenu.select(0);
|
||||||
eqItemMenu.focus();
|
popupMenu.focus();
|
||||||
|
|
||||||
manager.open(eqItemMenuWindow);
|
manager.open(popupMenuWindow);
|
||||||
|
|
||||||
if (item instanceof Useable useable) {
|
useBtn.setAction(deequip);
|
||||||
useBtn.setAction(() -> {
|
|
||||||
useable.use(player);
|
|
||||||
updateEquipment();
|
|
||||||
manager.close();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
dropBtn.setAction(() -> {
|
dropBtn.setAction(() -> {
|
||||||
player.dropItemFromEquipment(item);
|
player.dropItemFromEquipment(item);
|
||||||
@@ -103,6 +136,29 @@ public class EquipmentWindow extends DecoratedWindow {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void handleInventoryClick(ItemIconView slot, Item item) {
|
||||||
|
useBtn.setText(getButtonTitle(item));
|
||||||
|
popupMenu.select(0);
|
||||||
|
popupMenu.focus();
|
||||||
|
|
||||||
|
manager.open(popupMenuWindow);
|
||||||
|
|
||||||
|
if (item instanceof Useable useable) {
|
||||||
|
useBtn.setAction(() -> {
|
||||||
|
useable.use(player);
|
||||||
|
updateEquipment();
|
||||||
|
manager.close();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
dropBtn.setAction(() -> {
|
||||||
|
player.dropItemFromEquipment(item);
|
||||||
|
slot.setItem(null);
|
||||||
|
updateItemDetails(slot);
|
||||||
|
manager.close();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
private void updateItemDetails(Component slot) {
|
private void updateItemDetails(Component slot) {
|
||||||
var item = ((ItemIconView) slot).getItem();
|
var item = ((ItemIconView) slot).getItem();
|
||||||
|
|
||||||
|
|||||||
@@ -1,16 +1,17 @@
|
|||||||
package com.bartlomiejpluta.demo.gui;
|
package com.bartlomiejpluta.demo.gui;
|
||||||
|
|
||||||
import com.bartlomiejpluta.base.api.context.Context;
|
import com.bartlomiejpluta.base.api.context.Context;
|
||||||
import com.bartlomiejpluta.base.api.gui.Component;
|
import com.bartlomiejpluta.base.api.gui.*;
|
||||||
import com.bartlomiejpluta.base.api.gui.GUI;
|
import com.bartlomiejpluta.base.lib.gui.VOptionChoice;
|
||||||
import com.bartlomiejpluta.base.api.gui.Inflatable;
|
|
||||||
import com.bartlomiejpluta.base.api.gui.Ref;
|
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
|
|
||||||
public class GameMenuWindow extends DecoratedWindow implements Inflatable {
|
public class GameMenuWindow extends DecoratedWindow {
|
||||||
|
|
||||||
|
@Ref("menu")
|
||||||
|
private VOptionChoice menu;
|
||||||
|
|
||||||
@Ref("resume_game")
|
@Ref("resume_game")
|
||||||
@Getter
|
@Getter
|
||||||
@@ -29,7 +30,9 @@ public class GameMenuWindow extends DecoratedWindow implements Inflatable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onInflate() {
|
public void onOpen(WindowManager manager, Object[] args) {
|
||||||
resumeGameBtn.focus();
|
super.onOpen(manager, args);
|
||||||
|
menu.select(0);
|
||||||
|
menu.focus();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2,15 +2,14 @@ package com.bartlomiejpluta.demo.gui;
|
|||||||
|
|
||||||
import A.fonts;
|
import A.fonts;
|
||||||
import com.bartlomiejpluta.base.api.context.Context;
|
import com.bartlomiejpluta.base.api.context.Context;
|
||||||
import com.bartlomiejpluta.base.api.gui.Color;
|
import com.bartlomiejpluta.base.api.gui.*;
|
||||||
import com.bartlomiejpluta.base.api.gui.Component;
|
|
||||||
import com.bartlomiejpluta.base.api.gui.GUI;
|
|
||||||
import com.bartlomiejpluta.base.api.icon.Icon;
|
import com.bartlomiejpluta.base.api.icon.Icon;
|
||||||
import com.bartlomiejpluta.base.api.input.Key;
|
import com.bartlomiejpluta.base.api.input.Key;
|
||||||
import com.bartlomiejpluta.base.api.input.KeyAction;
|
import com.bartlomiejpluta.base.api.input.KeyAction;
|
||||||
import com.bartlomiejpluta.base.api.input.KeyEvent;
|
import com.bartlomiejpluta.base.api.input.KeyEvent;
|
||||||
import com.bartlomiejpluta.base.api.screen.Screen;
|
import com.bartlomiejpluta.base.api.screen.Screen;
|
||||||
import com.bartlomiejpluta.base.lib.gui.IconView;
|
import com.bartlomiejpluta.base.lib.gui.IconView;
|
||||||
|
import com.bartlomiejpluta.demo.util.IconUtil;
|
||||||
import com.bartlomiejpluta.demo.world.item.Item;
|
import com.bartlomiejpluta.demo.world.item.Item;
|
||||||
import com.bartlomiejpluta.demo.world.item.ItemStack;
|
import com.bartlomiejpluta.demo.world.item.ItemStack;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
@@ -18,9 +17,10 @@ import lombok.NonNull;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.function.Consumer;
|
import java.util.function.BiConsumer;
|
||||||
|
|
||||||
public class ItemIconView extends IconView {
|
public class ItemIconView extends IconView {
|
||||||
|
private final GUI gui;
|
||||||
private final Color normal;
|
private final Color normal;
|
||||||
private final Color hover;
|
private final Color hover;
|
||||||
private final Color textColor;
|
private final Color textColor;
|
||||||
@@ -28,11 +28,18 @@ public class ItemIconView extends IconView {
|
|||||||
@Getter
|
@Getter
|
||||||
private Item item;
|
private Item item;
|
||||||
|
|
||||||
|
private IconSet placeholderIconSet;
|
||||||
|
private Paint placeholderIconPaint;
|
||||||
|
|
||||||
|
private int placeholderIconSetRow;
|
||||||
|
private int placeholderIconSetColumn;
|
||||||
|
|
||||||
@Setter
|
@Setter
|
||||||
private Consumer<Item> action;
|
private BiConsumer<ItemIconView, Item> action;
|
||||||
|
|
||||||
public ItemIconView(Context context, GUI gui, Map<String, Component> refs) {
|
public ItemIconView(Context context, GUI gui, Map<String, Component> refs) {
|
||||||
super(context, gui, refs);
|
super(context, gui, refs);
|
||||||
|
this.gui = gui;
|
||||||
this.normal = gui.createColor();
|
this.normal = gui.createColor();
|
||||||
this.hover = gui.createColor();
|
this.hover = gui.createColor();
|
||||||
this.textColor = gui.createColor();
|
this.textColor = gui.createColor();
|
||||||
@@ -71,10 +78,19 @@ public class ItemIconView extends IconView {
|
|||||||
throw new UnsupportedOperationException();
|
throw new UnsupportedOperationException();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Attribute("placeholder")
|
||||||
|
public void setPlaceholderIcon(String icon) {
|
||||||
|
this.placeholderIconPaint = gui.createPaint();
|
||||||
|
var parts = icon.split(",");
|
||||||
|
this.placeholderIconSet = gui.getIconSet(A.iconsets.get(parts[0]).uid);
|
||||||
|
this.placeholderIconSetRow = Integer.parseInt(parts[1]);
|
||||||
|
this.placeholderIconSetColumn = Integer.parseInt(parts[2]);
|
||||||
|
}
|
||||||
|
|
||||||
private void handleKeyEvent(KeyEvent event) {
|
private void handleKeyEvent(KeyEvent event) {
|
||||||
if (event.getKey() == Key.KEY_ENTER && event.getAction() == KeyAction.PRESS && item != null && action != null) {
|
if (event.getKey() == Key.KEY_ENTER && event.getAction() == KeyAction.PRESS && item != null && action != null) {
|
||||||
event.consume();
|
event.consume();
|
||||||
action.accept(item);
|
action.accept(this, item);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -96,6 +112,12 @@ public class ItemIconView extends IconView {
|
|||||||
gui.fill();
|
gui.fill();
|
||||||
gui.closePath();
|
gui.closePath();
|
||||||
|
|
||||||
|
if (item == null && placeholderIconSet != null) {
|
||||||
|
gui.icon(this.x, this.y, 2, 2, 0, 0.2f, placeholderIconSet, placeholderIconSetRow, placeholderIconSetColumn, placeholderIconPaint);
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
super.draw(screen, gui);
|
super.draw(screen, gui);
|
||||||
|
|
||||||
if (item != null && item instanceof ItemStack stack) {
|
if (item != null && item instanceof ItemStack stack) {
|
||||||
|
|||||||
@@ -46,6 +46,8 @@ public class LootWindow extends DecoratedWindow implements Inflatable {
|
|||||||
|
|
||||||
this.loot = (Item[]) args[0];
|
this.loot = (Item[]) args[0];
|
||||||
this.titleLbl.setText((String) args[1]);
|
this.titleLbl.setText((String) args[1]);
|
||||||
|
this.lootMenu.select(0, 0);
|
||||||
|
this.lootMenu.focus();
|
||||||
updateSlots();
|
updateSlots();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -57,7 +59,7 @@ public class LootWindow extends DecoratedWindow implements Inflatable {
|
|||||||
this.loot = null;
|
this.loot = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void handleClick(Item item) {
|
private void handleClick(ItemIconView slot, Item item) {
|
||||||
if (item == null) {
|
if (item == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -66,7 +68,7 @@ public class LootWindow extends DecoratedWindow implements Inflatable {
|
|||||||
for (int i = 0; i < Enemy.MAX_LOOT; i++) {
|
for (int i = 0; i < Enemy.MAX_LOOT; i++) {
|
||||||
if (loot[i] == item) {
|
if (loot[i] == item) {
|
||||||
loot[i] = null;
|
loot[i] = null;
|
||||||
slots[i].setItem(null);
|
slot.setItem(null);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,16 +1,13 @@
|
|||||||
package com.bartlomiejpluta.demo.gui;
|
package com.bartlomiejpluta.demo.gui;
|
||||||
|
|
||||||
import com.bartlomiejpluta.base.api.context.Context;
|
import com.bartlomiejpluta.base.api.context.Context;
|
||||||
import com.bartlomiejpluta.base.api.gui.Component;
|
import com.bartlomiejpluta.base.api.gui.*;
|
||||||
import com.bartlomiejpluta.base.api.gui.GUI;
|
|
||||||
import com.bartlomiejpluta.base.api.gui.Inflatable;
|
|
||||||
import com.bartlomiejpluta.base.api.gui.Ref;
|
|
||||||
import com.bartlomiejpluta.base.lib.gui.VOptionChoice;
|
import com.bartlomiejpluta.base.lib.gui.VOptionChoice;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
public class StartMenuWindow extends DecoratedWindow implements Inflatable {
|
public class StartMenuWindow extends DecoratedWindow {
|
||||||
|
|
||||||
@Ref("new_game")
|
@Ref("new_game")
|
||||||
@Getter
|
@Getter
|
||||||
@@ -28,7 +25,8 @@ public class StartMenuWindow extends DecoratedWindow implements Inflatable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onInflate() {
|
public void onOpen(WindowManager manager, Object[] args) {
|
||||||
|
super.onOpen(manager, args);
|
||||||
menu.select(0);
|
menu.select(0);
|
||||||
menu.focus();
|
menu.focus();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -39,6 +39,6 @@ public class Ammunition extends StackableItem implements Useable {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String usageName() {
|
public String usageName() {
|
||||||
return "Equip";
|
return "Arm";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -65,6 +65,6 @@ public class MeleeWeapon extends BaseItem implements Weapon {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String usageName() {
|
public String usageName() {
|
||||||
return "Equip";
|
return "Arm";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -97,6 +97,6 @@ public class RangedWeapon extends BaseItem implements Weapon {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String usageName() {
|
public String usageName() {
|
||||||
return "Equip";
|
return "Arm";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -20,7 +20,7 @@
|
|||||||
fontSize="30f">Game Menu
|
fontSize="30f">Game Menu
|
||||||
</base:Label>
|
</base:Label>
|
||||||
|
|
||||||
<base:VOptionChoice width="relative">
|
<base:VOptionChoice ref="menu" width="relative">
|
||||||
<demo:Button
|
<demo:Button
|
||||||
ref="resume_game"
|
ref="resume_game"
|
||||||
font="A.fonts.roboto_regular.uid"
|
font="A.fonts.roboto_regular.uid"
|
||||||
|
|||||||
@@ -12,38 +12,40 @@
|
|||||||
<base:Label
|
<base:Label
|
||||||
font="A.fonts.roboto_regular.uid"
|
font="A.fonts.roboto_regular.uid"
|
||||||
width="relative"
|
width="relative"
|
||||||
alignment="top|center"
|
alignment="top|left"
|
||||||
red="1f"
|
red="1f"
|
||||||
green="1f"
|
green="1f"
|
||||||
blue="1f"
|
blue="1f"
|
||||||
alpha="0.5f"
|
alpha="0.5f"
|
||||||
fontSize="30f">Equipment
|
fontSize="30f">Inventory & Equipment
|
||||||
</base:Label>
|
</base:Label>
|
||||||
|
|
||||||
<base:HLayout>
|
<base:HLayout margin="0f" padding="0f">
|
||||||
<base:VGridLayout columns="2" padding="20f" width="250f">
|
<base:HOptionChoice ref="layout">
|
||||||
<demo:ItemIconView ref="weapon" margin="5f"/>
|
<base:VGridOptionChoice ref="equipment" columns="2" width="auto">
|
||||||
<demo:ItemIconView ref="ammo" margin="5f"/>
|
<demo:ItemIconView ref="weapon" placeholder="Generic,5,10" margin="5f"/>
|
||||||
</base:VGridLayout>
|
<demo:ItemIconView ref="ammo" placeholder="Generic,8,10" margin="5f"/>
|
||||||
|
</base:VGridOptionChoice>
|
||||||
|
|
||||||
<base:VGridOptionChoice ref="eq" columns="4" width="auto" height="auto">
|
<base:VGridOptionChoice ref="inventory" columns="4" width="auto" height="auto">
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
<demo:ItemIconView margin="5f"/>
|
<demo:ItemIconView margin="5f"/>
|
||||||
</base:VGridOptionChoice>
|
</base:VGridOptionChoice>
|
||||||
|
</base:HOptionChoice>
|
||||||
|
|
||||||
<base:VLayout height="relative" padding="20f" width="250f">
|
<base:VLayout height="relative" padding="20f" width="250f">
|
||||||
<base:Label ref="item-name"
|
<base:Label ref="item-name"
|
||||||
@@ -63,7 +65,6 @@
|
|||||||
margin="5f"/>
|
margin="5f"/>
|
||||||
|
|
||||||
</base:VLayout>
|
</base:VLayout>
|
||||||
|
|
||||||
</base:HLayout>
|
</base:HLayout>
|
||||||
</base:VLayout>
|
</base:VLayout>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user