Did I find the right examples for you? yes no

All Samples(2)  |  Call(1)  |  Derive(0)  |  Import(1)

src/p/y/pythello-0.1/pythello/servertk.py   pythello(Download)
 
from boardtk import BoardTk, S, H, W, SBH
from player import AI, HumanTk
from server import Server
 
        for player, color, playerstr in ('player1', 'black', bpstr), ('player2', 'white', wpstr):
            if playerstr == 'Human':
                setattr(self, player, HumanTk(color, self.board))
            else:
                assert playerstr.startswith('AI '), 'Got unexpected player type'