Difference between revisions of "Manual"
|Line 1:||Line 1:|
== Stats ==
== Stats ==
|Line 31:||Line 34:|
Revision as of 01:39, 19 July 2017
Stats are a fundamental concept in CCG Kit. They represent integer values that can change over the course of a game and are used in both players and cards. For example, a player could have life and mana stats and a creature card could have cost, attack and defense stats. Stats are transmitted over the network, which means you should only use them to represent values that can actually change over the course of a game in order to save bandwidth.
Stats have the following properties:
Stats are implemented by the Stat class.
You can think of keywords as enum-like stats. They are particularly useful if you need cards to have a field with a specific subset of possible values (like a static ability, which could take values such as "taunt" or "hexproof"). Just like stats, keywords are transmitted over the network.
Keywords are implemented by the Keyword class.
Properties are card values that are constant. Because they never change, they are never transmitted over the network (which helps saving bandwidth). Common examples of properties in a CCG are the card's name, its picture, its collector number, etc.