Code Monkey home page Code Monkey logo

risk-game's People

Contributors

gtimothee avatar hangao2333 avatar hantoine avatar nellybettirahola avatar yixuan-lee avatar

Watchers

 avatar  avatar

risk-game's Issues

Save edited maps

Saving a map to a text file exactly as edited (using the “conquest” game map format).

Allocation of armies

Players are allocated a number of initial armies, depending on the number of players.

Edit a map

Loading a map from an existing “conquest” map file, then editing the map, or create a new map from
scratch.

fix somes things in map editor

validate before saving (+connected graph)
fix the mysterious comma
null -> review
change message for "is not a connected graph"

Refactor: Implement Observer pattern

After the lecture on MVC, I realized in MVC the controlleur is not the one asking the view to update itself.

In the future we will have to use the observer pattern, I suggest we fix our MVC by already using the observer pattern. The changes to make would actually not be that broad, just make RiskView implements observer interface and make the view call updateView on itself whenever it receives a notification from the RiskModel. This would require RiskView to have a reference to RiskModel that we thought was not something to do.

I could take care of this.

Game Play

Implementation of a game driver implementing the game phases according to the Risk rules.

Verification of map

Verification of map correctness upon loading and before saving (at least 3 types of incorrect maps).

Loading the map

Map is loaded as a connected graph, which is rendered effectively to the user to enable efficient play

Choose players

User chooses the number of players, then all countries are randomly assigned to players.

Fix fortification phase

Make sure the player cannot remove all armies from a territory. There should always be at least one army left.

Creation of map elements

User-driven creation of map elements, such as country, continent, and connectivity between
countries.

File Reader

File reader to create the model (players, board (continent,countries...)).

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.