예제 #1
0
        public ServerInventory SourceObject(IRes resource)
        {
            ServerInventory serverInventory = new ServerInventory(this.MaxSlots);

            if (this.Items != null)
            {
                serverInventory.SetItems(DatabaseUtils.TransformForInventory(this.Items));
            }
            return(serverInventory);
        }
예제 #2
0
        public WorkhouseStation SourceObject(IRes resourcse)
        {
            WorkhouseStation station = new WorkhouseStation();

            //if(this.Hold != null ) {
            //    station.SetHold(this.Hold);
            //}

            if (this.StationInventoryItems == null)
            {
                this.StationInventoryItems = new List <InventoryItemDocumentElement>();
            }
            ServerInventory serverInventory = new ServerInventory(this.StationInventoryMaxSlots);

            serverInventory.SetItems(DatabaseUtils.TransformForInventory(this.StationInventoryItems));
            station.SetInventory(serverInventory);
            station.SetPetSchemeAdded(petSchemeAdded);
            return(station);
        }