Difference between revisions of "Creature Format"
From VCMI Project Wiki
(changed damage, advMapAmount syntax) |
|||
Line 21: | Line 21: | ||
"level" : 0, | "level" : 0, | ||
"faction" : "", // config name of faction. Examples: Castle, Rampart | "faction" : "", // config name of faction. Examples: Castle, Rampart | ||
− | "cost" : // cost, zero values can be omitted | + | "cost" : // cost, zero values can be omitted. Keys are the ids of the resources |
{ | { | ||
− | " | + | "Wood" : 0, |
− | " | + | "Mercury" : 0, |
− | " | + | "Ore" : 0, |
− | " | + | "Sulfur" : 0, |
− | " | + | "Crystal" : 0, |
− | " | + | "Gems" : 0, |
− | " | + | "Gold" : 0 |
}, | }, | ||
"fightValue" : 0, | "fightValue" : 0, | ||
Line 38: | Line 38: | ||
"attack" : 0, | "attack" : 0, | ||
"defence" : 0, | "defence" : 0, | ||
− | "damage" : | + | "damage" : |
− | "advMapAmount" : | + | { |
+ | "min" : 0, | ||
+ | "max" : 0 | ||
+ | }, | ||
+ | "advMapAmount" : | ||
+ | { | ||
+ | "min" : 0, | ||
+ | "max" : 0 | ||
+ | }, | ||
"graphics" : | "graphics" : | ||
{ | { | ||
Line 46: | Line 54: | ||
// optional | // optional | ||
− | "upgrades" : | + | "upgrades" : {}, // keys are ids of creatures that this can be upgraded to. Values are true or false |
"doubleWide" : false, | "doubleWide" : false, | ||
"shots" : 0, | "shots" : 0, | ||
Line 116: | Line 124: | ||
"level" : 1, | "level" : 1, | ||
"faction" : "Castle", | "faction" : "Castle", | ||
− | "upgrades" : | + | "upgrades" : |
− | "cost" : { " | + | { |
+ | "Halberdier" : true | ||
+ | }, | ||
+ | "cost" : | ||
+ | { | ||
+ | "Gold" : 60 | ||
+ | }, | ||
"fightValue" : 100, | "fightValue" : 100, | ||
"aiValue" : 80, | "aiValue" : 80, | ||
Line 125: | Line 139: | ||
"attack" : 4, | "attack" : 4, | ||
"defence" : 5, | "defence" : 5, | ||
− | "damage" : | + | "damage" : |
− | "advMapAmount" : | + | { |
− | "abilities" : | + | "min" : 1, |
+ | "max" : 3 | ||
+ | }, | ||
+ | "advMapAmount" : | ||
+ | { | ||
+ | "min" : 20, | ||
+ | "max" : 50 | ||
+ | }, | ||
+ | "abilities" : // this is subject to change | ||
{ | { | ||
"CHARGE_IMMUNITY" : {} | "CHARGE_IMMUNITY" : {} |
Revision as of 14:57, 26 August 2012
This is only a proposal and not official information by the VCMI team. See thread http://forum.vcmi.eu/viewtopic.php?t=533.
todo:
- remove deprecated attributes once implemented in town config
- better name for amm, something more self-documenting
- creature experience
Creature abilities use Bonus Format.
long version (83 lines):
{ "" : // name (for configs), should be camel case version of interface name. Examples: Pikeman, RoyalGriffin { // mandatory "name" : { "singular" : "", "plural" : "" }, "level" : 0, "faction" : "", // config name of faction. Examples: Castle, Rampart "cost" : // cost, zero values can be omitted. Keys are the ids of the resources { "Wood" : 0, "Mercury" : 0, "Ore" : 0, "Sulfur" : 0, "Crystal" : 0, "Gems" : 0, "Gold" : 0 }, "fightValue" : 0, "aiValue" : 0, "growth" : 0, "hitPoints" : 0, "speed" : 0, "attack" : 0, "defence" : 0, "damage" : { "min" : 0, "max" : 0 }, "advMapAmount" : { "min" : 0, "max" : 0 }, "graphics" : { "animation" : "" // name of def file }, // optional "upgrades" : {}, // keys are ids of creatures that this can be upgraded to. Values are true or false "doubleWide" : false, "shots" : 0, "spellPoints" : 0, "abilities" : { }, "graphics" : { "timeBetweenFidgets" : 1.00, "troopCountLocationOffset" : 0, "attackClimaxFrame" : 0, "animationTime" : { "walk" : 1.00, "attack" : 1.00, "flight" : 1.00 }, "background" : { "120" : "", // if empty, uses faction background "130" : "" // if empty, uses faction background }, "missile" : { "animation" : "", // name of def file for missile "spinning" : false, "offset" : { "upperX" : 0, "upperY" : 0, "middleX" : 0, "middleY" : 0, "lowerX" : 0, "lowerY" : 0 }, "frameAngles" : [] } }, "sound" : // names of sound files { "attack": "", "defend": "", "killed": "", "move": "", "shoot" : "", "wince": "", "moveStart" : "", "moveEnd" : "" }, // deprecated, move to town config "hordeGrowth" : 0, // growth bonus from horde building "turretShooter" : false // if used in turret }, // more creatures }
pikeman long (39 lines):
{ "Pikeman" : { "name" : { "singular" : "Pikeman", "plural" : "Pikemen" }, "level" : 1, "faction" : "Castle", "upgrades" : { "Halberdier" : true }, "cost" : { "Gold" : 60 }, "fightValue" : 100, "aiValue" : 80, "growth" : 14, "hitPoints" : 10, "speed" : 4, "attack" : 4, "defence" : 5, "damage" : { "min" : 1, "max" : 3 }, "advMapAmount" : { "min" : 20, "max" : 50 }, "abilities" : // this is subject to change { "CHARGE_IMMUNITY" : {} }, "graphics" : { "animation" : "CPKMAN.DEF", "animationTime" : { "walk" : 1.15 } }, "sound" : { "attack": "PIKEATTK.wav", "defend": "PIKEDFND.wav", "killed": "PIKEKILL.wav", "move": "PIKEMOVE.wav", "wince": "PIKEWNCE.wav" } } }