Skip to content

StudentTraineeCenter/code-soccer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Code Soccer

Code Soccer is a project where I tried to programme and evaluation system of a game Paper Soccer and implement AI algorithms. You can learn the rules on Wiki or in my dissertation work report which has been written in Czech.

Life cycle of a game of Code Soccer

  1. method Main calls method setupGame of GameSetup.java.
  2. Instance of SoccerGame.java is created with designated number of rows and columns. Move history is prepared and ball is set at the center.
  3. After the initialization proccess method play of GameEvaluation.java is called which starts the game.
  4. When game is finished, the winner is printed out in the console.

How to implement your own AI

  1. Fork this repo
  2. In opponents package create your own opponent. This opponet has to implement interface Opponent.java located at stc/soccer/opponents/Opponent.java:13
  3. Add your own type of AI to OpponentType.java enum located at stc.soccer.opponents.types.OpponentType#NAIVEAI
  4. Pass your AI to the constructor of the evaluation system in GameSetup.java located at stc/soccer/core/GameSetup.java:26. Both passed opponents must have different values of GoalLocationType, otherwise an IllegaleStatecException is thrown.
  5. Start your game and look at the results!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages