Git Product home page Git Product logo

plog_mod-x's Introduction

PLOG_Mod-X

This project is my application of the Mod-X board game (https://www.cryptozoic.com/games/mod-x) in Prolog. It is complete with all functionalities, including options to change number of pieces per player, number of points to be achieved and different modes. It includes a Player vs Player mode, a Player vs Computer mode and a Computer vs Computer mode.

There are 2 dificulties in the game with diferent levels of artificial intelligence (one easier, other harder). The first one will try its best to score as quickly as possible. The second one will do this, while at the same time will try to destroy your chances of scoring.

The game has 2 graphical interfaces, running simultaneously, for better comprehension of the current game state. The first is a text view where:

  • Player 1 pieces are marked with a "x";
  • Player 2 pieces are marked with a "o";
  • Jokers are marked with a "J";
  • Player 1 points are marked with a "1" and are painted green;
  • Player 2 points are marked with a "2" and are painted blue;

The second is a "table" interface in which:

  • Player 1 pieces are marked with a blue "x";
  • Player 2 pieces are marked with a red "x";
  • Jokers are marked with a yellow "x";
  • Player 1 points are painted blue;
  • Player 2 points are painted red/pink;

The main focus of this project is the logical implementation of the game, of its rules and the artificial intelligence, rather than the graphical interface. It was designed to run using SWI Prolog (http://www.swi-prolog.org/).

Fig. 1 - Initial menu

Fig. 2 - Game begins. Overview of both graphical interfaces

Fig. 3 - Both players placed their pieces in the first turn

Fig. 4 - Player 2 scored some points

Fig. 5 - Player 1 scored some points, and got one stolen from the other player

plog_mod-x's People

Contributors

miguellucas avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.