{"id":22124185,"url":"https://github.com/federicoponzi/tictactoeserverclient","last_synced_at":"2026-07-08T10:31:07.036Z","repository":{"id":74371254,"uuid":"144037705","full_name":"FedericoPonzi/TicTacToeServerClient","owner":"FedericoPonzi","description":"A simple TicTacToe game server with client","archived":false,"fork":false,"pushed_at":"2018-10-23T08:26:11.000Z","size":14,"stargazers_count":0,"open_issues_count":1,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-24T07:48:52.538Z","etag":null,"topics":["game-server","golang"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FedericoPonzi.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-08-08T16:05:22.000Z","updated_at":"2018-08-28T07:51:59.000Z","dependencies_parsed_at":null,"dependency_job_id":"45e4c7cd-1185-4918-8e82-6345b5838c1a","html_url":"https://github.com/FedericoPonzi/TicTacToeServerClient","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/FedericoPonzi/TicTacToeServerClient","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FedericoPonzi%2FTicTacToeServerClient","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FedericoPonzi%2FTicTacToeServerClient/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FedericoPonzi%2FTicTacToeServerClient/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FedericoPonzi%2FTicTacToeServerClient/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FedericoPonzi","download_url":"https://codeload.github.com/FedericoPonzi/TicTacToeServerClient/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FedericoPonzi%2FTicTacToeServerClient/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35262336,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-08T02:00:06.796Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["game-server","golang"],"created_at":"2024-12-01T15:46:50.078Z","updated_at":"2026-07-08T10:31:07.020Z","avatar_url":"https://github.com/FedericoPonzi.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TicTacToe game server\n\nThis is a simple client/server system to play TicTacToe.\n\nThe server waits for two opponents/clients to connect, and handle the communication between them.\n\nThere are still many TODO (it still need an appropriate error handling) but its seems usable already.\n\nIt's made in go and using goroutines it is able to handle multiple game simultaneously.\n\nThe protocol is very simple: \n * when two opponents connect, it sends them their \"mark\", \neither a `o` or a `x`.\n\n * `x` moves first. The client sends the move. \n * If the move is valid, the server will validate it \nby sending to both clients the next move. Both client have a copy of the board, and will update their \nlocal copy.\n\n * When the game is over both clients get disconnected.\n\nThere are still things to do, for example it needs a way to know if the connection \nis broken.\n\n\n## Run it\nIt's made with golang 1.10.3 but it should work with other versions too.\nBuild both server and clients:\n```golang\n#Download dependencies first:\ngo get -d ./...\ngo build server.go\ngo build client.go\n```\nRun first the server:\n```\n./server\n```\nAnd then two clients:\n```\n./client\n#In another terminal\n./client\n```\nAnd have fun!\n\n# TODO:\n * Add an AI: After a threshold waiting time, an opponent should start a game with an AI.\n * Add an heartbeating: to know if the other opponent is gone.\n * Add a UI: I'm planning to add a simple UI with QT library.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffedericoponzi%2Ftictactoeserverclient","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffedericoponzi%2Ftictactoeserverclient","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffedericoponzi%2Ftictactoeserverclient/lists"}