git.ucc.asn.au
/
progcomp2013.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove types_revealed from network.py
[progcomp2013.git]
/
qchess
/
src
/
network.py
diff --git
a/qchess/src/network.py
b/qchess/src/network.py
index
72467d8
..
75df117
100644
(file)
--- a/
qchess/src/network.py
+++ b/
qchess/src/network.py
@@
-116,7
+116,7
@@
class NetworkSender(Player,Network):
if selected != None and selected.colour == self.colour and len(s) > 2 and not "->" in s:
s = " ".join(s[0:3])
for i in range(2):
if selected != None and selected.colour == self.colour and len(s) > 2 and not "->" in s:
s = " ".join(s[0:3])
for i in range(2):
- if selected.types
_revealed[i] == True
:
+ if selected.types
[i][0] == '?'
:
s += " " + str(selected.types[i])
else:
s += " unknown"
s += " " + str(selected.types[i])
else:
s += " unknown"
@@
-132,7
+132,7
@@
class NetworkSender(Player,Network):
class NetworkReceiver(Player,Network):
def __init__(self, colour, address=None):
class NetworkReceiver(Player,Network):
def __init__(self, colour, address=None):
- Player.__init__(self,
address
, colour)
+ Player.__init__(self,
"NetworkReceiver"
, colour)
self.address = address
self.address = address
@@
-177,9
+177,9
@@
class NetworkReceiver(Player,Network):
for i in range(2):
selected.types[i] = str(s[3+i])
if s[3+i] == "unknown":
for i in range(2):
selected.types[i] = str(s[3+i])
if s[3+i] == "unknown":
- selected.types
_revealed[i] = False
+ selected.types
[i] = '?'+selected.types[i]
else:
else:
- selected.types
_revealed[i] = True
+ selected.types
[i] = selected.types[i][1:]
selected.current_type = selected.types[selected.choice]
else:
pass
selected.current_type = selected.types[selected.choice]
else:
pass
UCC
git Repository :: git.ucc.asn.au