Exemplo n.º 1
0
 def login(self):
     #socksend('R1L15026765035e51f')
     msg = stringtree.grow('R', [
         '1',
         stringtree.grow(
             'L', [self.roomid,
                   str(self.loginid), self.passHash, ''])
     ])
     #print msg
     self.sock.socksend(msg)
Exemplo n.º 2
0
 def joinTable(self, index):
     self.sock.socksend(stringtree.grow('TJ', [str(index)]))
Exemplo n.º 3
0
 def setTable(self, settings):
     self.sock.socksend(stringtree.grow('Ts', [settings]))
Exemplo n.º 4
0
 def swap(self, tiles):
     print "swapping " + tiles
     self.sock.socksend(stringtree.grow('GC', [tiles + '']))
Exemplo n.º 5
0
 def playMove(self, encMove):
     print "playMove in qpAction"
     self.sock.socksend(stringtree.grow('GW', [encMove + '']))
Exemplo n.º 6
0
 def privateChat(self, alias, text, me=None):
     if not me:
         me = self.me
     self.sock.socksend(
         stringtree.grow(
             'Cm', [stringtree.grow('u', [alias, me]), text + '50']))
Exemplo n.º 7
0
 def publicChat(self, text):
     self.sock.socksend(stringtree.grow('Cm', ['P', text + '50']))
Exemplo n.º 8
0
 def tableChat(self, text):
     self.sock.socksend(stringtree.grow('Cm', ['t', text + '50']))
Exemplo n.º 9
0
 def acceptUser(self, alias):
     print "***ACCEPTING USER " + alias + " to table " + str(self.myTable)
     self.sock.socksend(stringtree.grow('TA', [alias]))