diff --git a/infiniteworld.py b/infiniteworld.py index 7c04912..1c72926 100644 --- a/infiniteworld.py +++ b/infiniteworld.py @@ -1516,11 +1516,11 @@ class MCInfdevOldLevel(MCLevel): def getChunks(self, chunks=None): - """ pass a list of chunk coordinate tuples to get a list of InfdevChunks. - pass nothing for a list of every chunk in the level. + """ pass a list of chunk coordinate tuples to get an iterator yielding + InfdevChunks. pass nothing for an iterator of every chunk in the level. the chunks are automatically loaded.""" if chunks is None: chunks = self.allChunks; - return [self.getChunk(cx, cz) for (cx, cz) in chunks if self.containsChunk(cx, cz)] + return (self.getChunk(cx, cz) for (cx, cz) in chunks if self.containsChunk(cx, cz)) def _makeChunk(self, cx, cz):