diff --git a/.gitignore b/.gitignore index 5439071..d18b70c 100644 --- a/.gitignore +++ b/.gitignore @@ -2,6 +2,7 @@ *.pyc *.dat *.swp +*.tce passwd fake target/ diff --git a/tanks/Makefile b/tanks/Makefile index b769a30..dd24893 100644 --- a/tanks/Makefile +++ b/tanks/Makefile @@ -24,7 +24,7 @@ target: $(INSTALL) lib/* target/usr/lib/python2.6/site-packages/tanks/ $(INSTALL) -d target/var/service/tanks - $(INSTALL) run target/var/service/tanks/run + $(INSTALL) run run_tanks.py target/var/service/tanks/ $(INSTALL) -d target/var/service/tanks/log/ $(INSTALL) log.run target/var/service/tanks/log/run diff --git a/tanks/lib/Pflanzarr.py b/tanks/lib/Pflanzarr.py index c908815..1e05626 100644 --- a/tanks/lib/Pflanzarr.py +++ b/tanks/lib/Pflanzarr.py @@ -80,7 +80,7 @@ class Pflanzarr: if player == None: color = '#a0a0a0' else: - color = + color = colors[player] tank = Tank.Tank( player, (startX, startY), color, self._board, testMode=True) if player == None: diff --git a/tanks/run b/tanks/run index 8457d0b..25540a2 100755 --- a/tanks/run +++ b/tanks/run @@ -4,5 +4,5 @@ ln -s /var/lib/tanks /usr/lib/www/tanks/results -envuidgid ctf python2.6 run_tanks.py /var/lib/tanks/ easy 100 2>&1 & -envuidgid ctf report_score.py 2>&1 +exec envuidgid ctf python2.6 run_tanks.py /var/lib/tanks/ easy 100 2>&1 & +#envuidgid ctf report_score.py 2>&1 diff --git a/tanks/run_tanks.py b/tanks/run_tanks.py index 4263e15..e82be10 100644 --- a/tanks/run_tanks.py +++ b/tanks/run_tanks.py @@ -15,6 +15,8 @@ try: time.sleep( diff - T ) except: + import traceback + traceback.print_exc() print 'Usage: python2.6 run_tanks.py data_dir easy|medium|hard max_turns'