Browse Source

Update run.sh

tags/0.1.0
xiangmy21 GitHub 2 years ago
parent
commit
638aece08e
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 11 additions and 12 deletions
  1. +11
    -12
      dependency/shell/run.sh

+ 11
- 12
dependency/shell/run.sh View File

@@ -2,17 +2,16 @@


nice -10 ./Server/Server --port 8888 --studentCount 4 --trickerCount 1 --gameTimeInSecond 600 nice -10 ./Server/Server --port 8888 --studentCount 4 --trickerCount 1 --gameTimeInSecond 600
sleep 5 sleep 5
for k in {1..2}
cd /usr/local/thuai6

for i in {1..5}
do do
pushd /usr/local/team$k
for i in {1..5}
do
if [-f "./capi$i"]; then
j=$((i - 1))
nice -0 ./capi$i -I 127.0.0.1 -P 8888 -p $j
elif [-f "./python/player$i.py"]; then
nice -0 python3 ./python/player$i.py -I 127.0.0.1 -P 8888 -p $j
fi
done
popd
j=$((i - 1))
if [-f "./python/player$i.py"]; then
nice -0 python3 ./python/player$i.py -I 127.0.0.1 -P 8888 -p $j
elif [-f "./capi$i"]; then
nice -0 ./capi$i -I 127.0.0.1 -P 8888 -p $j
else
echo "ERROR. $i is not found."
fi
done done

Loading…
Cancel
Save