Git Product home page Git Product logo

onemus's People

Contributors

bkovacik avatar dependabot[bot] avatar

Watchers

 avatar  avatar

Forkers

barry-malone

onemus's Issues

Add zone movement methods

Zone movement methods are how users can interact with the card zones:

  • Draw card - Move card from deck to hand, order = nil
  • Mill card - Move card from deck to graveyard, set order
  • Discard card - Move card from hand to graveyard, set order
  • Play card - If permanent, move card from hand to in play, set location. If not permanent, move card from hand to revealed, then to graveyard, set order
  • Remove from play - Move card from anywhere to removed from play
  • Play terrain - Move terrain from terrain deck to in play, set location
  • Shuffle - Reassign order to deck

Add right-click menus in canvas

When the user right-clicks, a menu should pop up based on where the right-click happened. The actual contents of the menu are TBD but the actual right-click functionality should be there.

Correctly output create user/login errors

Messages are currently compiled into a single key, which means that flash doesn't properly display them. Some values (mainly the create user validation errors) are nested in an array. Error messages aren't really helpful, either.

Remove STI

Remove Single Table Inheritance. Convert the type from String to Integer and make a table for that enumeration. Change everything else to match and remove any models etc.

Check whether session has expired

Users can continue to browse the site when not logged in. There needs to be some sort of check (probably in Javascript to query continually). Whatever checks should be included in the layout or somewhere common.

Add lobby/game room functionality

There should be a chat-only lobby that has a list of open game rooms that can be visited and have games played in them.

Rooms table should be created and joined using a join table, similarly to chroma to cards.

Edit card

Users should be able to edit cards by clicking on them. The form will be filled out with the card's information, where the user can change existing information, then insert it back into the table.

Add turns and turn phases

Users should be able to "take" a turn by going through the phases in that turn:

  1. Refresh (Untap + all gold)
  2. Draw and place from terrain deck
  3. Draw from normal deck
  4. Summoning 1 (units have summoning sickness)
  5. Actions (movement, combat, capping takes 1 action, can’t attack more than once)
  6. Summoning 2
  7. Capture
  8. End

Look into using Redis for caching

The project already uses Redis for production. Maybe use additional caching features to speed up players in room, cards to be played, etc.?

Readd user to the game if they disconnect but come back

If a user refreshes the page, websockets considers them to have disconnected. Similarly, if they navigate off the page and come back, they should be able to come back to the game. Might require keeping track of user connected state.

Add relevant titles

Add titles for the pages that don't have one (all of them except login). Probably should use locales.

Create models for all card types

Have Cards as a base type, with name, ability, and json ability. Spells will directly inherit from Cards. Terrain will inherit from Cards with attack, hit, and evasion fields. Heroes will inherit from Cards, with the addition of card_type and HP/attack fields. Creatures will inherit from Heroes with the addition of a cost field.

Split cards table into smaller tables

With the change described in #40, individual card types in the table continue to differ from each other, gaining new fields and losing some common fields. Thus, it is probably best to split up the cards table.

The new cards tables can be linked together using a central card_id table, which stores both the relative and absolute card ids. Individual card entries will also have the relative and absolute card ids. These will be linked back and forth one-to-one.

All cards can be selected by performing a join between the card_id table and each other table on the absolute card_id field.

Add card list

Cards should be listed, where they can display pertinent information.

Add canvas and GUI

The GUI should keep track of the card zones (deck, in play, etc.) and other important information, such as a room list of player names, turn order, phase counters, etc.

Add card zones

Users should be able to interact with card zones:

  • Deck
  • Terrain deck
  • Removed from play
  • Hand
  • In play
  • Revealed

Add chroma

Need to add chroma to the database through a migration. Should link to a table in a many-to-many pattern with all 6 values: anger, apathy, entropy, greed, order, and pride.

Sort/filter card list

Card list should be able to be sorted/filtered, probably by chroma, cost, power, toughness, type, and sort by name.

Add decks

Decks can be premade for now, but the user should be able to interact with the deck as they decide: look through it, draw from it, shuffle it, etc. Composition of the deck should be variable as well.

Add counters

Add counters like damage and victory points (or maybe victory points should be a running total)

Add logout

Add logout (should be in the form of clearing session cookies)

Update cards database with the token update

Creature cards were updated such that they are no longer represented by individual cards and are instead represented by an archetype that can spawn tokens. We also added equipment that has represents a particular slot and is equipped in that slot for creatures.

So, we will need to represent equipment slots for creatures/heroes, which will likely be many-to-many, in addition to adding new fields such as population cap for tokens (LIST WIP)

Might also be time to fission the card table into smaller tables that more accurately represent what the particular type of card contains.

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.