Heroes 5 Wiki
Advertisement

The game supports a total of 221 skills. In the following example we will add a new skill with internal ID HERO_SKILL_AWESOME_SKILL

Change files

Skills.xdb

Open data.pak/GameMechanics/RefTables/Skills.xdb and add a new skill entry at the bottom of <Table_HeroSkill_SkillID><objects> item list. For example

<Item>
	<ID>HERO_SKILL_AWESOME_SKILL</ID>
	<obj>
		<Texture>
			<Item href="/Textures/HeroScreen/Perks/Invocation_EmpoweredSpells_grey.xdb#xpointer(/Texture)"/>
			<Item href="/Textures/HeroScreen/Perks/Invocation_EmpoweredSpells.xdb#xpointer(/Texture)"/>
		</Texture>
		<CommonTexture/>
		<NameFileRef>
 			<Item href="/Text/Game/Skills/Unique/Invocation/EmpoweredSpells/Name.txt"/>
 		</NameFileRef>
 		<CommonNameFileRef href=""/>
 		<DescriptionFileRef>
 			<Item href="/Text/Game/Skills/Unique/Invocation/EmpoweredSpells/Description.txt"/>
 		</DescriptionFileRef>
 		<CommonDescriptionFileRef href=""/>
		<SkillType>SKILLTYPE_STANDART_PERK</SkillType>
		<HeroClass>HERO_CLASS_NONE</HeroClass>
		<spellBuffs/>
		<BasicSkillID>HERO_SKILL_INVOCATION</BasicSkillID>
		<SkillPrerequisites/>
		<AIRacesValues>
			<Haven>
				<CommanderValue>4000</CommanderValue>
				<CollectorSupplierValue>3000</CollectorSupplierValue>
				<FreelancerValue>4000</FreelancerValue>
			</Haven>
			<Sylvan>
				<CommanderValue>4000</CommanderValue>
				<CollectorSupplierValue>3000</CollectorSupplierValue>
				<FreelancerValue>4000</FreelancerValue>
			</Sylvan>
			<Academy>
				<CommanderValue>4000</CommanderValue>
				<CollectorSupplierValue>3000</CollectorSupplierValue>
				<FreelancerValue>4000</FreelancerValue>
			</Academy>
			<Dungeon>
				<CommanderValue>4000</CommanderValue>
				<CollectorSupplierValue>3000</CollectorSupplierValue>
				<FreelancerValue>4000</FreelancerValue>
			</Dungeon>
			<Necropolis>
				<CommanderValue>4000</CommanderValue>
				<CollectorSupplierValue>3000</CollectorSupplierValue>
				<FreelancerValue>4000</FreelancerValue>
			</Necropolis>
			<Inferno>
				<CommanderValue>4000</CommanderValue>
				<CollectorSupplierValue>3000</CollectorSupplierValue>
				<FreelancerValue>4000</FreelancerValue>
			</Inferno>
			<Fortress>
				<CommanderValue>4000</CommanderValue>
				<CollectorSupplierValue>3000</CollectorSupplierValue>
				<FreelancerValue>4000</FreelancerValue>
			</Fortress>
			<Stronghold>
				<CommanderValue>0</CommanderValue>
				<CollectorSupplierValue>0</CollectorSupplierValue>
				<FreelancerValue>0</FreelancerValue>
			</Stronghold>
		</AIRacesValues>
		<PresetPrice>0</PresetPrice>
	</obj>
</Item>

Types.xml

In data.pak/Types.xml, find the location of <TypeName>SkillID</TypeName> and in the <Entries> section just below it add a new skill with value 221 (new entry in bold):

	<Item>
			<Name>HERO_SKILL_BARBARIAN_DARK_REVELATION</Name>   	     
			<Value>219</Value>
	</Item>
	<Item>
			<Name>HERO_SKILL_BARBARIAN_MENTORING</Name>
			<Value>220</Value>
	</Item>
	<Item>
			<Name>HERO_SKILL_AWESOME_SKILL</Name>
			<Value>221</Value>
	</Item>
</Entries>

In data.pak/Types.xml find <XPointer>/GameMechanics/RefTables/Skills.xdb#xpointer(/Table_HeroSkill_SkillID)</XPointer>

and in <EnumEntries> list just below it add the new skill internal id at the bottom.

	<Item>HERO_SKILL_BARBARIAN_DARK_REVELATION</Item>
	<Item>HERO_SKILL_BARBARIAN_MENTORING</Item>
	<Item>HERO_SKILL_AWESOME_SKILL</Item>
</EnumEntries>

In data.pak/Types.xml find item with Typename -> <TypeName>Table_HeroSkill_SkillID</TypeName> and in the <Attributes> branch just below it find Item with key <Key>ref_table_num_objs</Key>. Change its key from 221 to 222.

<TypeName>Table_HeroSkill_SkillID</TypeName>
	<EnclosingNamespace>00000000</EnclosingNamespace>
	<Attributes>
		<__ClassTypeID>270064327</__ClassTypeID>
		<__ObjectData>
			<Attributes>
				<Item>
					<Key>ref_table_is_pointer</Key>
					<Data>
 						<Type>04000000</Type>
 						<Data>false</Data>
 					</Data>
 				</Item>
 				<Item>
 					<Key>ref_table</Key>
 					<Data>
 						<Type>03000000</Type>
 						<Data/>
 					</Data>
 				</Item>
 				<Item>
 					<Key>ref_table_num_objs</Key>
 					<Data>
 						<Type>01000000</Type>
						<Data>222</Data>
					</Data>
 				</Item>


In data.pak/Types.xml find item with Typename -> <TypeName>Table_HeroSkill_SkillID</TypeName> and in the <Fields> section change <MinElements> and <MaxElements> to the new value of 222.

<Fields>
	<Item>
		<Type>340f4c29</Type>
		<Name>objects</Name>
		<ChunkID>2</ChunkID>
		<Description/>
		<Constraints>
			<Item>
				<__ClassTypeID>270062596</__ClassTypeID>
				<__ObjectData>
					<MinElements>222</MinElements>
					<MaxElements>222</MaxElements>
				</__ObjectData>
			</Item>
		</Constraints>
		<Attributes/>
		<DefaultValue>
			<Type>00000000</Type>
		</DefaultValue>
		<ComplexDefaultValue>
			<Type>00000000</Type>
		</ComplexDefaultValue>
	</Item>
</Fields>

Q binary

Do the following changes to increase skill slots from 221 to 222

 DD 00 00 00 8D 44 24 24  50 8D 4C 24 1C 51 68 FC to 
DE 00 00 00 8D 44 24 24  50 8D 4C 24 1C 51 68 FC


B8 DD 00 00 00 C3 CC CC  CC CC CC CC CC CC CC CC to
B8 DE 00 00 00 C3 CC CC  CC CC CC CC CC CC CC CC


28 E8 5A AC FF FF 8D 4C  24 24 51 8B 4E 04 68 DD to 
28 E8 5A AC FF FF 8D 4C  24 24 51 8B 4E 04 68 DE

ToE binary

Not yet found

Now you have a new slot to fill with a skill or perk!

Advertisement