X-Git-Url: https://git.ucc.asn.au/?p=progcomp2013.git;a=blobdiff_plain;f=qchess%2Fqchess.cgi;h=035dce094e05fba13aeb1733fabd6ae059de7735;hp=4b8e34c779d30b648100cdb9cfd6c075aa96dcde;hb=1da52d4a75c75ddff22f3a67a2c06875b335e601;hpb=87681496dec0b1bdadaf0733137010615997fb05 diff --git a/qchess/qchess.cgi b/qchess/qchess.cgi index 4b8e34c..035dce0 100755 --- a/qchess/qchess.cgi +++ b/qchess/qchess.cgi @@ -157,13 +157,17 @@ def main(argv): elif request == "start": print "New game." args = path+"qchess.py --no-graphics" - if mode == None or mode == "bishop": - args += " @fifo:../qchess-cgi-data/"+client+" @internal:AgentBishop --log=../qchess-cgi-data/"+client+".log" - if mode == "random": + if mode == "black": + args += " @internal:AgentBishop @fifo:../qchess-cgi-data/"+client + elif mode == None or mode == "bishop": + args += " @fifo:../qchess-cgi-data/"+client+" @internal:AgentBishop" + elif mode == "random": args += " @fifo:../qchess-cgi-data/"+client+" @internal:AgentRandom" elif mode == "eigengame": args += " --server=progcomp.ucc.asn.au @fifo:../qchess-cgi-data/"+client + args += " --log=@../qchess-cgi-data/"+client+".log"; + os.system("echo '"+args+"' | at now") # subprocess.Popen(args)