Alexander Schremmer  committed 97aaa7c

Set default for amount of AIPlayers to 0.

  • Participants
  • Parent commits 08d72f5
  • Branches default

Comments (0)

Files changed (2)

File domination/

                 n = min(len(names), int(request.form.get("numai", 1)))
             except ValueError:
-                n = 1
+                n = 0
             for i in range(n):
                 player = AIPlayer(names[i])

File domination/templates/create_game.html

   <form action="" method="post">
     <p>Name of Game: <input type="text" name="name" value="{{ name }}"></p>
     <p><input type="checkbox" name="ai" value="yes">Add
-      <input type="text" name="numai" value="1" maxlength="1" size="3"> AI player(s)</p>
+      <input type="text" name="numai" value="0" maxlength="1" size="3"> AI player(s)</p>
       {% for edition in editions %}
       <input type="checkbox" name="edition" value="{{ edition.key }}"