Giter Club home page Giter Club logo

mtg-horde's Introduction

MTG Horde Player

This tool is a helper for playing Horde, which is a cooperative format for Magic: The Gathering, where one or more players can play against a "dumb" deck.

Format Rules

  • There are two factions: the Horde (this app), and the Survivors (players)
  • The Horde will be controlled by this app. It starts with a pre-built deck of 200 cards
  • The Survivors are a group of one or more players, who can use any pre-built deck of their choosing.
  • The Survivors have a shared life total, which starts at 20 for each player (eg: 1 player = 20 life, 2 players = 40 life, etc)

Win conditions:

  • The Horde wins if the Survivors' shared life total drops to zero or below.
  • The Survivors win if the Horde has no cards in its library or in hand, and no creatures on the battlefield.

Survivor Rules

  • Survivors have three turns to set up their defenses before the Horde gets its first turn. Then the turns alternate like normal
  • Survivors take their turn simultaneously, and attack and block as a team, like in the Two Headed Giant format.
  • When the Survivors attack the Horde, they must choose to either "Confront the Horde" or "Burn the Bodies"
    • If they decide to "Confront the Horde", any combat damage dealt will result in discarding that many cards from the top of the deck, into the graveyard. In the app, that can be done via the "Discard" button below the deck.
    • If they decide to "Burn the Bodies", any combat damage dealt will result in exiling that many cards randomly from the graveyard. In the app, that can be done via the "Exile" button below the graveyard.
    • Survivors must choose one option or the other. They can't "Confront the Horde" with some creatures, and "Burn the Bodies" with others.
    • If you get an additional combat phase, you may choose a different option for it.
  • When direct damage is dealt to the Horde, it should be treated as "Confronting the Horde" (ie: discard from the library into the graveyard).

Horde Rules:

Most of these rules are (or will be) built into the app.

  • The Horde has infinite mana
  • Any decisions the horde has to make are random.
  • The Horde starts with one "Intensity" emblem, and one "Time" counter
  • On the Horde's turn, it will reveal cards from the top of its library, until X non-token cards are revealed, where X is the number of "Intensity" emblems the Horde has. Then all those cards will be cast (in the order they were revealed). Then, if the Horde has any cards that can be cast from its graveyard or its hand, it casts those.
  • All creatures controlled by the Horde have haste and "This creature must attack each turn if able"
  • At the end of each Horde turn, the Horde's "Time" counter increases by one. When it reaches 10 or more, it is reduced by 10, and the Horde gets an additional "Intensity" emblem.
  • If the Horde gains life, nothing happens.

Sources:

Contributing

Deploying

Once you have write access to the repo, you should be able to run npm run deploy to deploy the current project to github pages.

mtg-horde's People

Contributors

dkniffin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

sambrodriguez

mtg-horde's Issues

Save/load game

This should be fairly easy. To save, we just need to download the current state as a json file, then to load, we just upload the json file, and use it for the initial state.

Show all attack damage

The horde tends to have lots of creatures. It takes a long time to add up all those creatures' damage each turn. We should have something showing all combat damage coming at the survivors. This will only really be possible after #22.

Card modal

When we click on a card, it should open the card in a larger view, with some buttons for different actions, such as discard, exile, tap, etc.

  • Big card view
  • "Send to Graveyard"
  • "Send to Exile"
  • "Send to Library"
  • "Tap"

Draw during turn doesn't go to field

Normally, the horde doesn't draw, but some cards cause it to. One such case is Syphon Mind. If that gets played during the horde turn, they should draw cards, then immediately play them. Right now, that won't happen.

Buffs and counters

It's really tiresome to keep track of all the counters and buffs on the horde's creatures. To alleviate that, we should add some data for each card for counters (ie: "put a +1/+1 counter on target creature"), permanent buffs (ie: "all other zombies get +1/+1"), and temporary buffs (ie: "target creature gets +1/+1 until end of turn"). Then, we can show the total power/toughness on the card, by adding the base and any counters.

Additional play phase logic

Right now, the play phase will simply move cards from pending to either play or graveyard, depending on type. We also need:

  • Play any cards in hand
  • Play any cards from the graveyard that have threshold

Ability to undo

This should be relatively easy. I think redux has something built in for stepping back one state. Things might be complicated by the fact that we have multiple events dispatched from one event. We don't want to undo to those intermediate states. For example, when we discard from hand, we send one event to remove from hand, and another to add to graveyard. We don't want to just remove from graveyard, and not put it back in hand.

Multiple variations

Right now, we only support one rule set, which is a combination of this and this. It'd be nice to let the user choose which rules to play with.

From the user perspective, I can see this done in a couple ways. We could have a drop down that the user chooses a ruleset, or we could have some checkboxes to enable/disable different rules. Or both, maybe.

From a technical perspective, we'll need to save the user's choice somewhere (probably in the state), and read from it wherever we need to.

Option for number of cards

200 cards is a really long game. We should have an option to drop this down to 100. I think this will need to be implemented as a deck chooser. So, we'd have a dropdown before the game starts, which allows the user to choose "Zombies - 200 cards" or "Zombies - 100 cards".

Attack phase

Write logic for the attack phase. All creatures should tap, and have some indication of which player/planeswalker they are attacking.

  • Tap all creatures

Allow users to create tokens

We need a way to create tokens, with any power/toughness.

  • Build component
  • Connect the component's +/- buttons to a stat counter in the state
  • Connect the spawn button to an action that creates the card and puts it in on the field.

Show a built-in life counter

This should have the ability to:

  • Start with 20 * numPlayers
  • Be able to increment/decrement, with an input field

Quick board wipe

Right now, if a card gets played like "destroy all creatures", you have to click on each one, and send it to the graveyard. It'd be much easier to have a buttons like "Send all creatures to graveyard". We'll need different ones depending on the board wipe, so probably one for each type of permanent (Creatures, Artifacts, Enchantments)

"Overwhelming numbers" logic

From here:

After much playing and experimenting, I have found that it is too hard to make the horde scale against multiple players without making it too hard for less players. The solution I have come to is a rule to increase the horde's strength over time.

The rule I currently have in place works as follows:

  • At the end of each horde turn, a counter is increased by 1 for each player in the game.
  • When this counter hits 10 or more, reduce it by 10, and give the horde an emblem.
  • The horde starts with 1 emblem.
  • The horde reveals cards until X non-token cards are revealed, where X is the number of these emblems they have.

With this rule, the players are "forced" to attack the horde, and the horde will be able to naturally overcome powerful player board states when it gets stronger.

Currently, X is always 1.

Big graveyard view

When you click the graveyard, it should show all cards in the graveyard, with some buttons to move them to different zones (exile, play, etc)

  • Modal with all graveyard cards
  • On card click, open card modal.

Tokens shouldn't go to graveyard

So, after losing a few times this weekend, I realized that this is an optional rule:

Allow tokens to remain in the graveyard instead of ceasing to exist.

It makes it much easier if that doesn't happen. I think we should make it a setting players can choose to play with.

Handle all card logic

For the mvp, the plan is to have the players deal with most of the logic of the cards in the deck. For 1.0, ideally all of the cards in the horde deck would handle themselves, and the players would only need to do things manually if they play something from their decks that affects the horde's board.

The way I foresee this working is having a function defined for each card, that gets triggered at each possible trigger point, and it will dispatch events depending on what it does.

Send card to top of library

Right now, you can "send to library", but that shuffles it into the library. We should change that button text to reflect the shuffle, and add a new one for "Send to top of library"

Poison

There's no indication in either of our sources for how poison should work, so I've decide on something on my own. Normally, 10 poison kills a player. In two-headed giant, 15 poison kills the team. Extrapolating from there, I think the equation should be 5+(5*numPlayers). We should say this somewhere. The readme is fine to start, but ideally we'd like to add a poison counter, to go with the life counter (#13)

Tutorial

When a user first visits the page, we should have a tutorial that walks them through the format, and how to use the app.

I think the best way to do this would be with masking, where have most of the screen go black (or blur or translucent), and show a circle around what you want to show. This is the best screenshot I could find showing what I'm talking about:
image

I was also thinking this would make a cool javascript library, where you would use CSS selectors to control where the mask would go. Something like:

import tutorialMask from 'awesomeNewMaskingLibrary'

tutorialMask('#graveyard', 'This is the graveyard. When cards are destroyed or discarded, they go here. In horde, you have to careful, because some cards will bring zombies back from the dead!')

Survivor's turn

Not much to do here, but we do need to discard down to 7 cards in hand.

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.