fgslm
Recruit

could you add the ability to support the app to work on win Xp?
could you add the ability to support the app to work on win Xp?
void mbMissile::computePath()
{
m_hitType = mht_none;
m_hitHorse = false;
m_hitMissionObjectNo = -1;
m_hitAgentNo = -1;
m_hitBoneNo = -1;
m_attack.clear();
#if !defined DEDICATED_SERVER
m_screenState = mss_none;
m_soundChannel = -1;
if (m_startingDirection.dot(g_mission->m_cameraTransform.o - m_curPosition) > 0.1f)
m_screenState = mss_incoming;
#endif
rglVector4 position = m_startingPosition;
rglVector4 direction = m_startingDirection;
float speed = m_speed;
rglVector4 clientPosition = m_startingClientPosition;
rglVector4 clientDirection = m_startingClientVelocity;
float clientSpeed = clientDirection.normalize();
bool noFriction = false;
bool noGravity = false;
float friction = rglConfig::Battle::fAirFrictionArrow;
float timeFactor = 1.0f / 50.0f;
float gravityFactor = 9.8f / 50.0f;
if (m_missileItem.isValid())
{
mbItemKind *missileItemKind = m_missileItem.getItemKind();
if (missileItemKind->m_properties & itp_ignore_friction)
noFriction = true;
else if (missileItemKind->getType() == itp_type_bullets)
friction = rglConfig::Battle::fAirFrictionBullet;
if (missileItemKind->m_properties & itp_ignore_gravity)
noGravity = true;
}
m_path[0] = position;
m_prevPath = 0;
m_curPath = 1;
for (int i = 1; i < MB_MISSILE_PATH_SIZE; ++i)
{
rglVector4 newDirection = direction * speed;
rglVector4 newClientDirection = clientDirection * clientSpeed;
if (!noGravity)
{
newDirection.z -= gravityFactor;
newClientDirection.z -= gravityFactor;
}
position += newDirection * timeFactor;
clientPosition += newClientDirection * timeFactor;
if (i >= 25)
m_path[i] = position;
else
m_path[i] = (position * (float)i + clientPosition * (float)(25 - i)) * 0.04f;
float newSpeed = newDirection.normalize();
float newClientSpeed = newClientDirection.normalize();
if (!noFriction)
{
newSpeed = newSpeed - newSpeed * newSpeed * friction * timeFactor;
newClientSpeed = newClientSpeed - newClientSpeed * newClientSpeed * friction * timeFactor;
}
if (newSpeed > 0.00001f)
direction = newDirection;
if (newClientSpeed > 0.00001f)
clientDirection = newClientDirection;
speed = newSpeed;
clientSpeed = newClientSpeed;
}
}
This is interesting! Is there a config option to determine how far until it switches over, or it fixed to a set distance?1.0.5.2
-Added sf_use_next_for_far sound flag.
float distance = (m_transform.o - soundChannel.m_position).length();
float distanceFactor = 1.0f;
for (int i = 1; i < 5 && sound->m_flags & sf_use_next_for_far && distance > 15.0f && soundNo < (m_numSounds - i); ++i)
{
soundNo++;
sound = &m_sounds[soundNo];
distance *= 0.3f;
distanceFactor *= 0.35f;
}
soundChannel.m_position = m_transform.o + (soundChannel.m_position - m_transform.o) * distanceFactor;
1.0.5.2
-Added WFaS build.
-Added bMoreProficiencyEffectForMovingSpeedWhileReloading config option.
-Added sf_use_next_for_far sound flag.
-Fixed sf_always_send_via_network sound flag.
-Fixed sound bugs.
-Fixed backpedal speed.
Note for WFaS
Since the WFaS does not have necessary network events, for compatibility following Warband features works only when bBreakWarbandCompatibility=true:
-Separate audio channel for agent_play_sound and agent_stop_sound operations.
-Network sync for agent_set_accuracy_modifier, agent_set_speed_modifier, agent_set_reload_speed_modifier, agent_set_use_speed_modifier operations.
Thanks to DoDoCat for sponsoring development.
?1.0.5.2
-Added WFaS build.
Thank you for quick update.Fixed reloading bug - only one projectile was loaded, regardless of weapons max ammo.
(store_agent_hit_points, reg10, ":agent_id"),
(ti_on_agent_spawn, 0, 0, [],
[
(store_trigger_param_1, ":agent_no"),
(call_script, "script_multiplayer_server_on_agent_spawn_common", ":agent_no"),
(try_begin),
(agent_is_human, ":agent_no"),
(store_agent_hit_points, reg50, ":agent_no", 0),
(assign, reg51, ":agent_no"),
(display_message, "@Agent ID: {reg51 }HP: {reg50}", green),
(try_end),