agent_set_item_slot_ammo
Thanks, it worked. And native operator agent_set_ammo works too.
agent_set_item_slot_ammo
Where are the pdb files? Do you have any insructions?Also wse2 now inlcude pdb files for simplify debug.
If I am not misstaken, none of both skills give a missile speed bonus, they give merely a damage bonus.Hi, can you tell what is missile speed bonus applied by power_throw and power_draw skills?
float mbAgent::getMissileSpeed()
{
float missileSpeed = 10.0f;
float speedFactor = 1.0f;
mbItem item = getWieldedItem(ah_primary);
if (item.isValid())
{
mbItemKind *itemKind = item.getItemKind();
missileSpeed = (float)itemKind->getMissileSpeed();
if (itemKind->getType() == itp_type_bow)
{
speedFactor = rglMin(g_game->getTroopSkill(m_troopNo, skl_power_draw, true), item.getDifficulty() + 4) * 0.12f + 1.0f;
if (m_horseAgentNo != -1)
speedFactor *= g_game->getTroopSkill(m_troopNo, skl_horse_archery, true) * 0.019f + 0.8f;
if (g_mission->m_weather.m_precipitationType == wpr_rain)
speedFactor *= 0.9f;
}
else if (itemKind->getType() == itp_type_crossbow)
{
if (g_mission->m_weather.m_precipitationType == wpr_rain)
speedFactor *= 0.75f;
}
else if (itemKind->getType() == itp_type_thrown)
{
speedFactor = g_game->getTroopSkill(m_troopNo, skl_power_throw, true) * 0.1f + 1.0f;
if (m_horseAgentNo != -1)
speedFactor *= g_game->getTroopSkill(m_troopNo, skl_horse_archery, true) * 0.019f + 0.8f;
}
}
return rglSqrt(speedFactor) * missileSpeed * 1.2f;
}
The physic is bad. When you shoot on the horse while moving forward horse's speed added to missile speed. But when you shoot to the sides the missile will not change it's course. The only delay is caused by animation of releasing bow. I mean original engine. In WSE the physic is changed. I haven't explored it a lot. Example of changes when you run forward and throw a javeline at the standing horse you will get speed_damage_multiplier bonus but in the vanilla you will not.If I am not misstaken, none of both skills give a missile speed bonus, they give merely a damage bonus.
Thanks for the explanation, I was not aware that it differs so much between WSE and Native. I assume then that the formula above is not the same for Native, @K700 ?The physic is bad. When you shoot on the horse while moving forward horse's speed added to missile speed. But when you shoot to the sides the missile will not change it's course. The only delay is caused by animation of releasing bow. I mean original engine. In WSE the physic is changed. I haven't explored it a lot. Example of changes when you run forward and throw a javeline at the standing horse you will get speed_damage_multiplier bonus but in the vanilla you will not.
The formula above works for vanila.Thanks for the explanation, I was not aware that it differs so much between WSE and Native. I assume then that the formula above is not the same for Native, @K700 ?