Ejemplo n.º 1
0
        public static bool TestCellStorageStack(this Cell_Storage_Collection collection, IntVec3 cell, int expectedCount)
        {
            if (collection.TryGetCellStorage(cell, out CellStorage cellStorage))
            {
                return(Assert.AreEqaul(
                           cellStorage.Count
                           , expectedCount
                           , nameof(cellStorage.Count)
                           , nameof(expectedCount)));
            }

            ReportCantFindCell(collection, cell);
            return(false);
        }
Ejemplo n.º 2
0
        public static bool TestSpareSpaceOnNonFull(this Cell_Storage_Collection collection, Thing thing, IntVec3 cell, int expectedCount)
        {
            if (collection.TryGetCellStorage(cell, out CellStorage cellStorage))
            {
                return(Assert.AreEqaul(
                           cellStorage.SpareSpaceOnNonFull(thing)
                           , expectedCount
                           , $"SpareSpace On {cell}"
                           , nameof(expectedCount)));
            }

            ReportCantFindCell(collection, cell);
            return(false);
        }
Ejemplo n.º 3
0
        public static bool TestCellStorageWeight(this Cell_Storage_Collection collection, IntVec3 cell, float expectedWeight)
        {
            if (collection.TryGetCellStorage(cell, out CellStorage cellStorage))
            {
                return(Assert.AreEqaul(
                           cellStorage.TotalWeight
                           , expectedWeight
                           , nameof(cellStorage.TotalWeight)
                           , nameof(expectedWeight)));
            }

            ReportCantFindCell(collection, cell);
            return(false);
        }