Пример #1
0
 public void AddCommand(int index, ObjectInventoryManager obj, INPCCommand command)
 {
     model.commands.Add(new NPCCommandModel()
     {
         index = index, gameObject = obj, destinationCommand = command
     });
 }
        public void ConstructViewModel()
        {
            //TODO: This needs to be made more robust. It now sometimes comes back with a wrong object
            //object view was opened from
            currentObject = playerManager.WorldObjectLookingAt();
            var model = new ScreenInventoryTransferModel(currentObject, playerInventory.model.itemCollection, currentObject.inventory.itemCollection);

            view.ApplyModel(model);
        }
        public ScreenInventoryTransferModel(ObjectInventoryManager worldObject, List <Item> local, List <Item> remote)
        {
            remoteInventoryType = worldObject.inventory.inventoryType;

            localInventoryScroll = new ScrollListModel(worldObject.containLimit);

            if (remoteInventoryType == ObjectInventoryTypes.Type.Scroll)
            {
                remoteInventory = new ScrollListModel(worldObject.containLimit);
            }
            else
            {
                remoteInventory = new ScreenMachineProcessorModel(worldObject);
            }

            localInventoryScroll.AddContainers(local);
            remoteInventory.AddContainers(remote);
        }
Пример #4
0
 public void SelectedRouteObject(ObjectInventoryManager obj, int index, INPCCommand command)
 {
     stateManager.CameraShow();
     screenManager.Show();
     screenManager.AddRoute(index, obj, command);
 }
 public ScreenMachineProcessorModel(ObjectInventoryManager worldObject)
 {
     selectedWorldObject = worldObject;
 }
 public void AddRoute(int index, ObjectInventoryManager obj, INPCCommand command)
 {
     npc.AddCommand(index, obj, command);
 }