示例#1
0
        public void Deregister(Gas_Spreading gas, int index)
        {
            var c = map.cellIndices.IndexToCell(index);

            things[index].RemoveAll(g => g == gas);
            foreach (var offset in GenAdj.AdjacentCellsAndInside)
            {
                var cell   = c + offset;
                var center = cell.Equals(c);
                if (!cell.InBounds(map))
                {
                    continue;
                }
                var i = map.cellIndices.CellToIndex(c + offset);
                cumulativeThings[i].RemoveAll(g => g == gas);
                grid[i] = cumulativeThings[index].Count;
            }
        }
示例#2
0
 public void Deregister(Gas_Spreading gas, IntVec3 cell)
 {
     Deregister(gas, map.cellIndices.CellToIndex(cell));
 }
示例#3
0
 public void RegisterAt(Gas_Spreading gas, IntVec3 cell)
 {
     RegisterAt(gas, map.cellIndices.CellToIndex(cell));
 }