mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-24 22:14:36 +02:00
turned pathfinding effect into a bonus
This commit is contained in:
parent
c9ef773da0
commit
e8c32e05d8
@ -1,7 +1,53 @@
|
||||
{
|
||||
"pathfinding" : {
|
||||
"basic" : {
|
||||
"description" : "",
|
||||
"effects" : [
|
||||
{
|
||||
"subtype" : "skill.pathfinding",
|
||||
"type" : "SECONDARY_SKILL_PREMY",
|
||||
"val" : 25,
|
||||
"valueType" : "BASE_NUMBER"
|
||||
}
|
||||
]
|
||||
},
|
||||
"advanced" : {
|
||||
"description" : "",
|
||||
"effects" : [
|
||||
{
|
||||
"subtype" : "skill.pathfinding",
|
||||
"type" : "SECONDARY_SKILL_PREMY",
|
||||
"val" : 50,
|
||||
"valueType" : "BASE_NUMBER"
|
||||
}
|
||||
]
|
||||
},
|
||||
"expert" : {
|
||||
"description" : "",
|
||||
"effects" : [
|
||||
{
|
||||
"subtype" : "skill.pathfinding",
|
||||
"type" : "SECONDARY_SKILL_PREMY",
|
||||
"val" : 75,
|
||||
"valueType" : "BASE_NUMBER"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"estates" : {
|
||||
"basic" : {
|
||||
"description" : "Hero generates 250 gold each day.",
|
||||
"description" : "",
|
||||
"effects" : [
|
||||
{
|
||||
"subtype" : "skill.estates",
|
||||
"type" : "SECONDARY_SKILL_PREMY",
|
||||
"val" : 125,
|
||||
"valueType" : "BASE_NUMBER"
|
||||
}
|
||||
]
|
||||
},
|
||||
"advanced" : {
|
||||
"description" : "",
|
||||
"effects" : [
|
||||
{
|
||||
"subtype" : "skill.estates",
|
||||
@ -11,8 +57,8 @@
|
||||
}
|
||||
]
|
||||
},
|
||||
"advanced" : {
|
||||
"description" : "Hero generates 500 gold each day.",
|
||||
"expert" : {
|
||||
"description" : "",
|
||||
"effects" : [
|
||||
{
|
||||
"subtype" : "skill.estates",
|
||||
@ -21,17 +67,6 @@
|
||||
"valueType" : "BASE_NUMBER"
|
||||
}
|
||||
]
|
||||
},
|
||||
"expert" : {
|
||||
"description" : "Hero generates 1000 gold each day.",
|
||||
"effects" : [
|
||||
{
|
||||
"subtype" : "skill.estates",
|
||||
"type" : "SECONDARY_SKILL_PREMY",
|
||||
"val" : 1000,
|
||||
"valueType" : "BASE_NUMBER"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -217,6 +217,8 @@ const std::shared_ptr<Bonus> CSkillHandler::defaultBonus(SecondarySkill skill, i
|
||||
|
||||
switch (skill)
|
||||
{
|
||||
case SecondarySkill::PATHFINDING:
|
||||
bonusVal = 25 * level; break;
|
||||
case SecondarySkill::ARCHERY:
|
||||
bonusVal = 5 + 5 * level * level; break;
|
||||
case SecondarySkill::LOGISTICS:
|
||||
|
@ -87,7 +87,7 @@ ui32 CGHeroInstance::getTileCost(const TerrainTile &dest, const TerrainTile &fro
|
||||
else if(ti->nativeTerrain != from.terType && !ti->hasBonusOfType(Bonus::NO_TERRAIN_PENALTY, from.terType))
|
||||
{
|
||||
ret = VLC->heroh->terrCosts[from.terType];
|
||||
ret -= getSecSkillLevel(SecondarySkill::PATHFINDING) * 25;
|
||||
ret -= valOfBonuses(Selector::typeSubtype(Bonus::SECONDARY_SKILL_PREMY, SecondarySkill::PATHFINDING));
|
||||
if(ret < GameConstants::BASE_MOVEMENT_COST)
|
||||
ret = GameConstants::BASE_MOVEMENT_COST;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user