def render(self, screen, y, size, rcpos=None): for n, s in enumerate(self.sels): Img.bcentrex( tfont, s, screen, n * 64 + y - 16, col=(0, 0, 0) if rcpos is None or rcpos.y != n else self.selcol)
def render(self, screen, srcj): screen.fill(self.bcol) Img.bcentrex(tfont, self.title, screen, 48) y = 0 cc = self.cdict[srcj] for e in self.es: h = e.get_h(self.size.x) e.render(screen, y * 64 + 128, self.size, cc - Vector.VectorX(0, y) if y <= cc.y < y + h else None) y += h
def render(self, screen, y, size, rcpos=None): if Research.current[self.team]: for x, r in enumerate(Research.current[self.team]): if r is Research.current_research[self.team]: draw.rect( screen, (100, 100, 100), Rect(x % size.x * 64, y + x // size.x * 64, 64, 64)) screen.blit(r.img[3], (x % size.x * 64, y + x // size.x * 64)) if rcpos is not None: screen.blit(sel[3], rcpos * 64 + Vector.VectorX(0, y)) selr = Research.current[self.team][rcpos.x + rcpos.y * size.x] l = len(selr.packs) offset = (size.x - l) * 32 for x, p in enumerate(selr.packs): Img.draw_with_num(screen, Items.get_item_image("SP%s" % p), selr.n, (offset + x * 64, (size.y - 1) * 64), 4) else: Img.bcentrex(tfont, "NO RESEARCH AVAILABLE", screen, y - 16)
def render(self, screen, y, size, rcpos=None): Img.bcentrex(tfont, self.text, screen, y - 16, col=(0, 0, 0) if rcpos is None else self.selcol)