public UIWeaponSlot(Inventory.WeaponSlot slot, List <Weapon> availableWeapons, Texture2D buttonIcon, Rectangle frame, UIButtonStyle style) : base("", frame, style, null) { onPress = slot_Clicked; this.slot = slot; this.buttonIcon = buttonIcon; this.availableWeapons = availableWeapons; }
public void SelectWeapon(Inventory.WeaponSlot slot, Inventory.WeaponSlot otherSlot) { if (otherSlot.weapon == weapon) { otherSlot.weapon = slot.weapon; } slot.weapon = weapon; }
public UIWeaponButton(Weapon weapon, Inventory.WeaponSlot lmbSlot, Inventory.WeaponSlot rmbSlot, Rectangle frame, UIButtonStyle style) : base("", frame, style, null) { this.weapon = weapon; this.lmbSlot = lmbSlot; this.rmbSlot = rmbSlot; }