I think this is not so complicated.
The game is played on a 8×8 square playground.
For this you can use a simple array. For example an int array will be good, because you can simply indicate the puppets of the players with 0 and 1.
The checking can be done with more for loops. Maybe with three, one for the pattern lenght (how many same puppets in a line) and other two to loop through the array.
Other solution is to write a list previously how a pattern can be formed.
For example:
1 2 3 4 5 6 7 8
|
########
########
########
###0111#
###10###
########
########
########
|
[4][5],[4][6],[4][7] is a possible pattern.
You can store theese indices and only check theese every time.
Simplier than with loops although it claims more work.
You don't have to copy the source from somewhere, I think you can write it yourself. With it you will study a lot. :)