PHP Code:
void noOverheat()
{
ClientPlayer *mySoldier = ClientGameContext::GetInstance()->m_pPlayerManager->m_pLocalPlayer;
if (IsValidPtr(mySoldier))
{
ClientSoldierEntity* p_cSE = mySoldier->GetClientSoldier();
if (IsValidPtr(p_cSE))
{
ClientSoldierWeaponsComponent *p_swCmp = p_cSE->m_soldierWeaponsComponent;
if (IsValidPtr(p_swCmp))
{
ClientSoldierWeapon *p_csw = p_swCmp->GetActiveSoldierWeapon();
if (IsValidPtr(p_csw))
{
WeaponFiring *wFiring = p_csw->m_pPrimary;
if (IsValidPtr(wFiring))
{
wFiring->m_isOverheated = false;
}
}
}
}
}
}
But it doesn't work :L What am I doing wrong?
Aucun commentaire:
Enregistrer un commentaire