Skip to content
This repository was archived by the owner on Dec 26, 2021. It is now read-only.

Add its needed #4551

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions Horion.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -36,39 +36,39 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<SpectreMitigation>false</SpectreMitigation>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v141</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='BetaConf|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v141</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
<SpectreMitigation>false</SpectreMitigation>
<WholeProgramOptimization>true</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization>
<SpectreMitigation>false</SpectreMitigation>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='BetaConf|x64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization>
<SpectreMitigation>false</SpectreMitigation>
Expand Down Expand Up @@ -653,4 +653,4 @@
<Error Condition="!Exists('packages\Microsoft.XAudio2.Redist.1.2.0\build\native\Microsoft.XAudio2.Redist.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\Microsoft.XAudio2.Redist.1.2.0\build\native\Microsoft.XAudio2.Redist.targets'))" />
<Error Condition="!Exists('packages\directxtk_desktop_2017.2020.2.24.4\build\native\directxtk_desktop_2017.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\directxtk_desktop_2017.2020.2.24.4\build\native\directxtk_desktop_2017.targets'))" />
</Target>
</Project>
</Project>
2 changes: 1 addition & 1 deletion Horion/Module/Modules/AntiVoid.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const char* AntiVoid::getModuleName() {
return ("AntiVoid");
}

void AntiVoid::onTick(C_GameMode* gm) {
void AntiVoid::onLevelRender() {
C_LocalPlayer* player = g_Data.getLocalPlayer();
vec3_t blockBelow = player->eyePos0;
blockBelow.y -= player->height;
Expand Down
2 changes: 1 addition & 1 deletion Horion/Module/Modules/AntiVoid.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ class AntiVoid : public IModule {

// Inherited via IModule
virtual const char* getModuleName() override;
virtual void onTick(C_GameMode* gm) override;
virtual void onLevelRender() override;
};
2 changes: 1 addition & 1 deletion Horion/Module/Modules/AutoTotem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const char* AutoTotem::getModuleName() {
return ("AutoTotem");
}

void AutoTotem::onTick(C_GameMode* gm) {
void AutoTotem::onLevelRender() {
C_PlayerInventoryProxy* supplies = g_Data.getLocalPlayer()->getSupplies();
C_Inventory* inv = supplies->inventory;
C_InventoryTransactionManager* manager = g_Data.getLocalPlayer()->getTransactionManager();
Expand Down
2 changes: 1 addition & 1 deletion Horion/Module/Modules/AutoTotem.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ class AutoTotem : public IModule {
~AutoTotem();

virtual const char* getModuleName() override;
virtual void onTick(C_GameMode* gm) override;
virtual void onLevelRender() override;
};
10 changes: 5 additions & 5 deletions Horion/Module/Modules/ChestAura.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,24 +12,24 @@ const char* ChestAura::getModuleName() {
return ("ChestAura");
}

void ChestAura::onTick(C_GameMode* gm) {
void ChestAura::onLevelRender() {
if (g_Data.getLocalPlayer()->getSupplies()->inventory->isFull())
return;

vec3_t* pos = gm->player->getPos();
vec3_t* pos = g_Data.getCGameMode()->player->getPos();
for (int x = (int)pos->x - range; x < pos->x + range; x++) {
for (int z = (int)pos->z - range; z < pos->z + range; z++) {
for (int y = (int)pos->y - range; y < pos->y + range; y++) {
vec3_ti pos = vec3_ti(x, y, z);
C_Block* block = gm->player->region->getBlock(pos);
C_Block* block = g_Data.getCGameMode()->player->region->getBlock(pos);
if (block != nullptr && g_Data.canUseMoveKeys()) {
auto id = gm->player->region->getBlock(pos)->toLegacy()->blockId;
auto id = g_Data.getCGameMode()->player->region->getBlock(pos)->toLegacy()->blockId;
bool open = false;
if (id == 54) open = true; // Chests
if (id == 130 && enderchests) open = true; // EnderCheats
if (open)
if (!(std::find(chestlist.begin(), chestlist.end(), pos) != chestlist.end())) {
gm->buildBlock(&pos, 0);
g_Data.getCGameMode()->buildBlock(&pos, 0);
chestlist.push_back(pos);
return;
}
Expand Down
2 changes: 1 addition & 1 deletion Horion/Module/Modules/ChestAura.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@ class ChestAura : public IModule {

// Inherited via IModule
virtual const char* getModuleName() override;
virtual void onTick(C_GameMode* gm) override;
virtual void onLevelRender() override;
virtual void onDisable() override;
};
6 changes: 3 additions & 3 deletions Horion/Module/Modules/CrystalAura.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ void CrystalAura::DestroyC(C_Entity* ent, int range) {
}

bool shouldChange = false;
void CrystalAura::onTick(C_GameMode* gm) {
void CrystalAura::onLevelRender() {
if (shouldChange) {
shouldChange = false;
}
Expand Down Expand Up @@ -148,11 +148,11 @@ void CrystalAura::onTick(C_GameMode* gm) {
if (autoplace && g_Data.getLocalPlayer()->getSelectedItemId() == 629) { //endcrystal
if (pEnhanced)
for (auto& i : targetList)
CPlace(gm, i->getPos());
CPlace(g_Data.getCGameMode(), i->getPos());
else {
auto ptr = g_Data.getClientInstance()->getPointerStruct();
if (ptr->getEntity() == nullptr && ptr->rayHitType == 0)
CPlace(gm, &ptr->block.toFloatVector());
CPlace(g_Data.getCGameMode(), &ptr->block.toFloatVector());
}
}
return;
Expand Down
2 changes: 1 addition & 1 deletion Horion/Module/Modules/CrystalAura.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class CrystalAura : public IModule {

// Inherited via IModule
virtual const char* getModuleName() override;
virtual void onTick(C_GameMode* gm) override;
virtual void onLevelRender() override;
virtual void onPreRender(C_MinecraftUIRenderContext* renderCtx) override;
virtual void onEnable() override;
virtual void onDisable() override;
Expand Down
2 changes: 1 addition & 1 deletion Horion/Module/Modules/Freecam.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,4 @@ void Freecam::onDisable() {
*g_Data.getClientInstance()->minecraft->timer = 20.f;
plr->aabb.upper = plr->aabb.lower.add(oldOffset);
}
}
}
21 changes: 11 additions & 10 deletions Horion/Module/Modules/Jesus.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,23 @@ const char* Jesus::getModuleName() {
return "Jesus";
}

void Jesus::onTick(C_GameMode* gm) {
if (gm->player->isSneaking()) return;
void Jesus::onLevelRender() {
C_LocalPlayer* player = g_Data.getLocalPlayer();
if (player->isSneaking()) return;

if (gm->player->hasEnteredWater()) {
gm->player->velocity.y = 0.06f;
gm->player->onGround = true;
if (player->hasEnteredWater()) {
player->velocity.y = 0.06f;
player->onGround = true;
wasInWater = true;
} else if (gm->player->isInWater() || gm->player->isInLava()) {
gm->player->velocity.y = 0.1f;
gm->player->onGround = true;
} else if (player->isInWater() || player->isInLava()) {
player->velocity.y = 0.1f;
player->onGround = true;
wasInWater = true;
} else {
if (wasInWater) {
wasInWater = false;
gm->player->velocity.x *= 1.2f;
gm->player->velocity.x *= 1.2f;
player->velocity.x *= 1.2f;
player->velocity.x *= 1.2f;
}
}
}
2 changes: 1 addition & 1 deletion Horion/Module/Modules/Jesus.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ class Jesus :
~Jesus();
// Inherited via IModule
virtual const char* getModuleName() override;
virtual void onTick(C_GameMode* gm) override;
virtual void onLevelRender() override;
};

2 changes: 1 addition & 1 deletion Horion/Module/Modules/Scaffold.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ bool Scaffold::findBlock() {
return false;
}

void Scaffold::onTick(C_GameMode* gm) {
void Scaffold::onLevelRender() {
if (g_Data.getLocalPlayer() == nullptr)
return;
if (!g_Data.canUseMoveKeys())
Expand Down
2 changes: 1 addition & 1 deletion Horion/Module/Modules/Scaffold.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ class Scaffold : public IModule {

// Inherited via IModule
virtual const char* getModuleName() override;
virtual void onTick(C_GameMode* gm) override;
virtual void onLevelRender() override;
virtual void onDisable() override;
};
2 changes: 1 addition & 1 deletion Horion/Module/Modules/Xray.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const char* Xray::getModuleName() {
return ("Xray");
}

void Xray::onTick(C_GameMode* gm) {
void Xray::onLevelRender() {
if (smoothLightningSetting != nullptr) {
if (!gotSmoothInfo) {
gotSmoothInfo = true;
Expand Down
2 changes: 1 addition & 1 deletion Horion/Module/Modules/Xray.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ class Xray : public IModule {

// Inherited via IModule
virtual const char* getModuleName() override;
virtual void onTick(C_GameMode* gm) override;
virtual void onLevelRender() override;
virtual void onDisable() override;
};