Difference between revisions of "Creature Format"

From VCMI Project Wiki
Jump to: navigation, search
m (double week property added)
Line 442: Line 442:
 
"abilities" :
 
"abilities" :
 
[
 
[
Bonus Format
+
"someName1" : Bonus Format,
 +
"someName2" : Bonus Format
 
],
 
],
  
"hasDoubleWeek": true, //since 0.92
+
"hasDoubleWeek": true,
 
 
 
"graphics" :
 
"graphics" :
 
{
 
{
 
// name of file with creature battle animation
 
// name of file with creature battle animation
"animation" : ""  
+
"animation" : "",
 +
// adventure map animation def
 +
"map" : "",
 +
// path to small icon for tooltips & hero exchange window
 +
"iconSmall" : "",
 +
// path to large icon, used on town screen and in hero screen
 +
"iconLarge" : "",
 
 
 
// animation parameters
 
// animation parameters
Line 456: Line 463:
 
"timeBetweenFidgets" : 1.00,
 
"timeBetweenFidgets" : 1.00,
 
"troopCountLocationOffset" : 0,
 
"troopCountLocationOffset" : 0,
"attackClimaxFrame" : 0,
 
 
"animationTime" :
 
"animationTime" :
 
{
 
{
Line 467: Line 473:
 
// name of file for missile
 
// name of file for missile
 
"animation" : "",  
 
"animation" : "",  
// missile should spin, e.g. for throwing axes
+
// Frame at which projectile should appear
"spinning" : false,
+
"attackClimaxFrame" : 0,
 
"offset" :
 
"offset" :
 
{
 
{
Line 478: Line 484:
 
"lowerY" : 0
 
"lowerY" : 0
 
},
 
},
 +
// angles from which frames in .def file were rendered, -90...90 range
 
"frameAngles" : []
 
"frameAngles" : []
 
}
 
}
Line 491: Line 498:
 
"shoot" : "",
 
"shoot" : "",
 
"wince": "",
 
"wince": "",
"moveStart" : "",
+
"startMoving" : "",
"moveEnd" : ""
+
"endMoving" : ""
 
}
 
}
 
}
 
}

Revision as of 23:13, 20 May 2013

See thread http://forum.vcmi.eu/viewtopic.php?t=533 for discussion.

// camelCase unique creature identifier
"creatureName" : 
{
	// translatable names
	"name" :
	{
		"singular" : "Creature",
		"plural" : "Creatures"
	},
	"level" : 0,
	
	// config name of faction. Examples: castle, rampart
	"faction" : "", 
	// cost to recruit, zero values can be omitted.
	"cost" : 
	{
		"wood" : 0,
		"mercury" : 0,
		"ore" : 0,
		"sulfur" : 0,
		"crystal" : 0,
		"gems" : 0,
		"gold" : 0
	},
	// "value" of creature, used to determine for example army strength
	"fightValue" : 0,

	// "ai value" - how valuable this creature should be for AI
	"aiValue" : 0,
	
	// normal growth in town or external dwellings
	"growth" : 0,
	
	// growth bonus from horde building
	// TODO: reconsider need of this field after configurable buildings support
	"hordeGrowth" : 0,
	
	// Creature stats in battle
	"attack" : 0,
	"defence" : 0,
	"hitPoints" : 0,
	"shots" : 0,
	"speed" : 0,
	"damage" :
	{
		"min" : 0,
		"max" : 0
	},
	// spellpoints this creature has, how many times creature may cast its spells
	"spellPoints" : 0,
	// initial size of creature army on adventure map
	"advMapAmount" :
	{
		"min" : 0,
		"max" : 0
	},
	
	// Creature to which this creature can be upgraded
	// Note that only one upgrade can be available from UI
	"upgrades" :
	[
		"anotherCreature"
	],

	// Creature is 2-tiles in size on the battlefield
	"doubleWide" : false,

	// All creature abilities, using bonus format
	"abilities" :
	[
		"someName1" : Bonus Format,
		"someName2" : Bonus Format
	],

	"hasDoubleWeek": true,
	
	"graphics" :
	{
		// name of file with creature battle animation
		"animation" : "",
		// adventure map animation def
		"map" : "",
		// path to small icon for tooltips & hero exchange window
		"iconSmall" : "",
		// path to large icon, used on town screen and in hero screen
		"iconLarge" : "",
		
		// animation parameters
		// TODO: explain meaning and use them by engine
		"timeBetweenFidgets" : 1.00,
		"troopCountLocationOffset" : 0,
		"animationTime" :
		{
			"walk" : 1.00,
			"attack" : 1.00,
			"flight" : 1.00
		},
		"missile" :
		{
			// name of file for missile
			"animation" : "", 
			// Frame at which projectile should appear
			"attackClimaxFrame" : 0,
			"offset" :
			{
				"upperX" : 0,
				"upperY" : 0,
				"middleX" : 0,
				"middleY" : 0,
				"lowerX" : 0,
				"lowerY" : 0
			},
			// angles from which frames in .def file were rendered, -90...90 range
			"frameAngles" : []
		}
	},

	// names of sound files
	"sound" : 
	{
		"attack": "",
		"defend": "",
		"killed": "",
		"move": "",
		"shoot" : "",
		"wince": "",
		"startMoving" : "",
		"endMoving" : ""
	}
}


Modding related articles

Main articles
Modding changelog Modding guidelines How to create a town mod Mod Handler


Formats
Mod file Format
Town Format Creature Format Hero Classes Format
Artifact Format Animation Format Hero Format
Bonus Format Object Format Spell Format


Work-in-progress formats
Building bonuses Map format
Bonus Type Format Random map template


Outdated pages
Mod system proposal