-
Автор темы
- #1
C++:
auto anim_state = ent->AnimState();
auto layer = ent->AnimOverlays();
static bool side[65];
staticfloat_t old_weight[65];
float resolve_yaw;
auto eye_yaw = anim_state->m_flEyeYaw;
if (layer[3].m_flCycle == 0.f && layer[3].m_flWeight == 0.f)
resolve_yaw = eye_yaw + 60;
if (layer[3].m_flCycle == 0.012329f && layer[3].m_flWeight == 0.043137f)
resolve_yaw = eye_yaw - 60;
if (anim_state->speed_2d > 0.1f) {
old_weight[ent->EntIndex()] = layer[6].m_flWeight;
if (layer[6].m_flWeight = !old_weight[ent->EntIndex()])
resolve_yaw = eye_yaw + 60;
}
if (resolve_yaw == 0) {
resolve_yaw = eye_yaw + (side ? desync_delta(ent) : -desync_delta(ent));
if (obam::globals::missed_last_shot)
side[ent->EntIndex()] = !side[ent->EntIndex()];
}
else anim_state->m_flGoalFeetYaw = resolve_yaw;
Последнее редактирование модератором: