The Fun Part 0 ▲ ronjeffries.com 1 hour ago · 7 min read1407 words · Tech · hide · 0 comments Hello, loves! I think this morning we get to do the fun part with our new YieldStepper. Ants?? But first, we need to put in the view-handling part. When stepping the build, we need to update the view on every step. And in the BuildStepper, there’s some special code at the end of things, but maybe we’ll do that differently. To begin, however, I think we need to stick closely to the BuildStepper, which goes like this: class BuildStepper: def __init__(self, table, layout, dungeon ): self.table = table self.index = 0 self.layout = layout self.dungeon = dungeon def run_to_completion(self, view=None): while self._more_to_do(): self._do_one_step(view) self._update_view(view) def maker_single_step(self, view=None): if self._more_to_do(): self._do_one_step(view) self._update_view(view) return self._more_to_do() def _update_view(self, view): if view: sub = self.layout.subregion self.layout.clear_subregions() view.update_KSL() self.layout.subregion = sub def _more_to_do(self): return self.index… No comments yet. Log in to reply on the Fediverse. Comments will appear here.