feat(Self): Add local visibility option (#116)
This commit is contained in:
parent
be7e00f4f6
commit
98c5596864
@ -15,5 +15,20 @@ namespace big
|
|||||||
|
|
||||||
bLastInvisibility = g->self.invisibility;
|
bLastInvisibility = g->self.invisibility;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (NETWORK::NETWORK_IS_SESSION_STARTED())
|
||||||
|
{
|
||||||
|
if (g->self.invisibility && g->self.local_visibility)
|
||||||
|
{
|
||||||
|
NETWORK::SET_ENTITY_LOCALLY_VISIBLE(PLAYER::PLAYER_PED_ID());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (g->self.local_visibility)
|
||||||
|
{
|
||||||
|
ENTITY::SET_ENTITY_VISIBLE(PLAYER::PLAYER_PED_ID(), true, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -21,4 +21,4 @@ namespace big
|
|||||||
lastOverride = true;
|
lastOverride = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -122,9 +122,10 @@ namespace big
|
|||||||
bool free_cam = false;
|
bool free_cam = false;
|
||||||
bool godmode = false;
|
bool godmode = false;
|
||||||
bool invisibility = false;
|
bool invisibility = false;
|
||||||
|
bool local_visibility = true;
|
||||||
bool never_wanted = false;
|
bool never_wanted = false;
|
||||||
bool noclip = false;
|
|
||||||
bool no_ragdoll = false;
|
bool no_ragdoll = false;
|
||||||
|
bool noclip = false;
|
||||||
bool off_radar = false;
|
bool off_radar = false;
|
||||||
bool super_run = false;
|
bool super_run = false;
|
||||||
int wanted_level = 0;
|
int wanted_level = 0;
|
||||||
@ -382,8 +383,9 @@ namespace big
|
|||||||
this->self.clean_player = j["self"]["clean_player"];
|
this->self.clean_player = j["self"]["clean_player"];
|
||||||
this->self.godmode = j["self"]["godmode"];
|
this->self.godmode = j["self"]["godmode"];
|
||||||
this->self.invisibility = j["self"]["invisibility"];
|
this->self.invisibility = j["self"]["invisibility"];
|
||||||
this->self.no_ragdoll = j["self"]["no_ragdoll"];
|
this->self.local_visibility = j["self"]["local_visibility"];
|
||||||
this->self.never_wanted = j["self"]["never_wanted"];
|
this->self.never_wanted = j["self"]["never_wanted"];
|
||||||
|
this->self.no_ragdoll = j["self"]["no_ragdoll"];
|
||||||
this->self.off_radar = j["self"]["off_radar"];
|
this->self.off_radar = j["self"]["off_radar"];
|
||||||
this->self.super_run = j["self"]["super_run"];
|
this->self.super_run = j["self"]["super_run"];
|
||||||
|
|
||||||
@ -553,6 +555,7 @@ namespace big
|
|||||||
{ "clean_player", this->self.clean_player },
|
{ "clean_player", this->self.clean_player },
|
||||||
{ "godmode", this->self.godmode },
|
{ "godmode", this->self.godmode },
|
||||||
{ "invisibility", this->self.invisibility },
|
{ "invisibility", this->self.invisibility },
|
||||||
|
{ "local_visibility", this->self.local_visibility },
|
||||||
{ "never_wanted", this->self.never_wanted },
|
{ "never_wanted", this->self.never_wanted },
|
||||||
{ "no_ragdoll", this->self.no_ragdoll },
|
{ "no_ragdoll", this->self.no_ragdoll },
|
||||||
{ "off_radar", this->self.off_radar },
|
{ "off_radar", this->self.off_radar },
|
||||||
|
@ -32,6 +32,11 @@ namespace big
|
|||||||
ImGui::BeginGroup();
|
ImGui::BeginGroup();
|
||||||
|
|
||||||
ImGui::Checkbox("Invisibility", &g->self.invisibility);
|
ImGui::Checkbox("Invisibility", &g->self.invisibility);
|
||||||
|
if (g->self.invisibility)
|
||||||
|
{
|
||||||
|
ImGui::Checkbox("Locally Visible", &g->self.local_visibility);
|
||||||
|
}
|
||||||
|
|
||||||
ImGui::Checkbox("Keep Player Clean", &g->self.clean_player);
|
ImGui::Checkbox("Keep Player Clean", &g->self.clean_player);
|
||||||
if (ImGui::Button("Clean Player"))
|
if (ImGui::Button("Clean Player"))
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user