resolving merge with minor changes

This commit is contained in:
CallowBlack 2022-06-21 22:50:59 +03:00
commit bf9137c60f
17 changed files with 515 additions and 72 deletions

View File

@ -1,22 +1,25 @@
<h1 align="center">Akebi GC</h1>
The great software for some game that exploiting anime girls (and boys).
The great software for some anime game which is for exploiting with girls (and boys).
We opened [Discord server](https://discord.gg/MmV8hNZB9S)
<hr>
We opened a [Discord server](https://discord.gg/MmV8hNZB9S)
<h1 align="center">Getting Started</h1>
### Building from source
It is reccomended to use [Visual Studio 2022.](https://visualstudio.microsoft.com/)
## Building from source
It is recommended to use [Visual Studio 2022.](https://visualstudio.microsoft.com/)
As well as setting up **`cheat-library`** as startup project.
**The following is a recommended procedure, but others may be used.**
1. Clone repository with `git clone --recurse-submodules https://github.com/Akebi-Group/Akebi-GC.git`
1. Open `Akebi-GC/akebi-gc.sln`
1. Build solution `akebi-gc.sln`.
### Release
## Release
1. Head over to the releases page
1. Download the latest binaries
### Requirements
- [Visual C++ Redistributable packages for Visual Studio 2015, 2017, 2019, 2022](https://aka.ms/vs/17/release/vc_redist.x64.exe) (x64)
- [Visual C++ Redistributable packages for Visual Studio 2015, 2017, 2019, 2022](https://aka.ms/vs/17/release/vc_redist.x86.exe) (x86)
### Usage
(1-2 are optional if you didn't build from source)
1. Open `/bin`
@ -32,15 +35,14 @@ As well as setting up **`cheat-library`** as startup project.
- Protection Bypass
- In-Game GUI
- Hotkeys
- Notifications
#### Player
- God Mode
- Invincible
- Unlimited Stamina
- Dumb Enemies (Enemies don't attack)
- Player
- Multiply Attacks
- No Cooldown Skill/Ultimate
- No Cooldown Sprint
- Dumb Enemies
- Attack Modifier
- No Cooldown Skill/Ultimate/Sprint
#### World
- Auto Loot
@ -49,6 +51,7 @@ As well as setting up **`cheat-library`** as startup project.
- Auto Tree Farm
- Mob Vacuum
- Auto Fish
- Music Event (temporary)
#### Teleport
- Chest/Oculi Teleport (Teleports to nearest)
@ -58,9 +61,14 @@ As well as setting up **`cheat-library`** as startup project.
- ESP
- Interactive Map
- Elemental Sight
- Profile Changer
- In-game Embedded Browser
- Hide UI
- Camera Zoom
- No Fog
#### Debugging
- Entity List
- Entities Manager
- Position Info
- FPS Graph
- Packet Sniffer
@ -93,6 +101,28 @@ As well as setting up **`cheat-library`** as startup project.
<img src="https://github.com/CallowBlack/gif-demos/blob/main/genshin-cheat/auto-talk-demo.gif"/>
</details>
# Bugs
Welcome to the short explanation for bug reporting
1. You Found a bug.
1. write down what happened, as well as your first thoughts on what you think caused it.
1. can it be reproduced? Yes or no. If yes: Explain in as much clear as possible. i.e what happens when the bug occurs and why it occurs.
1. Tell us which version you are using. copy the `SHA`/ Version Number of the latest commit when you built the mod. For example: `bd17a00ec388f3b93624280cde9e1c66e740edf9` / Release 0.7
## Bug reporting template
<br>
### Ex.
I found a bug in the feature `enemy vacuum`.
I think it's caused by the filter functions that are defined in `someFeature.cpp`.
```
Date Occured: 5/3/2022
Is it reproducible: Occasionally
Latest Commit used: bd17a00ec388f3b93624280cde9e1c66e740edf9
Release Version: 0.7
```
<h1 align="center">Contributing</h1>
## Adding a feature
@ -104,30 +134,5 @@ As well as setting up **`cheat-library`** as startup project.
## Suggestions
Open an issue with the title of the suggesstion you want to make.
Open an issue with the title of the suggestion you want to make.
In the description, make sure it is descriptive enough so our devs can understand what you want and how you want it.
## Bugs
Welcome to the short explanation for bug reporting, as well as the bug report template.
1. Find a bug and write down what happened, as well as your first thoughts on what you think caused it.
2. Try to reproduce the bug. For this you need to understand what actually happened, leading up to the bug and when the actual bug happened. To make sure you get all this information correctly taking various forms of documentations, such as video, screenshots etc is essential. These steps makes it a lot easier to try and figure out what actually happened. Try to replicate the scenario where the bug appeared, as close to the original as possible. What we would recommend for this step is using the bug reporting template which can be found on page 2 and simply adding the information you have / find in there.
3. can it be reproduced? Yes or no. If yes: Explain in as much detail as possible what happens when the bug occurs and why it occurs. Try and explain it as cleanly and as concise as possible to make sure that the coders dont have to read an essay to understand what could be a simple bug with a simple fix. For this, remember that information is very subjective so it is much better to over communicate than to risk confusion. If no: Try to provide as much information about the bug as possible, so that the testers will be able to replicate the scenario in which the bug occurred more easily so we can try to reproduce the bug.
4. Tell us which version you are using. Otherwise we would be getting bug reports on the same issue, that has been infact fixed in the latest commits. copy the SHA / Version Number of the latest commit when you built the mod. For example: `bd17a00ec388f3b93624280cde9e1c66e740edf9` / Release 0.7
Notes: Please remember to always record your testing sessions on your local hard drive and then upload them unlisted to youtube to conserve memory space on your computer and to give us easy access to your replays. This is to ensure that the optimal amount of documentation is available for the bug testers and coders to use as a guideline for either replicating scenarios, reproducing bugs or fixing them.
TL:DR Record all your stuff while playing the mod and report any bugs to the issues section of this repository.
### Bug reporting template
Title: e.g. “Instantly kill enemy with Shackles“
Description: “Game crashed if x, y, z“
-- Footer --
Date Occured: 5 / 3 / 2022
Is it reproducible: Yes / Occasionally / No
Latest Commit used: `bd17a00ec388f3b93624280cde9e1c66e740edf9`
Release Version: 0.7

View File

@ -45,10 +45,15 @@ bool LoadLibraryDLL(HANDLE hProc, const std::string& dllpath)
VirtualFreeEx(hProc, pDLLPath, 0, MEM_RELEASE);
return false;
}
CloseHandle(hThread);
// TODO: Add waiting for thread end and release unneccessary data.
// VirtualFreeEx(hProc, pDLLPath, 0, MEM_RELEASE);
// Waiting for thread end and release unnecessary data.
if (WaitForSingleObject(hThread, 2000) == WAIT_OBJECT_0)
{
// ILog("[DLL Injection] Remote thread ended successfully.\n");
VirtualFreeEx(hProc, pDLLPath, 0, MEM_RELEASE);
}
CloseHandle(hThread);
ILog("[DLL Injection] Successfully LoadLibraryA injection.\n");
return true;

View File

@ -15,6 +15,7 @@
</ProjectConfiguration>
</ItemGroup>
<ItemGroup>
<ClInclude Include="src\user\cheat\world\FakeTime.h" />
<ClInclude Include="src\user\cheat\debugger.h">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WS|x64'">false</ExcludedFromBuild>
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">false</ExcludedFromBuild>
@ -44,6 +45,7 @@
<ClInclude Include="src\user\cheat\teleport\CustomTeleports.h" />
<ClInclude Include="src\user\cheat\visuals\Browser.h" />
<ClInclude Include="src\user\cheat\visuals\CameraZoom.h" />
<ClInclude Include="src\user\cheat\visuals\EnablePeaking.h" />
<ClInclude Include="src\user\cheat\visuals\FPSUnlock.h" />
<ClInclude Include="src\user\cheat\visuals\HideUI.h" />
<ClInclude Include="src\user\cheat\visuals\NoFog.h" />
@ -106,6 +108,7 @@
<ClInclude Include="src\user\cheat\world\DumbEnemies.h" />
<ClInclude Include="src\user\cheat\world\KillAura.h" />
<ClInclude Include="src\user\cheat\world\MobVacuum.h" />
<ClInclude Include="src\user\cheat\world\MusicEvent.h" />
<ClInclude Include="src\user\main.h" />
</ItemGroup>
<ItemGroup>
@ -113,6 +116,7 @@
<Font Include="res\Ruda-ExtraBold.ttf" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="src\user\cheat\world\FakeTime.cpp" />
<ClCompile Include="src\user\cheat\debugger.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">false</ExcludedFromBuild>
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WS|x64'">false</ExcludedFromBuild>
@ -142,6 +146,7 @@
<ClCompile Include="src\user\cheat\GenshinCM.cpp" />
<ClCompile Include="src\user\cheat\visuals\Browser.cpp" />
<ClCompile Include="src\user\cheat\visuals\CameraZoom.cpp" />
<ClCompile Include="src\user\cheat\visuals\EnablePeaking.cpp" />
<ClCompile Include="src\user\cheat\visuals\FPSUnlock.cpp" />
<ClCompile Include="src\user\cheat\visuals\HideUI.cpp" />
<ClCompile Include="src\user\cheat\visuals\NoFog.cpp" />
@ -201,6 +206,7 @@
<ClCompile Include="src\user\cheat\world\DumbEnemies.cpp" />
<ClCompile Include="src\user\cheat\world\KillAura.cpp" />
<ClCompile Include="src\user\cheat\world\MobVacuum.cpp" />
<ClCompile Include="src\user\cheat\world\MusicEvent.cpp" />
<ClCompile Include="src\user\main.cpp" />
</ItemGroup>
<PropertyGroup>
@ -894,8 +900,7 @@
</Command>
</PostBuildEvent>
<CustomBuildStep>
<Command>"$(OutDir)injector.exe"
powershell -nop -c "&amp; {sleep 15}"</Command>
<Command>"$(OutDir)injector.exe" powershell -nop -c "&amp;amp; {sleep 15}"</Command>
<Outputs>$(OutDir)_noexist.nope;%(Outputs)</Outputs>
<Inputs>$(TargetPath);%(Inputs)</Inputs>
</CustomBuildStep>

View File

@ -213,6 +213,9 @@
<ClInclude Include="src\user\cheat\world\AutoCook.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="src\user\cheat\world\FakeTime.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="src\user\cheat\visuals\ProfileChanger.h">
<Filter>Header Files</Filter>
</ClInclude>
@ -225,6 +228,12 @@
<ClInclude Include="src\user\cheat\visuals\Browser.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="src\user\cheat\world\MusicEvent.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="src\user\cheat\visuals\EnablePeaking.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<Font Include="res\Ruda-Bold.ttf" />
@ -396,6 +405,9 @@
<ClCompile Include="src\user\cheat\debugger.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="src\user\cheat\world\FakeTime.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="src\user\cheat\visuals\ProfileChanger.cpp">
<Filter>Source Files</Filter>
</ClCompile>
@ -408,6 +420,12 @@
<ClCompile Include="src\user\cheat\visuals\Browser.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="src\user\cheat\world\MusicEvent.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="src\user\cheat\visuals\EnablePeaking.cpp">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="res\res.rc">

View File

@ -26,6 +26,7 @@
#include <cheat/world/MobVacuum.h>
#include <cheat/world/AutoTreeFarm.h>
#include <cheat/world/AutoDestroy.h>
#include <cheat/world/FakeTime.h>
#include <cheat/teleport/ChestTeleport.h>
#include <cheat/teleport/MapTeleport.h>
@ -37,6 +38,7 @@
#include <cheat/world/AutoFish.h>
#include <cheat/world/AutoCook.h>
#include <cheat/world/MusicEvent.h>
#include <cheat/visuals/NoFog.h>
#include <cheat/visuals/FPSUnlock.h>
@ -46,6 +48,7 @@
#include <cheat/visuals/PaimonFollow.h>
#include <cheat/visuals/HideUI.h>
#include <cheat/visuals/Browser.h>
#include <cheat/visuals/EnablePeaking.h>
#include "GenshinCM.h"
@ -84,6 +87,7 @@ namespace cheat
FEAT_INST(ElementalSight),
FEAT_INST(KillAura),
FEAT_INST(MobVacuum),
FEAT_INST(FakeTime),
FEAT_INST(ChestTeleport),
FEAT_INST(OculiTeleport),
@ -95,6 +99,7 @@ namespace cheat
FEAT_INST(AutoFish),
FEAT_INST(AutoCook),
FEAT_INST(MusicEvent),
FEAT_INST(NoFog),
FEAT_INST(FPSUnlock),
@ -103,7 +108,8 @@ namespace cheat
FEAT_INST(ProfileChanger),
FEAT_INST(PaimonFollow),
FEAT_INST(HideUI),
FEAT_INST(Browser)
FEAT_INST(Browser),
FEAT_INST(EnablePeaking)
});
#undef FEAT_INST

View File

@ -513,6 +513,7 @@ namespace cheat::feature
ADD_FILTER_FIELD(mineral, ScarletQuartz);
ADD_FILTER_FIELD(mineral, StarSilver);
ADD_FILTER_FIELD(mineral, WhiteIronChunk);
ADD_FILTER_FIELD(mineral, DunlinsTooth);
// Trounce. Arranged by appearance in-game.
ADD_FILTER_FIELD(monster, Dvalin);
@ -582,7 +583,6 @@ namespace cheat::feature
ADD_FILTER_FIELD(monster, Samachurl);
ADD_FILTER_FIELD(monster, SangonomiyaCohort);
ADD_FILTER_FIELD(monster, ShadowyHusk);
ADD_FILTER_FIELD(monster, ShadowyHusk);
ADD_FILTER_FIELD(monster, ShogunateInfantry);
ADD_FILTER_FIELD(monster, Slime);
ADD_FILTER_FIELD(monster, Specter);
@ -635,6 +635,7 @@ namespace cheat::feature
ADD_FILTER_FIELD(puzzle, CubeDevices);
ADD_FILTER_FIELD(puzzle, EightStoneTablets);
ADD_FILTER_FIELD(puzzle, ElectricConduction);
ADD_FILTER_FIELD(puzzle, RelayStone);
ADD_FILTER_FIELD(puzzle, ElectroSeelie);
ADD_FILTER_FIELD(puzzle, ElementalMonument);
ADD_FILTER_FIELD(puzzle, FloatingAnemoSlime);

View File

@ -69,7 +69,7 @@ namespace cheat::game::filters
SimpleFilter LizardTail = { app::EntityType__Enum_1::EnvAnimal, "Lizard" };
SimpleFilter LuminescentSpine = { app::EntityType__Enum_1::EnvAnimal, "FireFly" };
SimpleFilter Onikabuto = { app::EntityType__Enum_1::GatherObject, "Electrohercules" };
SimpleFilter Starconch = { app::EntityType__Enum_1::GatherObject, "Shell" };
SimpleFilter Starconch = { app::EntityType__Enum_1::GatherObject, "_Shell" };
SimpleFilter Eel = { app::EntityType__Enum_1::EnvAnimal, "Eel_" };
SimpleFilter Inu = { app::EntityType__Enum_1::EnvAnimal, "_Inu_Shihandai" };
SimpleFilter Boar = { app::EntityType__Enum_1::Monster, "Boar" };
@ -107,6 +107,7 @@ namespace cheat::game::filters
SimpleFilter ScarletQuartz = { app::EntityType__Enum_1::GatherObject, "_OreDulinsBlood" };
SimpleFilter StarSilver = { app::EntityType__Enum_1::GatherObject, "_OreMoonMeteor" };
SimpleFilter WhiteIronChunk = { app::EntityType__Enum_1::GatherObject, "_OreMetal" };
SimpleFilter DunlinsTooth = { app::EntityType__Enum_1::GatherObject, "_DunlinsTooth" };
}
namespace monster
@ -231,6 +232,7 @@ namespace cheat::game::filters
WhitelistFilter CubeDevices = { std::vector<app::EntityType__Enum_1> {app::EntityType__Enum_1::Gadget, app::EntityType__Enum_1::Platform }, std::vector<std::string> {"_ElecStone", "_ElecSwitch" }};
SimpleFilter EightStoneTablets = { app::EntityType__Enum_1::Gadget, "_HistoryBoard" };
SimpleFilter ElectricConduction = { app::EntityType__Enum_1::Gear, "_ElectricPowerSource" };
SimpleFilter RelayStone = { app::EntityType__Enum_1::Worktop, "_ElectricTransfer_" };
WhitelistFilter ElectroSeelie = { std::vector<app::EntityType__Enum_1> {app::EntityType__Enum_1::Field, app::EntityType__Enum_1::Platform }, std::vector<std::string> {"_ElectricSeelie"} };
SimpleFilter ElementalMonument = { app::EntityType__Enum_1::Gear, "_ElemTablet" };
SimpleFilter FloatingAnemoSlime = { app::EntityType__Enum_1::Platform, "_WindSlime" };

View File

@ -107,6 +107,7 @@ namespace cheat::game::filters
extern SimpleFilter ScarletQuartz;
extern SimpleFilter StarSilver;
extern SimpleFilter WhiteIronChunk;
extern SimpleFilter DunlinsTooth;
}
namespace monster
@ -230,6 +231,7 @@ namespace cheat::game::filters
extern SimpleFilter EightStoneTablets;
extern SimpleFilter ElectricConduction;
extern SimpleFilter RelayStone;
extern WhitelistFilter ElectroSeelie;
extern SimpleFilter ElementalMonument;
extern SimpleFilter FloatingAnemoSlime;

View File

@ -8,13 +8,17 @@ namespace cheat::feature
{
static bool Miscs_CheckTargetAttackable_Hook(app::BaseEntity* attacker, app::BaseEntity* target, MethodInfo* method);
static void VCHumanoidMove_NotifyLandVelocity_Hook(app::VCHumanoidMove* __this, app::Vector3 velocity, float reachMaxDownVelocityTime, MethodInfo* method);
static void LCBaseCombat_FireBeingHitEvent_Hook(app::LCBaseCombat* __this, uint32_t attackeeRuntimeID, app::AttackResult* attackResult, MethodInfo* method);
static bool MoleMole_ActorAbilityPlugin_HanlderModifierThinkTimerUp_Hook(app::ActorAbilityPlugin* __this, float delay, app::Object* arg, MethodInfo* method);
GodMode::GodMode() : Feature(),
NFEX(f_Enabled, "God mode", "m_GodMode", "Player", false, false)
NFEX(f_Enabled, "God mode", "m_GodMode", "Player", false, false),
NF(f_AltGodMode, "Alternative God Mode", "Player", false)
{
// HookManager::install(app::MoleMole_LCBaseCombat_FireBeingHitEvent, LCBaseCombat_FireBeingHitEvent_Hook);
HookManager::install(app::VCHumanoidMove_NotifyLandVelocity, VCHumanoidMove_NotifyLandVelocity_Hook);
HookManager::install(app::Miscs_CheckTargetAttackable, Miscs_CheckTargetAttackable_Hook);
HookManager::install(app::MoleMole_LCBaseCombat_FireBeingHitEvent, LCBaseCombat_FireBeingHitEvent_Hook);
HookManager::install(app::MoleMole_ActorAbilityPlugin_HanlderModifierThinkTimerUp, MoleMole_ActorAbilityPlugin_HanlderModifierThinkTimerUp_Hook);
}
const FeatureGUIInfo& GodMode::GetGUIInfo() const
@ -28,16 +32,21 @@ namespace cheat::feature
ConfigWidget("God Mode", f_Enabled,
"Enables god mode, i.e. no incoming damage.\n" \
"May not work with some types of damage.");
ImGui::Indent();
ConfigWidget("Alternative God Mode", f_AltGodMode,
"Alternative god mode that ignores incoming damage\n" \
"including environmental damage.");
ImGui::Unindent();
}
bool GodMode::NeedStatusDraw() const
{
return f_Enabled;
return f_Enabled || f_AltGodMode;
}
void GodMode::DrawStatus()
{
ImGui::Text("God Mode");
ImGui::Text("God Mode%s", f_AltGodMode ? "+Alt " : " ");
}
GodMode& GodMode::GetInstance()
@ -64,7 +73,7 @@ namespace cheat::feature
static void VCHumanoidMove_NotifyLandVelocity_Hook(app::VCHumanoidMove* __this, app::Vector3 velocity, float reachMaxDownVelocityTime, MethodInfo* method)
{
auto& gm = GodMode::GetInstance();
if (gm.f_Enabled && -velocity.y > 13)
if ((gm.f_Enabled || gm.f_AltGodMode) && -velocity.y > 13)
{
float randAdd = (float)(std::rand() % 1000) / 1000;
velocity.y = -8 - randAdd;
@ -75,13 +84,24 @@ namespace cheat::feature
}
// Analog function for disable attack damage (Thanks to Taiga74164)
//void LCBaseCombat_FireBeingHitEvent_Hook(app::LCBaseCombat* __this, uint32_t attackeeRuntimeID, app::AttackResult* attackResult, MethodInfo* method)
//{
// auto avatarEntity = GetAvatarEntity();
// if (avatarEntity != nullptr && Config::cfgGodModEnable.GetValue() && avatarEntity->fields._runtimeID_k__BackingField == attackeeRuntimeID)
// return;
//
// return callOrigin(LCBaseCombat_FireBeingHitEvent_Hook, __this, attackeeRuntimeID, attackResult, method);
//}
static void LCBaseCombat_FireBeingHitEvent_Hook(app::LCBaseCombat* __this, uint32_t attackeeRuntimeID, app::AttackResult* attackResult, MethodInfo* method)
{
auto& gm = GodMode::GetInstance();
auto& manager = game::EntityManager::instance();
if (gm.f_AltGodMode && manager.avatar()->runtimeID() == attackeeRuntimeID)
return;
CALL_ORIGIN(LCBaseCombat_FireBeingHitEvent_Hook, __this, attackeeRuntimeID, attackResult, method);
}
// Environmental damage immunity (Thanks to RELOADED#7236 / GitHub: @34736384)
static bool MoleMole_ActorAbilityPlugin_HanlderModifierThinkTimerUp_Hook(app::ActorAbilityPlugin* __this, float delay, app::Object* arg, MethodInfo* method)
{
auto& gm = GodMode::GetInstance();
if (gm.f_AltGodMode/* || gm.f_Enabled*/)
return FALSE;
return CALL_ORIGIN(MoleMole_ActorAbilityPlugin_HanlderModifierThinkTimerUp_Hook, __this, delay, arg, method);
}
}

View File

@ -9,6 +9,7 @@ namespace cheat::feature
{
public:
config::Field<config::Toggle<Hotkey>> f_Enabled;
config::Field<config::Toggle<Hotkey>> f_AltGodMode;
static GodMode& GetInstance();

View File

@ -0,0 +1,52 @@
#include "pch-il2cpp.h"
#include "EnablePeaking.h"
#include <helpers.h>
namespace cheat::feature
{
static void MoleMole_VCBaseSetDitherValue_set_ManagerDitherAlphaValue_Hook(app::MoleMole_VCBaseSetDitherValue* __this, float value, MethodInfo* method);
EnablePeaking::EnablePeaking() : Feature(),
NF(f_Enabled, "Enable Peaking", "Visuals::EnablePeaking", false)
{
HookManager::install(app::MoleMole_VCBaseSetDitherValue_set_ManagerDitherAlphaValue, MoleMole_VCBaseSetDitherValue_set_ManagerDitherAlphaValue_Hook);
}
const FeatureGUIInfo& EnablePeaking::GetGUIInfo() const
{
static const FeatureGUIInfo info{ "EnablePeaking", "Visuals", false };
return info;
}
void EnablePeaking::DrawMain()
{
ConfigWidget(f_Enabled, ";)");
}
bool EnablePeaking::NeedStatusDraw() const
{
return f_Enabled;
}
void EnablePeaking::DrawStatus()
{
ImGui::Text("Enable Peaking");
}
EnablePeaking& EnablePeaking::GetInstance()
{
static EnablePeaking instance;
return instance;
}
static void MoleMole_VCBaseSetDitherValue_set_ManagerDitherAlphaValue_Hook(app::MoleMole_VCBaseSetDitherValue* __this, float value, MethodInfo* method)
{
EnablePeaking& EnablePeaking = EnablePeaking::GetInstance();
if (EnablePeaking.f_Enabled)
value = 1;
CALL_ORIGIN(MoleMole_VCBaseSetDitherValue_set_ManagerDitherAlphaValue_Hook, __this, value, method);
}
}

View File

@ -0,0 +1,25 @@
#pragma once
#include <cheat-base/cheat/Feature.h>
#include <cheat-base/config/config.h>
namespace cheat::feature
{
class EnablePeaking : public Feature
{
public:
config::Field<config::Toggle<Hotkey>> f_Enabled;
static EnablePeaking& GetInstance();
const FeatureGUIInfo& GetGUIInfo() const override;
void DrawMain() override;
virtual bool NeedStatusDraw() const override;
void DrawStatus() override;
private:
EnablePeaking();
};
}

View File

@ -116,12 +116,48 @@ namespace cheat::feature
}
};
template <typename KeyT, typename ValT, uint32_t Size, class /*forward*/ _Hasher = std::hash<KeyT>>
class lra_map {
using key_value_pair = std::pair<KeyT, ValT>;
using list_iterator = typename std::list<key_value_pair>::iterator;
public:
void put(const KeyT& key, const ValT& val) {
auto it = elem_map.find(key);
// if element already in the map, don't modify it.
if (it != elem_map.end())
return;
items_list.push_front(key_value_pair(key, val));
elem_map[key] = items_list.begin();
if (Size < elem_map.size()) {
{
const KeyT& last_key = items_list.back().first;
elem_map.erase(last_key);
}
items_list.pop_back();
}
}
ValT& get(const KeyT& key) {
auto it = elem_map.find(key);
if (it == elem_map.end())
throw std::runtime_error("Tried to access key not present in map");
return it->second->second;
}
bool exists(const KeyT& key) const {
return elem_map.find(key) != elem_map.end();
}
protected:
std::list<key_value_pair> items_list;
std::unordered_map<KeyT, list_iterator, _Hasher> elem_map;
};
void AutoTreeFarm::OnGameUpdate()
{
static std::unordered_map<Vector3d, uint32_t, hash_fn> s_AttackCountMap;
static lra_map<Vector3d, uint32_t, 10, hash_fn> s_AttackCountMap;
static std::queue<app::SceneTreeObject*> s_AttackQueue;
static std::unordered_set<app::SceneTreeObject*> s_AttackQueueSet;
static uint64_t s_LastAttackTimestamp = 0;
@ -142,7 +178,7 @@ namespace cheat::feature
if (s_AttackQueueSet.count(tree) > 0)
continue;
if (tree->fields._lastTreeDropTimeStamp + m_RepeatDelay > timestamp)
if (s_LastAttackTimestamp + m_RepeatDelay > timestamp)
continue;
auto position = tree->fields._.realBounds.m_Center;
@ -173,22 +209,20 @@ namespace cheat::feature
if (m_AttackPerTree > 0)
{
if (s_AttackCountMap.count(position) == 0)
s_AttackCountMap[position] = 0;
if (!s_AttackCountMap.exists(position))
s_AttackCountMap.put(position, 0);
auto& attackCount = s_AttackCountMap[position];
auto& attackCount = s_AttackCountMap.get(position);
attackCount++;
if (attackCount > static_cast<uint32_t>(m_AttackPerTree))
continue;
}
tree->fields._lastTreeDropTimeStamp = timestamp;
s_LastAttackTimestamp = timestamp;
app::MoleMole_NetworkManager_RequestHitTreeDropNotify(networkManager, position, position, treeType, nullptr);
break;
}
if (s_AttackCountMap.size() > 1000)
s_AttackCountMap.clear();
}
}

View File

@ -0,0 +1,67 @@
#include "pch-il2cpp.h"
#include "FakeTime.h"
#include <cheat/events.h>
namespace cheat::feature
{
//CNLouisLiu
void* LevelTimeManager = NULL;
FakeTime::FakeTime() : Feature(),
NF(f_Enabled, "FakeTime", "Enabled", false),
NF(f_TimeHour, "FakeTime", "TimeHour", 12),
NF(f_TimeMinute, "FakeTime", "TimeMinute", 0)
{
HookManager::install(app::LevelTimeManager_SetInternalTimeOfDay, LevelTimeManager_SetInternalTimeOfDay_Hook);
events::GameUpdateEvent += MY_METHOD_HANDLER(FakeTime::OnGameUpdate);
}
FakeTime& FakeTime::GetInstance()
{
static FakeTime instance;
return instance;
}
const FeatureGUIInfo& FakeTime::GetGUIInfo() const
{
static const FeatureGUIInfo info{ "FakeTime", "World", true };
return info;
}
void FakeTime::DrawMain()
{
ConfigWidget("Enabled", f_Enabled, "Keep game time the same");
ConfigWidget("TimeHour", f_TimeHour, 1, 0, 24);
ConfigWidget("TimeMinute", f_TimeMinute, 1, 0, 60);
}
bool FakeTime::NeedStatusDraw() const
{
return f_Enabled;
}
void FakeTime::DrawStatus()
{
ImGui::Text("FakeTime|%d:%d", f_TimeHour.value(), f_TimeMinute.value());
}
float FakeTime::ConversionTime() {
float time = float(f_TimeHour);
float timemin = f_TimeMinute / 60;
return time + timemin;
}
void FakeTime::OnGameUpdate()
{
if (LevelTimeManager != NULL && f_Enabled) {
auto& faketime = GetInstance();
CALL_ORIGIN(LevelTimeManager_SetInternalTimeOfDay_Hook, LevelTimeManager, faketime.ConversionTime(), false, false, (MethodInfo*)0);
}
}
void FakeTime::LevelTimeManager_SetInternalTimeOfDay_Hook(void* __this, float inHours, bool force, bool refreshEnviroTime, MethodInfo* method) {
float Hours = inHours;
auto& faketime = GetInstance();
if (faketime.f_Enabled)
{
Hours = faketime.ConversionTime();
}
CALL_ORIGIN(LevelTimeManager_SetInternalTimeOfDay_Hook, __this, Hours, force, refreshEnviroTime, method);
}
}

View File

@ -0,0 +1,23 @@
#pragma once
namespace cheat::feature
{
class FakeTime : public Feature
{
public:
config::Field<config::Toggle<Hotkey>> f_Enabled;
config::Field<int> f_TimeHour;
config::Field<int> f_TimeMinute;
static FakeTime& GetInstance();
void OnGameUpdate();
const FeatureGUIInfo& GetGUIInfo() const override;
void DrawMain() override;
virtual bool NeedStatusDraw() const override;
void DrawStatus() override;
private:
static void LevelTimeManager_SetInternalTimeOfDay_Hook(void* __this, float inHours, bool force, bool refreshEnviroTime, MethodInfo* method);
float ConversionTime();
FakeTime();
};
}

View File

@ -0,0 +1,152 @@
#include "pch-il2cpp.h"
#include "MusicEvent.h"
#include <helpers.h>
#include <cheat/events.h>
namespace cheat::feature
{
static void MusicGamePlayComponent_OnStart_Hook(app::MusicGamePlayComponent* __this, app::BeatMapData* beatMapData, app::MusicMetaInfo* musicMetaInfo, MethodInfo* method);
static void MusicGamePlayComponent_OnMiss_Hook(app::MusicGamePlayComponent* __this, MethodInfo* method);
static void MusicGamePlayComponent_set_combo_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method);
static void MusicGamePlayComponent_set_score_Hook(app::MusicGamePlayComponent* __this, float value, MethodInfo* method);
static void MusicGamePlayComponent_set_maxCombo_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method);
static void MusicGamePlayComponent_set_perfectCnt_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method);
static void MusicGamePlayComponent_set_greatCnt_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method);
static void MusicGamePlayComponent_set_missCnt_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method);
static void MusicGamePlayComponent_OnHit_Hook(app::MusicGamePlayComponent* __this, float score, MethodInfo* method);
MusicEvent::MusicEvent() : Feature(),
NF(f_Enabled, "Music Event", "MusicEvent", false)
{
//HookManager::install(app::MusicGamePlayComponent_OnStart, MusicGamePlayComponent_OnStart_Hook);
HookManager::install(app::MusicGamePlayComponent_OnMiss, MusicGamePlayComponent_OnMiss_Hook);
HookManager::install(app::MusicGamePlayComponent_set_combo, MusicGamePlayComponent_set_combo_Hook);
HookManager::install(app::MusicGamePlayComponent_set_score, MusicGamePlayComponent_set_score_Hook);
HookManager::install(app::MusicGamePlayComponent_set_maxCombo, MusicGamePlayComponent_set_maxCombo_Hook);
HookManager::install(app::MusicGamePlayComponent_set_perfectCnt, MusicGamePlayComponent_set_perfectCnt_Hook);
HookManager::install(app::MusicGamePlayComponent_set_greatCnt, MusicGamePlayComponent_set_greatCnt_Hook);
HookManager::install(app::MusicGamePlayComponent_set_missCnt, MusicGamePlayComponent_set_missCnt_Hook);
HookManager::install(app::MusicGamePlayComponent_OnHit, MusicGamePlayComponent_OnHit_Hook);
}
const FeatureGUIInfo& MusicEvent::GetGUIInfo() const
{
static const FeatureGUIInfo info{ "", "World", false };
return info;
}
void MusicEvent::DrawMain()
{
ConfigWidget(f_Enabled, "Enemies don't attack or use abilities against player. \n"
"May not work with some enemies or enemy abilites.");
}
bool MusicEvent::NeedStatusDraw() const
{
return f_Enabled;
}
void MusicEvent::DrawStatus()
{
ImGui::Text("Music Event");
}
MusicEvent& MusicEvent::GetInstance()
{
static MusicEvent instance;
return instance;
}
static void MusicGamePlayComponent_OnStart_Hook(app::MusicGamePlayComponent * __this, app::BeatMapData* beatMapData, app::MusicMetaInfo* musicMetaInfo, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
__this->fields._combo = 9999999;
__this->fields._score_k__BackingField = 9999999;
__this->fields._maxCombo_k__BackingField = 9999999;
__this->fields._perfectCnt_k__BackingField = 9999999;
__this->fields._greatCnt_k__BackingField = 9999999;
__this->fields._missCnt_k__BackingField = 0;
}
CALL_ORIGIN(MusicGamePlayComponent_OnStart_Hook, __this, beatMapData, musicMetaInfo, method);
}
static void MusicGamePlayComponent_OnMiss_Hook(app::MusicGamePlayComponent* __this, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
return;
}
CALL_ORIGIN(MusicGamePlayComponent_OnMiss_Hook, __this, method);
}
static void MusicGamePlayComponent_set_combo_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
value = 999999999;
}
CALL_ORIGIN(MusicGamePlayComponent_set_combo_Hook, __this, value, method);
}
static void MusicGamePlayComponent_set_score_Hook(app::MusicGamePlayComponent* __this, float value, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
value = 999999999;
}
CALL_ORIGIN(MusicGamePlayComponent_set_score_Hook, __this, value, method);
}
static void MusicGamePlayComponent_set_maxCombo_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
value = 999999999;
}
CALL_ORIGIN(MusicGamePlayComponent_set_maxCombo_Hook, __this, value, method);
}
static void MusicGamePlayComponent_set_perfectCnt_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
value = 999999999;
}
CALL_ORIGIN(MusicGamePlayComponent_set_perfectCnt_Hook, __this, value, method);
}
static void MusicGamePlayComponent_set_greatCnt_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
value = 999999999;
}
CALL_ORIGIN(MusicGamePlayComponent_set_greatCnt_Hook, __this, value, method);
}
static void MusicGamePlayComponent_set_missCnt_Hook(app::MusicGamePlayComponent* __this, uint32_t value, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
value = 0;
}
CALL_ORIGIN(MusicGamePlayComponent_set_missCnt_Hook, __this, value, method);
}
static void MusicGamePlayComponent_OnHit_Hook(app::MusicGamePlayComponent* __this, float score, MethodInfo* method)
{
MusicEvent& MusicEvent = MusicEvent::GetInstance();
if (MusicEvent.f_Enabled)
{
score = 999999999;
}
CALL_ORIGIN(MusicGamePlayComponent_OnHit_Hook, __this, score, method);
}
}

View File

@ -0,0 +1,25 @@
#pragma once
#include <cheat-base/cheat/Feature.h>
#include <cheat-base/config/config.h>
namespace cheat::feature
{
class MusicEvent : public Feature
{
public:
config::Field<config::Toggle<Hotkey>> f_Enabled;
static MusicEvent& GetInstance();
const FeatureGUIInfo& GetGUIInfo() const override;
void DrawMain() override;
virtual bool NeedStatusDraw() const override;
void DrawStatus() override;
private:
MusicEvent();
};
}