Escalation Project
-
Автор темы
- #1
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
C++:
auto fire_first = autowall::get().wall_penetration(globals.g.eye_pos, player->hitbox_position_matrix(HITBOX_HEAD, player_record->matrixes_data.first), player);
auto fire_second = autowall::get().wall_penetration(globals.g.eye_pos, player->hitbox_position_matrix(HITBOX_HEAD, player_record->matrixes_data.second), player);
auto fire_third = autowall::get().wall_penetration(globals.g.eye_pos, player->hitbox_position_matrix(HITBOX_HEAD, player_record->matrixes_data.zero), player);
// Hold the line, don't forget
// Taking arms is taking heads
// Hold the line, don't forget
// Taking arms is taking heads
// антипаста для самых глупых
if (layers[3].m_flWeight == 0.f && layers[3].m_flCycle == 0.f)
{
Vector src3D, dst3D, forward, right, up, src, dst;
float back_two, right_two, left_two;
CGameTrace tr;
CTraceFilter filter;
Vector RightPose(player->m_angEyeAngles().x, player->m_angEyeAngles().y - player->get_max_desync_delta(), player->m_angEyeAngles().z);
Vector LeftPose(player->m_angEyeAngles().x, player->m_angEyeAngles().y + player->get_max_desync_delta(), player->m_angEyeAngles().z);
math::angle_vectors(Vector(0, get_backward_side(player), 0), &forward, &right, &up);
src3D = player->get_shoot_position();
dst3D = src3D + (forward * 384);
/* back engine tracers */
m_trace()->TraceRay(Ray_t(src3D, dst3D), MASK_SHOT, &filter, &tr);
fire_third.damage = (tr.endpos - tr.startpos).Length();
/* right engine tracers */
m_trace()->TraceRay(Ray_t(src3D + RightPose * 35, dst3D + RightPose * 35), MASK_SHOT, &filter, &tr);
fire_first.damage = (tr.endpos - tr.startpos).Length();
/* left engine tracers */
m_trace()->TraceRay(Ray_t(src3D - RightPose * 35, dst3D - RightPose * 35), MASK_SHOT, &filter, &tr);
fire_second.damage = (tr.endpos - tr.startpos).Length();
if (fire_first.damage > 0.0f && fire_second.damage > 0.0f)
{
int freestand_side;
if (fire_first.damage > fire_second.damage || fire_first.damage > fire_third.damage)
{
freestand_side = 1;
if (freestand_side == 1)
animstate->m_flGoalFeetYaw = math::normalize_yaw(player->m_angEyeAngles().y - 58.f);
switch (globals.g.missed_shots[i] % 1)
{
case 0:
animstate->m_flGoalFeetYaw = math::normalize_yaw(player->m_angEyeAngles().y + 58.f);
break;
default:
break;
}
}
else if (fire_first.damage < fire_second.damage || fire_second.damage > fire_third.damage)
{
freestand_side = -1;
if (freestand_side == -1)
animstate->m_flGoalFeetYaw = math::normalize_yaw(player->m_angEyeAngles().y + 58.f);
switch (globals.g.missed_shots[i] % 1)
{
case 0:
animstate->m_flGoalFeetYaw = math::normalize_yaw(player->m_angEyeAngles().y - 58.f);
break;
default:
break;
}
}
else
{
freestand_side = 0;
animstate->m_flGoalFeetYaw = math::normalize_yaw(player->m_angEyeAngles().y - 0.f);
}
}
}
Последнее редактирование: