-
Автор темы
- #1
не все переменные скинул, если кому-то надо пишите скину
C++:
if (player->m_fFlags() & FL_ONGROUND && animstate->m_flUpdateTimeDelta) {
if (player->m_vecVelocity().Length2D() <= 1.1f) {
if (resolver_adjust->previous_layers[3].m_flWeight == 0.0f && resolver_adjust->previous_layers[3].m_flCycle == 0.0f && resolver_adjust->previous_layers[6].m_flWeight == 0.0f && animstate->m_flUpdateTimeDelta) {
// detection side.
auto angle_difference_delta = math::angle_diff(animstate->m_flEyeYaw, zero_goal_feet_yaw);
side = (2 * (angle_difference_delta <= 0.0) - 1) ? 1 : -1;
float yaw = animstate->m_flGoalFeetYaw;
auto delta = AngleDiff(player->m_angEyeAngles().y, yaw);
auto positive_resolver = (2 * (delta <= 0.1f) - 1) > 0.1f;
side = positive_resolver ? 1 : -1;
side = math::clamp((2 * (delta <= 0.f) - 1), -1, 1);// copysign(1, delta);
//lag_data->animations_updated = true;
}
else if ((abs(m_globals()->m_realtime) > 0.5f || resolver_adjust->previous_layers[7].m_flWeight >= 0.99f)
&& int(resolver_adjust->resolver_layers[0][6].m_flCycle * 10000.f) == int(resolver_adjust->previous_layers[6].m_flCycle * 10000.f))
{
float delta1 = abs(resolver_adjust->previous_layers[6].m_flPlaybackRate - resolver_adjust->resolver_layers[0][6].m_flPlaybackRate);
float delta2 = abs(resolver_adjust->previous_layers[6].m_flPlaybackRate - resolver_adjust->resolver_layers[2][6].m_flPlaybackRate);
float delta3 = abs(resolver_adjust->previous_layers[6].m_flPlaybackRate - resolver_adjust->resolver_layers[1][6].m_flPlaybackRate);
if (delta1 < delta3 || delta2 <= delta3 || (int)(float)(delta3 * 10000.0f))
{
if (delta1 >= delta2 && delta3 > delta2 && !(int)(float)(delta2 * 10000.0f))
{
side = 1;
lag_data->realtime = m_globals()->m_realtime;
m_bResolve = true;
//animstate->m_flGoalFeetYaw = math::NormalizedAngle(player->m_angEyeAngles().y + 60.f);//meme d1g
//negri pidori
}
}
else
{
side = -1;
lag_data->realtime = m_globals()->m_realtime;
m_bResolve = true;
//animstate->m_flGoalFeetYaw = math::NormalizedAngle(player->m_angEyeAngles().y - 60.f);//meme
}
if (delta1 <= delta2)
move_delta = delta1;
else
move_delta = delta2;
if (move_delta > delta3)
move_delta = delta2;
if (!(move_delta * 10000.f) && (delta3 * 10000.f) != (delta2 * 10000.f))
{
if (move_delta == delta3)
{
//v56 = -v56;
delta2 = delta3;
}
else if (move_delta == delta2)
{
delta3 = delta2;
}
}
}
Последнее редактирование: