diff options
author | makefu <github@syntax-fehler.de> | 2013-11-19 08:38:38 +0100 |
---|---|---|
committer | makefu <github@syntax-fehler.de> | 2013-11-19 08:39:03 +0100 |
commit | b2bdf4e508bd6c58445de4ad302c656a8cf2e983 (patch) | |
tree | d2aa1691341fd58b66106ca76debb02aabbb45b9 /cholerab/cholerab-live/cholerab.py | |
parent | 5788b95fe7834d3049df9de1009f3d8dbc34fea2 (diff) |
cholerab-live -> graveyard
Diffstat (limited to 'cholerab/cholerab-live/cholerab.py')
-rwxr-xr-x | cholerab/cholerab-live/cholerab.py | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/cholerab/cholerab-live/cholerab.py b/cholerab/cholerab-live/cholerab.py deleted file mode 100755 index eb9e66df..00000000 --- a/cholerab/cholerab-live/cholerab.py +++ /dev/null @@ -1,36 +0,0 @@ -#!/usr/bin/python2 -# -*- coding: utf-8 -*- -import curses,time -from view import CursesView -from chol_net import CholerabMulicastNet -import logging -logging.basicConfig(filename='here.log',level=logging.DEBUG) -log = logging.getLogger('main') -class Cholerab: - def __init__(self): - self.view = CursesView(cholerab=self) - self.transport = CholerabMulicastNet(cholerab=self) - def send_char(self,x,y,char): - log.info("Sending %s at (%d,%d) to connected peers" %(char,x,y)) - self.transport.send_char(x,y,char) - - def write_char(self,x,y,char): - log.info("Writing %s at (%d,%d) to view" %(char,x,y)) - self.view.write_char(x,y,char,user=2) - def stop(self): - self.view.stop() - self.transport.stop() - def main(self): - self.view.start() - self.transport.start() - self.view.join() - #after view dies, kill the transport as well - self.transport.stop() - self.transport.join() -def main(): - log.debug('started main') - chol = Cholerab() - chol.main() - -if __name__ == "__main__": - main() |