3 Commits
8 ... 14

Author SHA1 Message Date
Jadis0x
a462aa0afc Fix minor issues and add new feature
- Fixed crash issue that occurred after activating Azazel's speed and returning to the menu
- Added GetAzazelName() function
- Added Rank Spoofer
2024-06-25 23:23:37 +03:00
Jadis0x
af76512cf4 Add IsSequencePlaying helper function and enable NolanBehaviour in the lobby 2024-06-23 22:35:02 +03:00
3601c508cb fix: ESP crash in main menu
still crashes when leaving a game, Unity race conditions ig
2024-06-15 15:42:57 +02:00
7 changed files with 60 additions and 13 deletions

View File

@@ -67,6 +67,25 @@ bool IsInGame()
return false;
}
bool IsSequencePlaying()
{
app::Survival* survival = Object::FindObjectOfType<app::Survival>("Survival");
// Return false if the object was not found.
if (survival == nullptr) return false;
if (app::Survival_IsEndingPlaying != nullptr || app::Survival_IsJumpScarePlaying != nullptr || app::Survival_StartingToPlayFailEnding != nullptr) {
bool isEndingPlaying = app::Survival_IsEndingPlaying(survival, nullptr);
bool isJumpScarePlaying = app::Survival_IsJumpScarePlaying(survival, nullptr);
bool isStartingToPlayFailEnding = app::Survival_StartingToPlayFailEnding(survival, nullptr);
// Return true if any sequence is playing.
return isEndingPlaying || isJumpScarePlaying || isStartingToPlayFailEnding;
}
return false;
}
app::GameObject* GetAzazel(app::Survival* survival)
{
app::GameObject* ai = app::Survival_GetAzazel(survival, nullptr);
@@ -95,6 +114,18 @@ std::string SceneName()
return std::string("");
}
std::string GetAzazelName()
{
if (IsInGame()) {
app::InGameHelpers* inGameHelpers = app::InGameHelpers_get_singleton(nullptr);
if (inGameHelpers)
return il2cppi_to_string(app::InGameHelpers_GetAzazelName(inGameHelpers, nullptr));
}
return std::string("Azazel");
}
float Time_DeltaTime()
{

View File

@@ -8,8 +8,11 @@ bool IsLocalPlayer(app::NolanBehaviour* player);
bool IsPlayerCrawling();
bool IsPlayerCrawling(app::GameObject* go);
bool IsInGame();
bool IsSequencePlaying();
app::GameObject* GetAzazel(app::Survival* survival);
std::string SceneName();
std::string GetAzazelName();
float Time_DeltaTime();

View File

@@ -106,7 +106,6 @@ void ComputePositionAndDrawESP(app::Object_1__Array* ents, ImColor color, bool u
void ESP::RunAzazelESP() {
app::GameObject__Array* ents = Object::FindGameObjectsWithTag("Azazel");
//app::Object_1__Array *ents = Object::FindObjectsOfType("SurvivalAzazelBehaviour", "");
if (ents == NULL)
return;
@@ -128,6 +127,8 @@ void ESP::RunDemonESP() {
std::vector<std::string> demons_c = { "SurvivalDemonBehaviour", "SpiderBehaviour", "GhostBehaviour", "BoarBehaviour", "CorpseBehaviour" };
for (std::string& class_ : demons_c) {
if (SceneName() != "Menu")
return;
app::Object_1__Array *ents = Object::FindObjectsOfType(class_.c_str(), "");
if (ents == nullptr)
continue;
@@ -147,6 +148,8 @@ void ESP::RunItemsESP() {
ComputePositionAndDrawESP(ents, col, true);
}
if (SceneName() != "Menu")
return;
ents = Object::FindObjectsOfType("KeyBehaviour", "");
if (ents != nullptr && ents->vector[0] != nullptr) {
ComputePositionAndDrawESP(ents, col, false, "Key");

View File

@@ -319,15 +319,15 @@ void DrawMiscTab() {
if (ImGui::Button("Make random noise")) {
//Misc::PlayRandomSound();
}
ImGui::Checkbox("Walk in lobby", &settings::walk_in_lobby);
ImGui::Checkbox("Auto respawn", &settings::auto_respawn);
*/
ImGui::Checkbox("Spoof level", &settings::spoof_level);
ImGui::InputInt("New level", &settings::new_level);
*/
ImGui::Checkbox("EXP Modifier", &settings::exp_modifier);
ImGui::SliderInt("Amount", &settings::new_exp, 0, 5000);

View File

@@ -94,7 +94,7 @@ void Misc::InstantWin()
std::string _scene = SceneName();
if (_scene == std::string("Menu") && !IsHost() && !Player::GetLocalPlayer()) return;
if (_scene == std::string("Menu") || !IsHost() || !Player::GetLocalPlayer()) return;
int32_t progress = 10;
@@ -104,7 +104,6 @@ void Misc::InstantWin()
if (_MapController) {
// DO_APP_FUNC(0x00930CD0, void, MapController_SetProgressTo, (MapController * __this, int32_t progress, MethodInfo * method));
if (app::MapController_SetProgressTo != nullptr) {
app::MapController_SetProgressTo(_MapController, progress, nullptr);
}
@@ -116,7 +115,6 @@ void Misc::InstantWin()
if (_SlaughterhouseAltarController) {
// DO_APP_FUNC(0x0050DEB0, void, SlaughterhouseAltarController_SkipToGoat, (SlaughterhouseAltarController * __this, int32_t number, MethodInfo * method));
if (app::SlaughterhouseAltarController_SkipToGoat != nullptr) {
app::SlaughterhouseAltarController_SkipToGoat(_SlaughterhouseAltarController, progress, nullptr);
}
@@ -128,7 +126,6 @@ void Misc::InstantWin()
if (_SurvivalObjectBurnController) {
// DO_APP_FUNC(0x00562590, void, SurvivalObjectBurnController_SkipToGoat, (SurvivalObjectBurnController * __this, int32_t number, MethodInfo * method));
if (app::SurvivalObjectBurnController_SkipToGoat != nullptr) {
app::SurvivalObjectBurnController_SkipToGoat(_SurvivalObjectBurnController, progress, nullptr);
}

View File

@@ -94,6 +94,10 @@ typedef void(__stdcall* TNolanBehaviour_Update)(app::NolanBehaviour*, MethodInfo
TNolanBehaviour_Update oNolanBehaviour_Update = NULL;
void __stdcall hNolanBehaviour_Update(app::NolanBehaviour* __this, MethodInfo* method) {
if (settings::spoof_level && IsLocalPlayer(__this)) {
Misc::RankSpoofer(settings::new_level);
}
if (settings::fly && IsLocalPlayer(__this)) {
float speed = settings::fly_speed;
@@ -159,7 +163,7 @@ typedef void(__stdcall* TNolanBehaviour_FixedUpdate)(app::NolanBehaviour*, Metho
TNolanBehaviour_FixedUpdate oNolanBehaviour_FixedUpdate = NULL;
void __stdcall hNolanBehaviour_FixedUpdate(app::NolanBehaviour* __this, MethodInfo* method) {
if (settings::freeze_azazel && IsHost()) {
if (settings::freeze_azazel && IsHost() && IsInGame()) {
app::GameObject* goAzazel = __this->fields.m_Survival->fields.m_Azazel;
if (goAzazel) {
@@ -759,20 +763,19 @@ HRESULT __stdcall hookD3D11Present(IDXGISwapChain* pSwapChain, UINT SyncInterval
DrawMenu(open_menu);
}
// to-do: move it to "fixed update" hook
if (settings::player_esp)
ESP::RunPlayersESP();
if (settings::goat_esp)
if (settings::goat_esp && SceneName() != "Menu")
ESP::RunGoatsESP();
if (settings::item_esp)
if (settings::item_esp && SceneName() != "Menu")
ESP::RunItemsESP();
if (settings::demon_esp)
ESP::RunDemonESP();
if (settings::azazel_esp)
if (settings::azazel_esp && SceneName() != "Menu")
ESP::RunAzazelESP();
ImGui::GetIO().MouseDrawCursor = open_menu;

View File

@@ -21,6 +21,7 @@
#include "utils/utils.hpp"
#include "network/VersionControl.h"
#include "players/players.h"
#define CLIENT_VERSION "4.1"
@@ -146,8 +147,17 @@ void Run()
if (GetAsyncKeyState(VK_END) & 0x8000 || should_unhook)
break;
// enable "NolanBehaviour" in the lobby so the client can use fly mode
if (SceneName() == std::string("Menu")) {
if (Player::GetLocalPlayer() != nullptr) {
app::NolanBehaviour* nolan = Player::GetNolan();
if (nolan != nullptr) {
if (!Object::Enabled(nolan)) Object::Enabled(nolan, true);
}
}
}
std::this_thread::sleep_for(std::chrono::milliseconds(1000));
std::this_thread::sleep_for(std::chrono::milliseconds(3000));
}
CreateThread(0, 0, EjectThread, 0, 0, 0);
}