5
# Copyright (C) 2005 Laurent Lacheny
7
# This program is free software; you can redistribute it and/or modify
8
# it under the terms of the GNU General Public License as published by
9
# the Free Software Foundation; either version 3 of the License, or
10
# (at your option) any later version.
12
# This program is distributed in the hope that it will be useful,
13
# but WITHOUT ANY WARRANTY; without even the implied warranty of
14
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
# GNU General Public License for more details.
17
# You should have received a copy of the GNU General Public License
18
# along with this program; if not, see <http://www.gnu.org/licenses/>.
21
# This code comes from the project 4stattack
22
# http://forcedattack.sourceforge.net/
24
#########################################################################
26
#########################################################################
28
# Developer - "slm" - Jeroen Vloothuis #
29
# Graphics - "Korruptor" - Gareth Noyce #
30
# Music - "theGREENzebra" #
31
#########################################################################
33
# chakie(Jan Elkholm) - letting me "embrace and extend" his gui lib #
34
# Mighty(Xander Soldaat) - for the Makefile and the Debian packages #
35
# Han - for the rpms #
36
# jk - for the FreeBSD port #
37
# Tjerk Nan - for the Windows version #
38
# Micon - for the webdesign #
39
# Everyone in #pygame and the opensource community in general #
40
#########################################################################
41
# This software is licensed under the GPL - General Public License #
42
#########################################################################
47
# Setup an empty board
54
def move(self, move, player):
55
self.state[move].append(player)
58
def domoves(self, moves):
59
for (move, player) in moves:
60
self.move(move, player)
62
def undomove(self, move):
63
if len(self.state[move]) > 0:
64
del self.state[move][len(self.state[move])-1]