|
|
@ -1504,9 +1504,152 @@ static void generate_labor_to_skill_map()
|
|
|
|
labor_to_skill[labor] = skill;
|
|
|
|
labor_to_skill[labor] = skill;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
struct skill_attr_weight {
|
|
|
|
|
|
|
|
int phys_attr_weights [6];
|
|
|
|
|
|
|
|
int mental_attr_weights [13];
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
static struct skill_attr_weight skill_attr_weights[ENUM_LAST_ITEM(job_skill) + 1] =
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
// S A T E R D AA F W C I P M LA SS M KS E SA
|
|
|
|
|
|
|
|
{ { 1, 0, 1, 1, 0, 0 }, { 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0 } } /* MINING */,
|
|
|
|
|
|
|
|
{ { 1, 1, 0, 1, 0, 0 }, { 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0 } } /* WOODCUTTING */,
|
|
|
|
|
|
|
|
{ { 1, 1, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* CARPENTRY */,
|
|
|
|
|
|
|
|
{ { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* DETAILSTONE */,
|
|
|
|
|
|
|
|
{ { 1, 1, 0, 1, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* MASONRY */,
|
|
|
|
|
|
|
|
{ { 0, 1, 1, 1, 0, 0 }, { 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0 } } /* ANIMALTRAIN */,
|
|
|
|
|
|
|
|
{ { 0, 1, 0, 0, 0, 0 }, { 1, 0, 0,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, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* MATHEMATICS */,
|
|
|
|
|
|
|
|
{ { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* ASTRONOMY */,
|
|
|
|
|
|
|
|
{ { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* CHEMISTRY */,
|
|
|
|
|
|
|
|
{ { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* GEOGRAPHY */,
|
|
|
|
|
|
|
|
{ { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* OPTICS_ENGINEER */,
|
|
|
|
|
|
|
|
{ { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* FLUID_ENGINEER */,
|
|
|
|
|
|
|
|
{ { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* PAPERMAKING */,
|
|
|
|
|
|
|
|
{ { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } } /* BOOKBINDING */
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
static void enable_plugin(color_ostream &out)
|
|
|
|
static void enable_plugin(color_ostream &out)
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -2147,6 +2290,7 @@ private:
|
|
|
|
{
|
|
|
|
{
|
|
|
|
int skill_level = 0;
|
|
|
|
int skill_level = 0;
|
|
|
|
int xp = 0;
|
|
|
|
int xp = 0;
|
|
|
|
|
|
|
|
int attr_weight = 0;
|
|
|
|
|
|
|
|
|
|
|
|
if (labor != df::unit_labor::NONE)
|
|
|
|
if (labor != df::unit_labor::NONE)
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -2155,10 +2299,16 @@ private:
|
|
|
|
{
|
|
|
|
{
|
|
|
|
skill_level = Units::getEffectiveSkill(d->dwarf, skill);
|
|
|
|
skill_level = Units::getEffectiveSkill(d->dwarf, skill);
|
|
|
|
xp = Units::getExperience(d->dwarf, skill, false);
|
|
|
|
xp = Units::getExperience(d->dwarf, skill, false);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for (int pa = 0; pa < 6; pa++)
|
|
|
|
|
|
|
|
attr_weight += (skill_attr_weights[skill].phys_attr_weights[pa]) * (d->dwarf->body.physical_attrs[pa].value - 1000);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for (int ma = 0; ma < 13; ma++)
|
|
|
|
|
|
|
|
attr_weight += (skill_attr_weights[skill].mental_attr_weights[ma]) * (d->dwarf->status.current_soul->mental_attrs[ma].value - 1000);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
int score = skill_level * 1000 - (d->high_skill - skill_level) * 2000 + (xp / (skill_level + 5) * 10);
|
|
|
|
int score = skill_level * 1000 - (d->high_skill - skill_level) * 2000 + (xp / (skill_level + 5) * 10) + attr_weight;
|
|
|
|
|
|
|
|
|
|
|
|
if (labor != df::unit_labor::NONE)
|
|
|
|
if (labor != df::unit_labor::NONE)
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -2176,6 +2326,8 @@ private:
|
|
|
|
score += 5000;
|
|
|
|
score += 5000;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
score -= Units::computeMovementSpeed(d->dwarf);
|
|
|
|
|
|
|
|
|
|
|
|
return score;
|
|
|
|
return score;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|