feat(info): Added Another Godmode Check And Health Info (#839)

This commit is contained in:
TheGreenBandit 2023-01-26 13:41:47 -05:00 committed by GitHub
parent 2ce44e8d98
commit f1c0092956
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 2 deletions

View File

@ -94,7 +94,6 @@ namespace big
return m_is_friend;
}
bool player::is_valid() const
{
return m_net_game_player == nullptr ? false : m_net_game_player->is_valid();

View File

@ -27,6 +27,8 @@ namespace big
uint32_t ped_damage_bits = 0;
uint32_t ped_task_flag = 0;
uint32_t ped_health = 0;
uint32_t ped_maxhealth = 0;
uint32_t veh_damage_bits = 0;
std::string mode_str = "";
@ -34,6 +36,8 @@ namespace big
{
ped_damage_bits = ped->m_damage_bits;
ped_task_flag = ped->m_ped_task_flag;
ped_health = ped->m_health;
ped_maxhealth = ped->m_maxhealth;
}
if (ped_damage_bits & (uint32_t)eEntityProofs::GOD)
@ -50,6 +54,10 @@ namespace big
{
mode_str += "Explosion, ";
}
if (ped_health > 328 || ped_maxhealth > 328 && !(uint32_t)eEntityProofs::EXPLOSION && !(uint32_t)eEntityProofs::BULLET)
{
mode_str += "Unnatural Health";
}
}
if (mode_str.empty())
@ -142,6 +150,7 @@ namespace big
ImGui::Text("Money In Bank: %d", stats.Money - stats.WalletBalance);
ImGui::Text("Total Money: %d", stats.Money);
ImGui::Text("Rank: %d (RP %d)", stats.Rank, stats.RP);
ImGui::Text("Health: %d (MaxHealth: %d)", ped_health, ped_maxhealth);
ImGui::Text("K/D Ratio: %f", stats.KdRatio);
ImGui::Text("Kills On Players: %d", stats.KillsOnPlayers);
ImGui::Text("Deaths By Players: %d", stats.DeathsByPlayers);
@ -181,4 +190,4 @@ namespace big
ImGui::TreePop();
}
}
}
}