def draw(self, dt=0): with util.pushmatrix(gamestate.scale): for scn in self.scenes: scn.draw() if self.blackout_alpha > 0.0: util.draw.set_color(0, 0, 0, self.blackout_alpha) self.batch.draw()
def draw(self, dt=0): if self.blackout: draw.set_color(0, 0, 0, 1) draw.rect(0, 0, gamestate.norm_w, gamestate.norm_h) return self.env.behind.blit(0, 0, 0) with camera.apply_camera(self.camera): if self.main_group: self.main_group.x = self.x_offset self.main_group.y = self.y_offset with pushmatrix(pyglet.gl.glTranslatef, self.x_offset, self.y_offset, 0): self.env.draw() self.shadow.draw() self.batch.draw() self.env.draw_overlay() self.convo.draw() convos_to_remove = set() for c in self.background_convos: c.draw() if not c.active: convos_to_remove.add(c) for c in convos_to_remove: c.delete() self.background_convos.remove(c)
def draw(self, dt=0): if self.blackout: draw.set_color(0,0,0,1) draw.rect(0, 0, gamestate.norm_w, gamestate.norm_h) return self.env.behind.blit(0,0,0) with camera.apply_camera(self.camera): if self.main_group: self.main_group.x = self.x_offset self.main_group.y = self.y_offset with pushmatrix(pyglet.gl.glTranslatef, self.x_offset, self.y_offset, 0): self.env.draw() self.shadow.draw() self.batch.draw() self.env.draw_overlay() self.convo.draw() convos_to_remove = set() for c in self.background_convos: c.draw() if not c.active: convos_to_remove.add(c) for c in convos_to_remove: c.delete() self.background_convos.remove(c)
def draw(self, dt=0): with util.pushmatrix(gamestate.scale): for scn in self.scenes: scn.draw() if self.blackout_alpha > 0.0: self.fs.opacity = self.blackout_alpha*255 self.fs.set_position(0, 0) self.batch.draw()
def draw(self, dt=0): with util.pushmatrix(gamestate.scale): self.scene_handler.draw_scenes() self.ui.draw() self.scene_handler.draw()