Ejemplo n.º 1
0
 protected override Validation <string, InventoryView> CreateService(
     Option <string> closeAction,
     IPlayerControl playerControl,
     Godot.Control node,
     ILoggerFactory loggerFactory)
 {
     return
         (from viewControl in ViewControl
          .ToValidation("Failed to find the view control.")
          from itemStand in ItemStand
          .ToValidation("Failed to find the item stand.")
          from tree in Tree
          .ToValidation("Failed to find the tree view.")
          from buttonContainer in Buttons
          .ToValidation("Failed to find the button container.")
          from infoPanel in InfoPanel
          .ToValidation("Failed to find the information panel.")
          from titleLabel in Title
          .ToValidation("Failed to find the title label.")
          from actionButton in Optional(ActionButton)
          .ToValidation("Failed to find action button template.")
          select new InventoryView(
              playerControl,
              viewControl,
              itemStand,
              PauseWhenVisible,
              closeAction,
              node,
              tree,
              buttonContainer,
              infoPanel,
              titleLabel,
              Type,
              Description,
              actionButton,
              loggerFactory));
 }