Table of Contents
Card Engine
  Cards
  Expansions
  Card Types
  Casting
  Discarding

Card Engine

The Card Engine takes care of the listing, the casting and the purchasing of Cards within the Game. The cards are objects and it's up to the client on how to present this to the player. For an example of the output of Cards in the Astralis Client see the image on the left.

Cards

Each card has a set of required properties as well as some optional ones. For example required properties on Cards are caption, name, casting_cost, etc. For the complete overview of properties Cards can have, please refer to the API. Cards can only be cast if the Prophet is not busy. Discarding cards is possible at any moment.

The casting cost for a card is a nested Tuple, each entry within the Tuple contains a Resource and the number of Resources required for casting. See the example below.

# You will require 3 Board and 1 Stone in order to play this card.
casting_cost = (('Board', 3), ('Stone', 1), )

You can get the full set of Cards per booster pack by calling get_all_cards on the Card engine. With the python BlockingGameClient? it would look as follows to get all cards from the Genesis booster pack.

>>> b = BlockingGameClient()
>>> b.connect()
>>> cards = b.game('card.get_all_cards', 'genesis')
>>> print cards[0]
{'__Card__': {'fields': {'description': '', 'receive': [['Gold', 100]], 'image': 'placeholder', 'expansion': 'genesis', 'turn_end': False, 'caption': 'Desert Nomads', 'produce': None, 'id': '1', 'type': 'item', 'casting_cost': [['Water', 50], ['actions', 1]], 'alignment': None, 'name': 'nomad1'} } }
>>>

Expansions

Each Card within the Game is placed within an Expansion set, the Player can acquire new cards by purchasing booster packs. At the moment Booster packs are set to contain 10 cards with the following distribution of Card types: Five Spell cards, two Building cards, two Item cards and either one Enchantment or one Artefact. This is currently under consideration and the distribution will probably change in the near feature.

Booster packs are bought through IN-GAME CURRENCY only. This is not a pay-to-win game. As such, with the current settings, a starting player will be able to purchase two Booster packs of the Genesis-expansion with their starting Gold.

In order to get the list of different expansion booster packs which are currently defined within Empyreal you can call get_boosters on the Card engine. See an example from the python BlockingGameClient? below.

>>> b = BlockingGameClient()
>>> b.connect()
>>> print b.game('card.get_boosters')
[{'available': True, 'caption': 'Genesis', 'name': 'genesis', 'gold': 500, 'faith': 7500}, {'available': False, 'caption': 'Aeolian', 'name': 'aeolian', 'gold': 750, 'faith': 15000}, {'available': False, 'caption': 'Inquisition', 'name': 'inquisition', 'gold': 1500, 'faith': None}]
>>>

Each expansion pack will have the boolean available set on them, which informs the Client on whether or not the booster is actually available for purchase. In case you try to purchase a booster for an expansion which is currently unavailable an EmpyrealException is thrown.

Card Types

Spells

The Spell cards are the most used cards within the game. They provide one time effects that can influence the game world and your alignment towards the Holy or Unholy side. Spells often have Faith points as their casting cost, most spells will also end the users turn.

An example spell card is Preach. The description reads Rallies up to 20 Residents to believe in your Deity.. You can see an example card to the right, taken from the Astralis Client.

The effect of this card is semi-random. The card will always influence Residents with a maximum of 20 different ones. The minimum is currently not listed on the card but that might be changed in the future. Each of the affected Residents will gain a little believe in the players Religion.

The casting cost for the Preach card is 500 Faith and 1 Action point, casting the card will also end your turn. This particular Spell card grants the user points for their Holy alignment.

In addition to the description of the Spell card, some of them also have a chance to have a critical effect. This means that the effect of the card is stronger, which for example can mean more Residents are affected by it or; more faith points are awarded for each of the Spells affected Residents.

NOTE: critical effects are currently not passed along with the Card objects, this might change in the future.

Buildings

In order for the player to get their Production lines going they will need to have Buildings at your location(s). Construction of Buildings is done with Building cards.

After a building card has been cast, the corresponding Building is constructed in the players current Location. Buildings are unoccupied upon construction, a worker will automatically be assigned within a few turns (if there are available Residents at the City). Once a Building is occupied Production can commence.

Items

NOTE: the title "Items" is still under consideration and might be changed to Resource in the future.

Enchantments

Artefacts

Casting

In order to be able to cast a card there are a few requirements for the player. The most obvious is that they have to have enough of the Resources mentioned as the Casting cost of the card. If the player does not have the required Resources, trying to cast the card will result with a raised Exception. For the full requirements for casting cards refer to the empyreal.engine.card.CardController API page.

Discarding

All cards within the players Deck can be discarded even if the player is busy. At the moment the return "reward" for discarding a card is 100 Faith and 10 Gold.


See also: Server, empyreal.engine.card