public InventoryWindow(GraphicsDevice graphics, Texture2D view, InventoryInterface inventory) { this.view = view; //Draw Rectangles all cover entire screen this.drawDest = new Rectangle(0, 0, view.Width, view.Height); this.drawSource = drawDest; this.inventory = inventory; loadPockets(); batch = new SpriteBatch(graphics); showing = false; }
protected override void Awake() { base.Awake(); combatantHudLeft = GetComponentsInChildren <CombatantHUD>()[0]; combatantHudRight = GetComponentsInChildren <CombatantHUD>()[1]; _roundTransitionText = GetComponentInChildren <LayeredText>(); _roundTransitionAnimator = _roundTransitionText.GetComponent <Animator>(); inventoryInterface = GetComponentInChildren <InventoryInterface>(true); commandInterface = GetComponentInChildren <CommandInterface>(true); queueInterface = GetComponentInChildren <CommandQueueInterface>(); lootInterface = GetComponentInChildren <LootInterface>(); itemDescriptionPanel = GetComponentInChildren <ItemDescriptionPanel>(); inputInfoInterface = GetComponentInChildren <InputInfoInterface>(); inventoryInterface.Show(false); lootInterface.Show(false); itemDescriptionPanel.gameObject.SetActive(false); _cameraController = FindObjectOfType <CameraController>(); _gameOverOverlay = GetComponentInChildren <GameOverOverlay>(true); }
public void RegisterObserver(InventoryInterface inventoryInterface) { _InventoryInterface.Add(inventoryInterface); }
protected override void LoadContent() { Rectangle dicks = new Rectangle(); Vector2 ass; dicks.X = (int)ass.X; dicks.Y = (int)ass.Y; test[0] = new Item("test", Content.Load<Texture2D>("testimg")); // Create a new SpriteBatch, which can be used to draw textures. loader = new Loader(Content, GraphicsDevice); font = Content.Load<SpriteFont>("cheese serif"); mainguy = loader.getSpriteExt(); dialogueHandler = new DialogueHandler(Content.Load<Texture2D>("bubbles"), GraphicsDevice, font, mainguy); inventory = new Inventory(mainguy, test); uis = new UIManager(loader.getInventoryWindow(inventory)); playerActions = new PlayerActions(mainguy, dialogueHandler); levels = loader.getLevelExt(mainguy, playerActions); backgroundMusic = Content.Load<Song>("test"); currentLevel = levels[loader.getLevelIntExt()]; currentLevel.setLoc(loader.getSaveCoords()); playerActions.level = currentLevel; area = loader.getAreaExt(); MediaPlayer.IsRepeating = true; MediaPlayer.Play(backgroundMusic); // TODO: use this.Content to load your game content here }
private void ClearControls() { _billData = new BillData(); _inventoryData = new InventoryData(); _client = null; _remissionDetail = new List<RemissionDetailModel>(); _remissionSaveModel = new RemissionSaveModel(); _remission = new RemissionModel { Id = Guid.NewGuid(), RemissionNumber = _remissionData.GetRemissionNumber(), DateEvent = DateTime.Now }; lblNumeroRemision.Text = _remission.RemissionNumber.ToString().PadLeft(8, '0'); lblGranTotal.Text = "$0,00"; txtSubTotal.Text = string.Format("{0:0.00}", 0.00); txtDescuentoFinal.Text = string.Format("{0:0.00}", 0.00); txtDescuentoCliente.Text = string.Format("{0:0.00}", 0.00); dtgDetalleRemision.DataSource = new List<RemissionDetailModel>(); txtIdentificacionCliente.Text = string.Empty; txtNombreCliente.Text = string.Empty; txtDireccion.Text = string.Empty; txtTelefono.Text = string.Empty; txtEmail.Text = string.Empty; txtCodigoBarras.Text = string.Empty; txtNombreProducto.Text = string.Empty; lstProducto.DataSource = new List<InventoryModel>(); btnRemitir.Enabled = false; }
void Awake() { _inventoryInterface = GetComponent <InventoryInterface>(); }
private void ClearControls() { _billData = new BillData(); _inventoryData = new InventoryData(); _client = null; _billDetail = new List<BillDetailModel>(); _bill = new BillModel(); _billTaxes = new List<BillTaxesModel>(); _billSaveModel = new BillSaveModel(); _bill = new BillModel { Id = Guid.NewGuid(), BillNumber = _billData.GetBillNumber(), DateEvent = DateTime.Now }; lblNumeroFactura.Text = _bill.BillNumber.ToString().PadLeft(8, '0'); _billTaxes = _billData.GetBillTaxes(); _billTaxes.ForEach(x => x.IdBill = _bill.Id); dtgImpuestos.DataSource = _billTaxes; lblGranTotal.Text = "$0,00"; txtSubTotal.Text = string.Format("{0:0.00}", 0.00); txtDescuentoFinal.Text = string.Format("{0:0.00}", 0.00); txtDescuentoCliente.Text = string.Format("{0:0.00}", 0.00); dtgDetalleFactura.DataSource = new List<BillDetailModel>(); txtIdentificacionCliente.Text = string.Empty; txtNombreCliente.Text = string.Empty; txtDireccion.Text = string.Empty; txtTelefono.Text = string.Empty; txtEmail.Text = string.Empty; txtCodigoBarras.Text = string.Empty; txtNombreProducto.Text = string.Empty; lstProducto.DataSource = new List<InventoryModel>(); btnBuscarProducto.Enabled = false; btnFacturar.Enabled = false; }
void Awake() { _dialogueController = GameObject.FindGameObjectWithTag(Tags.GameController).GetComponent <DialogueController> (); _shopInterface = GetComponent <ShopInterface>(); _inventoryInterface = GameObject.FindGameObjectWithTag(Tags.GameController).GetComponent <InventoryInterface>(); }