Ejemplo n.º 1
0
    def __init__(self):
        ##
        director.set_clear_color(COLOR_WHITE);

        ## Logo
        self.logo     = assets.load_image("AmazingCow_Logo_Small.png");
        logo_size     = self.logo.get_size();
        self.logo_pos = ((GAME_WIN_WIDTH * 0.5) - (logo_size[0] * 0.5), 15);

        color_surface(
            self.logo,
            director.randint(0, 255),
            director.randint(0, 255),
            director.randint(0, 255)
        );


        ## Message
        msg = [
            "This remake was made with <3 by Amazing Cow.",
            "We hope that you enjoy this little game (!)"
            "",
            "We have other projects at:",
            "www.amazingcow.com",
            "",
            "This game is entirely FREE SOFTWARE",
            "This means that you're welcome to",
            "SHARE and HACK IT (!!!)",
            "",
            "You can find the sources at:",
            "opensource.amazingcow.com",
            "",
            "Dev / Graphics / Sound by N2OMatt",
            "",
            "THANKS FOR PLAYING...",
            "",
            "The CCV helps people not commit suicide.",
            "Their work is very, very important.",
            "Why don't you help them?",
            "www.cvv.org.br"
        ];

        self.texts   = [];
        start_offset = self.logo_pos[1] + logo_size[1] + 5;
        line_offset  =  16;

        for i in xrange(0, len(msg)):
            text = Text("SourceCodePro-Regular.ttf", line_offset,
                        -1, -1,
                        msg[i], COLOR_BLACK);
            text_size = text.get_size();

            text.set_position(
                (GAME_WIN_WIDTH * 0.5) - (text_size[0] * 0.5),
                start_offset + (i * line_offset)
            );

            self.texts.append(text);
Ejemplo n.º 2
0
    def __init__(self):
        ##
        director.set_clear_color(COLOR_WHITE);

        ## Logo
        self.logo     = assets.load_image("AmazingCow_Logo_Small.png");
        self.logo_pos = ((GAME_WIN_WIDTH * 0.5) - (self.logo.get_width() * 0.5),
                         20);

        color_surface(
            self.logo,
            random.randint(0, 255),
            random.randint(0, 255),
            random.randint(0, 255)
        );


        ## Message
        msg = [
            "This remake was made with <3 by Amazing Cow Labs.",
            "We hope that you enjoy this little game (!)"
            "",
            "We have other projects at:",
            "www.amazingcow.com",
            "Take a look :)",
            "",
            "This game is entirely FREE SOFTWARE",
            "This means that you're welcome to",
            "SHARE and HACK IT (!!!)",
            "",
            "You can find the sources at:",
            "opensource.amazingcow.com",
            "",
            "Dev / Graphics / Sound by N2OMatt",
            "","",
            "THANKS FOR PLAYING..."
            "", "", "",
            "APAE do a wonderful job helping exceptional people",
            "Why you don't look and help their work? <3",
            "www.apaebrasil.org.br"
        ];

        self.texts   = [];
        start_offset = 140;
        line_offset  =  20;

        for i in xrange(0, len(msg)):
            text      = Text("SourceCodePro-Regular.ttf", 20, -1, -1, msg[i], COLOR_BLACK);
            text_size = text.get_size();

            text.set_position(
                (GAME_WIN_WIDTH * 0.5) - (text_size[0] * 0.5),
                start_offset + (i * line_offset)
            );

            self.texts.append(text);
Ejemplo n.º 3
0
    def update(self, dt):
        self._timer.update(dt);

        if(not self._update_colors):
            return;

        curr_r, curr_g, curr_b = self._curr_rgb;
        dst_r, dst_g, dst_b    = self._dst_rgb;
        step = 5;

        ## Red
        if  (curr_r > dst_r): curr_r -= step;
        elif(curr_r < dst_r): curr_r += step;
        ## Blue
        if  (curr_g > dst_g): curr_g -= step;
        elif(curr_g < dst_g): curr_g += step;
        ## Green
        if  (curr_b > dst_b): curr_b -= step;
        elif(curr_b < dst_b): curr_b += step;

        self._curr_rgb = curr_r, curr_b, curr_g;
        color_surface(self._logo, curr_r, curr_g, curr_b);
Ejemplo n.º 4
0
    def update(self, dt):
        self._timer.update(dt)

        if (not self._update_colors):
            return

        curr_r, curr_g, curr_b = self._curr_rgb
        dst_r, dst_g, dst_b = self._dst_rgb
        step = 5

        ## Red
        if (curr_r > dst_r): curr_r -= step
        elif (curr_r < dst_r): curr_r += step
        ## Blue
        if (curr_g > dst_g): curr_g -= step
        elif (curr_g < dst_g): curr_g += step
        ## Green
        if (curr_b > dst_b): curr_b -= step
        elif (curr_b < dst_b): curr_b += step

        self._curr_rgb = curr_r, curr_b, curr_g
        color_surface(self._logo, curr_r, curr_g, curr_b)