-
Автор темы
- #1
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
WARNING: DONT SAY IT'S WRONG IT'S MUCH BETTER THEN DEFAULT LEGENDWARE BONES
structs.cpp
animation_system.cpp
structs.cpp
C++:
if (!this) //-V704
return false;
auto setuped = false;
std::array < AnimationLayer, 13 > animation_layers;
float curtime = m_globals()->m_curtime;
float realtime = m_globals()->m_realtime;
float absoluteframetime = m_globals()->m_absoluteframetime;
float frametime = m_globals()->m_frametime;
float framecount = m_globals()->m_framecount;
float tickcount = m_globals()->m_tickcount;
float interpolation_amount = m_globals()->m_interpolation_amount;
m_globals()->m_curtime = this->m_flSimulationTime();
m_globals()->m_realtime = this->m_flSimulationTime();
m_globals()->m_frametime = m_globals()->m_intervalpertick;
m_globals()->m_absoluteframetime = m_globals()->m_intervalpertick;
m_globals()->m_framecount = TIME_TO_TICKS(this->m_flSimulationTime());
m_globals()->m_tickcount = TIME_TO_TICKS(this->m_flSimulationTime());
m_globals()->m_interpolation_amount = 0.0f;
const LPVOID inverse_kinematics = *(LPVOID*)(uintptr_t(this) + 0x2670);
const int client_effects = *(uint8_t*)(uintptr_t(this) + 0x68);
const int last_skip_framecount = *(int*)(uintptr_t(this) + 0xA68);
const int occlusion_mask = *(int*)(uintptr_t(this) + 0xA28);
const int occlusion_frame = *(int*)(uintptr_t(this) + 0xA30);
const int effects = this->m_fEffects();
const bool maintain_sequence_transition = *(bool*)(uintptr_t(this) + 0x9F0);
const Vector absoluteorigin = this->GetAbsOrigin();
std::memcpy(animation_layers.data(), this->get_animlayers(), sizeof(AnimationLayer) * 13);
this->invalidate_bone_cache();
this->m_BoneAccessor().m_ReadableBones = NULL;
this->m_BoneAccessor().m_WritableBones = NULL;
auto animstate = this->get_animation_state();
auto previous_weapon = animstate ? animstate->m_pLastActiveWeapon : nullptr;
if (previous_weapon)
animstate->m_pLastActiveWeapon = animstate->m_pActiveWeapon;
*(int*)(uintptr_t(this) + 0xA30) = 0;
*(int*)(uintptr_t(this) + 0xA28) = 0;
*(int*)(uintptr_t(this) + 0xA68) = 0;
if (this != g_ctx.local())
this->set_abs_origin(this->m_vecOrigin());
this->m_fEffects() |= 8;
*(uint8_t*)(uintptr_t(this) + 0x68) |= 2;
*(LPVOID*)(uintptr_t(this) + 0x2670) = nullptr;
*(bool*)(uintptr_t(this) + 0x2930) = false;
*(bool*)(uintptr_t(this) + 0x9F0) = false;
if (mask == BONE_USED_BY_HITBOX)
this->get_animlayers()[3].m_pOwner = NULL;
else if (this == g_ctx.local())
{
this->get_animlayers()[12].m_flWeight = 0.0f;
if (this->sequence_activity(this->get_animlayers()[3].m_nSequence) == ACT_CSGO_IDLE_TURN_BALANCEADJUST)
{
this->get_animlayers()[3].m_flCycle = 0.0f;
this->get_animlayers()[3].m_flWeight = 0.0f;
}
}
g_ctx.globals.setuping_bones = true;
setuped = SetupBones(matrix, MAXSTUDIOBONES, mask, this->m_flSimulationTime());
g_ctx.globals.setuping_bones = false;
*(bool*)(uintptr_t(this) + 0x9F0) = maintain_sequence_transition;
*(LPVOID*)(uintptr_t(this) + 0x2670) = inverse_kinematics;
*(uint8_t*)(uintptr_t(this) + 0x68) = client_effects;
this->m_fEffects() = effects;
*(int*)(uintptr_t(this) + 0xA68) = last_skip_framecount;
*(int*)(uintptr_t(this) + 0xA30) = occlusion_frame;
*(int*)(uintptr_t(this) + 0xA28) = occlusion_mask;
if (this != g_ctx.local())
set_abs_origin(absoluteorigin);
std::memcpy(this->get_animlayers(), animation_layers.data(), sizeof(AnimationLayer) * 13);
m_globals()->m_curtime = curtime;
m_globals()->m_realtime = realtime;
m_globals()->m_absoluteframetime = absoluteframetime;
m_globals()->m_frametime = frametime;
m_globals()->m_framecount = framecount;
m_globals()->m_tickcount = tickcount;
m_globals()->m_interpolation_amount = interpolation_amount;
return setuped;
C++:
switch (matrix)
{
case MAIN:
e->setup_bones_fixed(record->matrixes_data.main, BONE_USED_BY_ANYTHING);
break;
case FIRST:
e->setup_bones_fixed(record->matrixes_data.first, BONE_USED_BY_HITBOX);
break;
case NONE:
e->setup_bones_fixed(record->matrixes_data.zero, BONE_USED_BY_HITBOX);
break;
case SECOND:
e->setup_bones_fixed(record->matrixes_data.second, BONE_USED_BY_HITBOX);
break;
}