botsArena/src/arenas/tictactoe/doc-en.html
2015-12-27 17:30:10 +01:00

42 lines
1.7 KiB
HTML

<h1>Functioning of duels for noughts and crosses</h1>
<p>
Do not trust the animated GIF of the site's home page.<br/>
It's the illustration of the overall operation of the arena, but it is wrong : the tictactoe only needs to send 10 variables to the bots.<br/>
The choice was therefore made to pass them by GET parameters and not by POST as shown in the animation.
</p>
<h2>Requirements : GET variables and HTML return</h2>
<p>
Your program does not have to manage a whole part of noughts and crosses, just one lap.
</p>
<p>
The arbitrator program (the arena) build a request as follows :
</p>
<pre>
https://votreUrl/?you=O&amp;0-0=&amp;0-1=O&amp;0-2=X&amp;1-0=X&amp;1-1=X&amp;1-2=O&amp;2-0=O&amp;2-1=&amp;2-2=X
</pre>
<p>
The GET parameter "you" indicate what is your symbol in the noughts and crosses grid<br/>
Classically : "X" or "O"
</p>
<p>
For each box of the noughts and crosses grid, a GET parameter corresponding to the coordinates ("0-0", "0-1", etc ...) is indicated to you.<br/>
He can be :
</p>
<ul>
<li>Your symbol (which means that you have already played there)</li>
<li>The symbol of your opponent. He has already played in this box</li>
<li>Nothing, the box is available</li>
</ul>
<p>
Your program chooses the box on which he wishes to play in view of the grid and returns its coordinates.
</p>
<p>
The result of the HTTP (s) request can only be : "0-0" ou "0-1" ou "0-2" ou "1-0" etc.
</p>
<p>
A player (an AI) that answers something else, or responds with the coordinates of a box already played, loses the game.
</p>
<h2>Publish your program to test it then release into to the arena</h2>
<p>
The form is on <a href="/">website home page</a> !
</p>