Quote:Do you mean your AI has finally caught up with mine! ? Smile Well sorry to say your a year behind my Perfect playing program attached Big Grin ...yeah well... different priorities I guess ;-))
Quote:bplus Wrote: Wrote:@ARB the program is an exe file only, no source .bas file, correct?
Yes! ? Just run the program in one Window and your program in another and play them against each other move by move,if your Paranoid about my program being able to read what your program is thinking ? then run them on different Computers,or even off an external USB Linux live distro running Wine.
No I am not paranoid about your exe's, it's just that the bas is what is interesting to me. I like to see how you get it to do what it does.
Otherwise, I might as well download a random TTT program off Internet to play TTT, it's boring playing a black box!
We are a programming forum honing and showing off our QB64 coding skills; game sharing and playing is for other places.
For instance, this is the code I added for AI to defend against the human should they start at one corner (AI picks middle) and human picks the corner opposite the first corner. A guaranteed win for human IF AI played a corner so the fix was this addition:
Code: (Select All)
' one time you dont want a corner when 3 moves made human has opposite corners, then defense is any side!
If (board$(0, 0) = Player$ And board$(2, 2) = Player$) Or (board$(2, 0) = Player$ And board$(0, 2) = Player$) Then
' try a side order?
If board$(1, 0) = "" Then AIchoice = 1: Exit Function
If board$(0, 1) = "" Then AIchoice = 3: Exit Function
If board$(2, 1) = "" Then AIchoice = 5: Exit Function
If board$(1, 2) = "" Then AIchoice = 7: Exit Function
'still here still? how about a corner office?
If board$(0, 0) = "" Then AIchoice = 0: Exit Function
If board$(2, 0) = "" Then AIchoice = 2: Exit Function
If board$(0, 2) = "" Then AIchoice = 6: Exit Function
If board$(2, 2) = "" Then AIchoice = 8: Exit Function
Else
Now that is something useful a QB64 coder might use for their TTT perfect playing AI.
b = b + ...