pygamegsoc12 / alchemymadness /

import layout
import resources
from sprite import MaskedSprite, Node

class Tubes(Node):
    def __init__(self, *groups):
        super(Tubes, self).__init__()
        for i, r in enumerate(layout.Main.tube_rects):
            self.add(Tube(i, r, *groups))

    def set_colors(self, colors):
        for t in self.children:
            t.mix_color(colors[], 1.)

class Tube(Node, MaskedSprite):
    def __init__(self, tid, rect, *groups):
        super(Tube, self).__init__((255,255,255), *groups) = tid
        self.rect = rect
        self.t_image = resources.background_mask.subsurface(self.rect)
        self.dirty = 1

    def update(self, time):
        super(Tube, self).update(time)
        print 't update'
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.