Skip to content

Commit

Permalink
Merge pull request #144 from ByteCorum/WIP
Browse files Browse the repository at this point in the history
Visual fixes and changes
  • Loading branch information
ByteCorum authored Sep 21, 2024
2 parents 0d79afc + 6186161 commit e0c643e
Show file tree
Hide file tree
Showing 22 changed files with 36,642 additions and 2,725 deletions.
Binary file added Assets/NotoSans_Condensed-Bold.ttf
Binary file not shown.
12 changes: 10 additions & 2 deletions DragonBurn/Config/ConfigMenu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,6 @@ namespace ConfigMenu {
MenuConfig::WindowStyle = 0;
ESPConfig::ShowPreview = true;
ESPConfig::ShowHeadBox = true;
ESPConfig::HeadBoxStyle = 0;
ESPConfig::HeadBoxColor = ImColor(131, 137, 150, 180);

ESPConfig::ShowDistance = false;
Expand All @@ -173,7 +172,6 @@ namespace ConfigMenu {
LegitBotConfig::HitboxUpdated = false;

ESPConfig::BoxType = 0;
ESPConfig::HealthBarType = 0;
ESPConfig::BoneColor = ImColor(131, 137, 150, 180);
ESPConfig::BoxColor = ImColor(59, 71, 148, 180);
ESPConfig::EyeRayColor = ImVec4(0, 98, 98, 255);
Expand Down Expand Up @@ -253,5 +251,15 @@ namespace ConfigMenu {

LegitBotConfig::FovCircleColor = ImColor(131, 137, 150, 180);

MenuConfig::MarkWinPos = ImVec2(ImGui::GetIO().DisplaySize.x - 300.0f, 100.f);
MenuConfig::RadarWinPos = ImVec2(0.f, 0.f);
MenuConfig::SpecWinPos = ImVec2(10.0f, ImGui::GetIO().DisplaySize.y / 2 - 200);
MenuConfig::BombWinPos = ImVec2((ImGui::GetIO().DisplaySize.x - 200.0f) / 2.0f, 80.0f);

MenuConfig::MarkWinChengePos = true;
MenuConfig::BombWinChengePos = true;
MenuConfig::RadarWinChengePos = true;
MenuConfig::SpecWinChengePos = true;

}
}
38 changes: 34 additions & 4 deletions DragonBurn/Config/ConfigSaver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ namespace MyConfigSaver
ConfigData["ESP"]["FilledVisBox"]= ESPConfig::FilledVisBox;
ConfigData["ESP"]["MultiColor"]= ESPConfig::MultiColor;
ConfigData["ESP"]["OutLine"]= ESPConfig::OutLine;
ConfigData["ESP"]["HeadBoxStyle"]= ESPConfig::HeadBoxStyle;
ConfigData["ESP"]["BoxRounding"]= ESPConfig::BoxRounding;
ConfigData["ESP"]["ShowScoped"]= ESPConfig::ShowIsScoped;
ConfigData["ESP"]["ArmorBar"]= ESPConfig::ArmorBar;
Expand Down Expand Up @@ -214,6 +213,18 @@ namespace MyConfigSaver
ConfigData["Misc"]["TeamCheck"]= MenuConfig::TeamCheck;
ConfigData["Misc"]["AntiRecord"]= MenuConfig::BypassOBS;

ConfigData["MenuConfig"]["MarkWinPos"]["x"] = MenuConfig::MarkWinPos.x;
ConfigData["MenuConfig"]["MarkWinPos"]["y"] = MenuConfig::MarkWinPos.y;

ConfigData["MenuConfig"]["BombWinPos"]["x"] = MenuConfig::BombWinPos.x;
ConfigData["MenuConfig"]["BombWinPos"]["y"] = MenuConfig::BombWinPos.y;

ConfigData["MenuConfig"]["RadarWinPos"]["x"] = MenuConfig::RadarWinPos.x;
ConfigData["MenuConfig"]["RadarWinPos"]["y"] = MenuConfig::RadarWinPos.y;

ConfigData["MenuConfig"]["SpecWinPos"]["x"] = MenuConfig::SpecWinPos.x;
ConfigData["MenuConfig"]["SpecWinPos"]["y"] = MenuConfig::SpecWinPos.y;

configFile << ConfigData.dump(4);
configFile.close();
}
Expand Down Expand Up @@ -373,6 +384,8 @@ namespace MyConfigSaver
LegitBotConfig::VisibleCheck = ReadData(ConfigData["Aimbot"],{"VisibleCheck"}, true);
AimControl::IgnoreFlash = ReadData(ConfigData["Aimbot"],{"IgnoreFlash"}, false);
AimControl::ScopeOnly = ReadData(ConfigData["Aimbot"],{"ScopeOnly"}, false);
AimControl::SetHotKey(LegitBotConfig::AimBotHotKey);
LegitBotConfig::HitboxUpdated = false;
}

if (ConfigData.contains("RCS"))
Expand All @@ -391,6 +404,7 @@ namespace MyConfigSaver
TriggerBot::ScopeOnly = ReadData(ConfigData["Triggerbot"],{"ScopeOnly"}, false);
TriggerBot::IgnoreFlash = ReadData(ConfigData["Triggerbot"],{"IgnoreFlash"}, false);
LegitBotConfig::TriggerAlways = ReadData(ConfigData["Triggerbot"],{"AutoMode"}, false);
TriggerBot::SetHotKey(LegitBotConfig::TriggerHotKey);
}

if (ConfigData.contains("Misc"))
Expand Down Expand Up @@ -421,8 +435,24 @@ namespace MyConfigSaver
MenuConfig::BypassOBS = ReadData(ConfigData["Misc"],{"AntiRecord"}, false);
}

AimControl::SetHotKey(LegitBotConfig::AimBotHotKey);
TriggerBot::SetHotKey(LegitBotConfig::TriggerHotKey);
LegitBotConfig::HitboxUpdated = false;
if (ConfigData.contains("MenuConfig"))
{
MenuConfig::MarkWinPos.x = ReadData(ConfigData["MenuConfig"], { "MarkWinPos","x" }, ImGui::GetIO().DisplaySize.x - 300.0f);
MenuConfig::MarkWinPos.y = ReadData(ConfigData["MenuConfig"], { "MarkWinPos","y" }, 100.f);

MenuConfig::BombWinPos.x = ReadData(ConfigData["MenuConfig"], { "BombWinPos","x" }, (ImGui::GetIO().DisplaySize.x - 200.0f) / 2.0f);
MenuConfig::BombWinPos.y = ReadData(ConfigData["MenuConfig"], { "BombWinPos","y" }, 80.0f);

MenuConfig::RadarWinPos.x = ReadData(ConfigData["MenuConfig"], { "RadarWinPos","x" }, 0.f);
MenuConfig::RadarWinPos.y = ReadData(ConfigData["MenuConfig"], { "RadarWinPos","y" }, 0.f);

MenuConfig::SpecWinPos.x = ReadData(ConfigData["MenuConfig"], { "SpecWinPos","x" }, 10.0f);
MenuConfig::SpecWinPos.y = ReadData(ConfigData["MenuConfig"], { "SpecWinPos","y" }, ImGui::GetIO().DisplaySize.y / 2 - 200);

MenuConfig::MarkWinChengePos = true;
MenuConfig::BombWinChengePos = true;
MenuConfig::RadarWinChengePos = true;
MenuConfig::SpecWinChengePos = true;
}
}
}
11 changes: 10 additions & 1 deletion DragonBurn/Core/Cheats.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,9 @@ void Radar(Base_Radar Radar, const CEntity& LocalEntity)
if ((RadarCFG::ShowRadar && LocalEntity.Controller.TeamID != 0) || (RadarCFG::ShowRadar && MenuConfig::ShowMenu))
{
Radar.Render();

MenuConfig::RadarWinPos = ImGui::GetWindowPos();
ImGui::End();
}
}

Expand Down Expand Up @@ -287,10 +290,16 @@ void RadarSetting(Base_Radar& Radar)
ImGui::SetNextWindowBgAlpha(RadarCFG::RadarBgAlpha);
ImGui::Begin("Radar", 0, ImGuiWindowFlags_NoResize);
ImGui::SetWindowSize({ RadarCFG::RadarRange * 2,RadarCFG::RadarRange * 2 });
ImGui::SetWindowPos(MenuConfig::RadarWinPos, ImGuiCond_Once);

if (MenuConfig::RadarWinChengePos)
{
ImGui::SetWindowPos("Radar", MenuConfig::RadarWinPos);
MenuConfig::RadarWinChengePos = false;
}

if (!RadarCFG::customRadar)
{
ImGui::SetWindowPos(ImVec2(0, 0));
RadarCFG::ShowRadarCrossLine = false;
RadarCFG::Proportion = 3300.f;
RadarCFG::RadarPointSizeProportion = 1.f;
Expand Down
18 changes: 12 additions & 6 deletions DragonBurn/Core/Config.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
namespace MenuConfig
{
inline std::string name = "DragonBurn";
inline std::string version = "2.0.2.5";
inline std::string version = "2.0.3.0";
inline std::string author = "ByteCorum";

inline std::string path = "";
inline std::string docPath = "";
inline int RenderFPS = 1000000.0f;
inline int RenderFPS = 10000.0f;
inline int RenderDistance = 1000;


Expand All @@ -35,6 +35,15 @@ namespace MenuConfig
inline bool TeamCheck = true;
inline bool BypassOBS = false;
inline bool WorkInSpec = true;

inline ImVec2 MarkWinPos;
inline ImVec2 RadarWinPos;
inline ImVec2 SpecWinPos;
inline ImVec2 BombWinPos;
inline bool MarkWinChengePos = false;
inline bool RadarWinChengePos = false;
inline bool SpecWinChengePos = false;
inline bool BombWinChengePos = false;
}

namespace LegitBotConfig
Expand Down Expand Up @@ -86,11 +95,8 @@ namespace ESPConfig
inline bool MultiColor = false;
inline bool OutLine = true;
inline bool ShowIsScoped = true;
// 0: normal 1: dynamic 2: Flat
// 0: normal 1: Corner
inline int BoxType = 0;
// 0: Vertical 1: Horizontal
inline int HealthBarType = 0;
inline int HeadBoxStyle = 0;
inline float BoxRounding = 5;
inline bool ShowLineToEnemy = false;
inline ImColor LineToEnemyColor = ImColor(59, 71, 148,180);
Expand Down
31 changes: 22 additions & 9 deletions DragonBurn/Core/GUI.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,11 @@ namespace GUI
Gui.LoadTextureFromMemory(Images::AimbotButtonPressed, sizeof Images::AimbotButtonPressed, &MenuButton2Pressed, &buttonW, &buttonH);
Gui.LoadTextureFromMemory(Images::MiscButtonPressed, sizeof Images::MiscButtonPressed, &MenuButton3Pressed, &buttonW, &buttonH);
Gui.LoadTextureFromMemory(Images::ConfigButtonPressed, sizeof Images::ConfigButtonPressed, &MenuButton4Pressed, &buttonW, &buttonH);

MenuConfig::MarkWinPos = ImVec2(ImGui::GetIO().DisplaySize.x - 300.0f, 100.f);
MenuConfig::RadarWinPos = ImVec2(0.f, 0.f);
MenuConfig::SpecWinPos = ImVec2(10.0f, ImGui::GetIO().DisplaySize.y / 2 - 200);
MenuConfig::BombWinPos = ImVec2((ImGui::GetIO().DisplaySize.x - 200.0f) / 2.0f, 80.0f);
}
}

Expand Down Expand Up @@ -301,19 +306,18 @@ namespace GUI
ImGui::SetCursorPos(ImVec2(15.f, 24.f));
ImGui::SeparatorText("ESP");
float MinRounding = 0.f, MaxRouding = 5.f;
int MinCombo = 0, MaxCombo = 2;
PutSwitch(Text::ESP::Toggle.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::ESPenabled);
if (ESPConfig::ESPenabled)
{
const char* LinePos[] = { Text::ESP::LinePos_1.c_str(), Text::ESP::LinePos_2.c_str(), Text::ESP::LinePos_3.c_str()};
PutSwitch(Text::ESP::Box.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::ShowBoxESP, true, "###BoxCol", reinterpret_cast<float*>(&ESPConfig::BoxColor));
if (ESPConfig::ShowBoxESP)
{
PutSwitch(Text::ESP::Outline.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::OutLine);
ImGui::TextDisabled(Text::ESP::BoxType.c_str());
ImGui::SameLine();
ImGui::SetNextItemWidth(165.f);
ImGui::Combo("###BoxType", &ESPConfig::BoxType, "Normal\0Dynamic\0Corner\0");
AlignRight(160.f);
ImGui::SetNextItemWidth(160.f);
ImGui::Combo("###BoxType", &ESPConfig::BoxType, "Normal\0Corner\0");
PutSliderFloat(Text::ESP::BoxRounding.c_str(), 10.f, &ESPConfig::BoxRounding, &MinRounding, &MaxRouding, "%.1f");
}
PutSwitch(Text::ESP::FilledBox.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::FilledBox, true, "###FilledBoxCol", reinterpret_cast<float*>(&ESPConfig::FilledColor));
Expand All @@ -322,8 +326,14 @@ namespace GUI
PutSwitch(Text::ESP::HeadBox.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::ShowHeadBox, true, "###HeadBoxCol", reinterpret_cast<float*>(&ESPConfig::HeadBoxColor));
PutSwitch(Text::ESP::Skeleton.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::ShowBoneESP, true, "###BoneCol", reinterpret_cast<float*>(&ESPConfig::BoneColor));
PutSwitch(Text::ESP::SnapLine.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::ShowLineToEnemy, true, "###LineCol", reinterpret_cast<float*>(&ESPConfig::LineToEnemyColor));
if (ESPConfig::ShowLineToEnemy)
PutSliderInt(Text::ESP::LinePosList.c_str(), 10.f, &ESPConfig::LinePos, &MinCombo, &MaxCombo, LinePos[ESPConfig::LinePos]);
if (ESPConfig::ShowLineToEnemy)
{
ImGui::TextDisabled(Text::ESP::LinePosList.c_str());
ImGui::SameLine();
AlignRight(160.f);
ImGui::SetNextItemWidth(160.f);
ImGui::Combo("###LinePos", &ESPConfig::LinePos, "Top\0Center\0Bottom\0");
}
PutSwitch(Text::ESP::EyeRay.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::ShowEyeRay, true, "###LineCol", reinterpret_cast<float*>(&ESPConfig::EyeRayColor));
PutSwitch(Text::ESP::HealthBar.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &ESPConfig::ShowHealthBar);
if (ESPConfig::ShowHealthBar)
Expand Down Expand Up @@ -416,7 +426,8 @@ namespace GUI
ImGui::SetCursorPosX(ImGui::GetCursorPosX() + 10.f);
ImGui::TextDisabled(Text::Aimbot::HotKeyList.c_str());
ImGui::SameLine();
ImGui::SetNextItemWidth(165.f);
AlignRight(160.f);
ImGui::SetNextItemWidth(160.f);
if (ImGui::Combo("###AimKey", &LegitBotConfig::AimBotHotKey, "LALT\0LBUTTON\0RBUTTON\0XBUTTON1\0XBUTTON2\0CAPITAL\0SHIFT\0CONTROL\0"))
{
AimControl::SetHotKey(LegitBotConfig::AimBotHotKey);
Expand Down Expand Up @@ -555,7 +566,8 @@ namespace GUI
ImGui::SetCursorPosX(ImGui::GetCursorPosX() + 5.f);
ImGui::TextDisabled(Text::Trigger::HotKeyList.c_str());
ImGui::SameLine();
ImGui::SetNextItemWidth(170.f);
AlignRight(160.f);
ImGui::SetNextItemWidth(160.f);
if (ImGui::Combo("###TriggerbotKey", &LegitBotConfig::TriggerHotKey, "LALT\0RBUTTON\0XBUTTON1\0XBUTTON2\0CAPITAL\0SHIFT\0CONTROL\0"))
{
TriggerBot::SetHotKey(LegitBotConfig::TriggerHotKey);
Expand Down Expand Up @@ -586,7 +598,8 @@ namespace GUI
ImGui::SetCursorPosX(ImGui::GetCursorPosX() + 10.f);
ImGui::TextDisabled(Text::Misc::HitSound.c_str());
ImGui::SameLine();
ImGui::SetNextItemWidth(155.f);
AlignRight(160.f);
ImGui::SetNextItemWidth(160.f);
ImGui::Combo("###HitSounds", &MiscCFG::HitSound, "None\0Neverlose\0Skeet\0");
PutSwitch(Text::Misc::HitMerker.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &MiscCFG::HitMarker);
PutSwitch(Text::Misc::BunnyHop.c_str(), 10.f, ImGui::GetFrameHeight() * 1.7, &MiscCFG::BunnyHop);
Expand Down
10 changes: 1 addition & 9 deletions DragonBurn/Core/Render.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,7 @@ namespace Render
CenterPos = Head.ScreenPos;
float Radius = abs(Head.ScreenPos.y - Neck.ScreenPos.y) + 2;

switch (ESPConfig::HeadBoxStyle)
{
case 1:
Gui.CircleFilled(CenterPos, Radius + 1, Color & IM_COL32_A_MASK);
Gui.CircleFilled(CenterPos, Radius, Color);
break;
default:
Gui.Circle(CenterPos, Radius, Color, 1.2);
}
Gui.Circle(CenterPos, Radius, Color, 1.2);

}

Expand Down
4 changes: 2 additions & 2 deletions DragonBurn/DragonBurn.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<OutDir>$(SolutionDir)\built_dbg\</OutDir>
<IntDir>$(SolutionDir)\built_dbg\ceche</IntDir>
<IntDir>$(SolutionDir)\built_dbg\cache</IntDir>
<RunCodeAnalysis>false</RunCodeAnalysis>
<IncludePath>Libs\json</IncludePath>
<ExternalIncludePath>$(ExternalIncludePath)</ExternalIncludePath>
Expand All @@ -97,7 +97,7 @@
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<OutDir>$(SolutionDir)\built\</OutDir>
<IntDir>$(SolutionDir)\built\ceche</IntDir>
<IntDir>$(SolutionDir)\built\cache</IntDir>
<RunCodeAnalysis>false</RunCodeAnalysis>
<IncludePath>Libs\json</IncludePath>
<ExternalIncludePath>$(ExternalIncludePath)</ExternalIncludePath>
Expand Down
10 changes: 9 additions & 1 deletion DragonBurn/Features/BombTimer.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,17 @@ namespace bmb

static float windowWidth = 200.0f;
ImGuiWindowFlags flags = ImGuiWindowFlags_NoCollapse | ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoResize;
ImGui::SetNextWindowPos({ (ImGui::GetIO().DisplaySize.x - 200.0f) / 2.0f, 80.0f }, ImGuiCond_Once);
ImGui::SetNextWindowPos(MenuConfig::BombWinPos, ImGuiCond_Once);
ImGui::SetNextWindowSize({ windowWidth, 0 }, ImGuiCond_Once);
ImGui::GetStyle().WindowRounding = 8.0f;
ImGui::Begin("Bomb Timer", nullptr, flags);

if (MenuConfig::BombWinChengePos)
{
ImGui::SetWindowPos("Bomb Timer", MenuConfig::BombWinPos);
MenuConfig::BombWinChengePos = false;
}

float remaining = (40000 - (int64_t)time + plantTime) / (float)1000;

/*
Expand Down Expand Up @@ -114,6 +121,7 @@ namespace bmb
isPlanted = false;
}
//ImGui::PopStyleColor();
MenuConfig::BombWinPos = ImGui::GetWindowPos();
ImGui::End();
}
}
Loading

0 comments on commit e0c643e

Please sign in to comment.