<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://pzwiki.wdka.nl/mw-mediadesign/index.php?action=history&amp;feed=atom&amp;title=2009_302</id>
	<title>2009 302 - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://pzwiki.wdka.nl/mw-mediadesign/index.php?action=history&amp;feed=atom&amp;title=2009_302"/>
	<link rel="alternate" type="text/html" href="https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;action=history"/>
	<updated>2026-08-05T07:54:02Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.38.2</generator>
	<entry>
		<id>https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3440&amp;oldid=prev</id>
		<title>Michael Murtaugh: /* The (Py)Game of life */</title>
		<link rel="alternate" type="text/html" href="https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3440&amp;oldid=prev"/>
		<updated>2009-05-25T12:21:31Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;The (Py)Game of life&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 14:21, 25 May 2009&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l11&quot;&gt;Line 11:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 11:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== The (Py)Game of life ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== The (Py)Game of life ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[http://en.wikipedia.org/wiki/Conway%27s_Game_of_Life &lt;/del&gt;Conway's Game of &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Life&lt;/del&gt;]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;We looked today at a Python implementation of &lt;/ins&gt;Conway's &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[&lt;/ins&gt;Game of &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;life]&lt;/ins&gt;]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Media:PyGameOfLife.zip]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Media:PyGameOfLife.zip]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Michael Murtaugh</name></author>
	</entry>
	<entry>
		<id>https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3439&amp;oldid=prev</id>
		<title>Michael Murtaugh at 09:38, 14 May 2009</title>
		<link rel="alternate" type="text/html" href="https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3439&amp;oldid=prev"/>
		<updated>2009-05-14T09:38:41Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 11:38, 14 May 2009&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l10&quot;&gt;Line 10:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 10:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== The (Py)Game of life ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== The (Py)Game of life ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[http://en.wikipedia.org/wiki/Conway%27s_Game_of_Life Conway's Game of Life]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Media:PyGameOfLife.zip]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Media:PyGameOfLife.zip]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Michael Murtaugh</name></author>
	</entry>
	<entry>
		<id>https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3438&amp;oldid=prev</id>
		<title>Michael Murtaugh at 12:29, 12 May 2009</title>
		<link rel="alternate" type="text/html" href="https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3438&amp;oldid=prev"/>
		<updated>2009-05-12T12:29:22Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Reading ==&lt;br /&gt;
&lt;br /&gt;
There is a reading for next week. Copies are available in the office (I left a pile on my/Aymeric's desk).&lt;br /&gt;
&lt;br /&gt;
== Morning ==&lt;br /&gt;
&lt;br /&gt;
Talking [[PyGame]]&lt;br /&gt;
&lt;br /&gt;
http://www.youtube.com/watch?v=LLUMM18Ln5Q&lt;br /&gt;
&lt;br /&gt;
== The (Py)Game of life ==&lt;br /&gt;
&lt;br /&gt;
[[Media:PyGameOfLife.zip]]&lt;br /&gt;
&amp;lt;p&amp;gt;&lt;br /&gt;
beginning of space invaders, follow the enemy!&lt;br /&gt;
&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;source lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
import pygame&lt;br /&gt;
from pygame.locals import *&lt;br /&gt;
from sys import exit&lt;br /&gt;
from random import *&lt;br /&gt;
&lt;br /&gt;
clock = pygame.time.Clock()&lt;br /&gt;
pygame.init()&lt;br /&gt;
screen = pygame.display.set_mode((640, 480), 0, 32)&lt;br /&gt;
&lt;br /&gt;
class Anybody(object):&lt;br /&gt;
    def __init__(self, x, y, color=(255, 255, 255)):&lt;br /&gt;
        self.x = x&lt;br /&gt;
        self.y = y&lt;br /&gt;
        self.color = color&lt;br /&gt;
        self.width = 20&lt;br /&gt;
        self.height = 20&lt;br /&gt;
        &lt;br /&gt;
    def draw(self, screen):&lt;br /&gt;
        pygame.draw.rect(screen, self.color, Rect(self.x, self.y, self.width, self.height))&lt;br /&gt;
    def chase(self, enemy):&lt;br /&gt;
        if enemy.x &amp;lt; self.x:&lt;br /&gt;
            self.x -= 1&lt;br /&gt;
        else:&lt;br /&gt;
            self.x += 1&lt;br /&gt;
&lt;br /&gt;
player = Anybody(100, 400, (0, 255, 0))&lt;br /&gt;
invader = Anybody(100, 50)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
while True:&lt;br /&gt;
    #1 Handling the events&lt;br /&gt;
    for event in pygame.event.get():&lt;br /&gt;
        if event.type == QUIT:&lt;br /&gt;
            exit()&lt;br /&gt;
        elif event.type == KEYDOWN and event.key == K_ESCAPE:&lt;br /&gt;
            exit()&lt;br /&gt;
        elif event.type == KEYDOWN:&lt;br /&gt;
            if event.key == K_RIGHT:&lt;br /&gt;
                player.x += 20&lt;br /&gt;
            elif event.key == K_LEFT:&lt;br /&gt;
                player.x -= 20&lt;br /&gt;
&lt;br /&gt;
    #2 Draw the frame&lt;br /&gt;
    # blank the screen&lt;br /&gt;
    pygame.draw.rect(screen, (0, 0, 0), Rect(0, 0, 640, 480))&lt;br /&gt;
    player.draw(screen)&lt;br /&gt;
    invader.draw(screen)&lt;br /&gt;
    invader.chase(player)&lt;br /&gt;
    pygame.display.update()&lt;br /&gt;
    clock.tick(30)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Michael Murtaugh</name></author>
	</entry>
	<entry>
		<id>https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3434&amp;oldid=prev</id>
		<title>Michael Murtaugh at 13:18, 7 May 2009</title>
		<link rel="alternate" type="text/html" href="https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3434&amp;oldid=prev"/>
		<updated>2009-05-07T13:18:24Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Morning ==&lt;br /&gt;
&lt;br /&gt;
Talking [[PyGame]]&lt;br /&gt;
&lt;br /&gt;
http://www.youtube.com/watch?v=LLUMM18Ln5Q&lt;br /&gt;
&lt;br /&gt;
== The (Py)Game of life ==&lt;br /&gt;
&lt;br /&gt;
[[Media:PyGameOfLife.zip]]&lt;/div&gt;</summary>
		<author><name>Michael Murtaugh</name></author>
	</entry>
	<entry>
		<id>https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3432&amp;oldid=prev</id>
		<title>Michael Murtaugh: New page: == Morning ==  Talking PyGame</title>
		<link rel="alternate" type="text/html" href="https://pzwiki.wdka.nl/mw-mediadesign/index.php?title=2009_302&amp;diff=3432&amp;oldid=prev"/>
		<updated>2009-05-07T09:59:07Z</updated>

		<summary type="html">&lt;p&gt;New page: == Morning ==  Talking &lt;a href=&quot;/mediadesign/PyGame&quot; class=&quot;mw-redirect&quot; title=&quot;PyGame&quot;&gt;PyGame&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Morning ==&lt;br /&gt;
&lt;br /&gt;
Talking [[PyGame]]&lt;/div&gt;</summary>
		<author><name>Michael Murtaugh</name></author>
	</entry>
</feed>