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

Commit c72e42e

Browse files
committed
cbe
1 parent cdf3d9a commit c72e42e

1 file changed

Lines changed: 1 addition & 7 deletions

File tree

Horion/Command/Commands/CommandBlockExploitCommand.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,7 @@ bool CommandBlockExploitCommand::execute(std::vector<std::string>* args) {
1919
os << " ";
2020
os << args->at(i);
2121
}
22-
using ItemRegistry__lookupByName_t = C_Item***(__fastcall*)(void*, void*, TextHolder);
23-
static ItemRegistry__lookupByName_t ItemRegistry__lookupByNameF = reinterpret_cast<ItemRegistry__lookupByName_t>(FindSignature("48 89 5C 24 ? 55 56 57 41 54 41 55 41 56 41 57 48 8D AC 24 ? ? ? ? 48 81 EC ? ? ? ? 48 8B 05 ? ? ? ? 48 33 C4 48 89 85 ? ? ? ? 4C 8B EA 48 89 54 24 ? 48 89 4C 24 ? 48 89 4D"));
24-
void* ItemPtr = malloc(0x8);
25-
void* idk = malloc(0x0);
26-
C_ItemStack* yot = new C_ItemStack(***ItemRegistry__lookupByNameF(ItemPtr, idk, std::string("beehive")), 1, 0);
27-
free(ItemPtr);
28-
free(idk);
22+
C_ItemStack* yot = new C_ItemStack(***ItemRegistry::lookUpByName(std::make_unique<uintptr_t>().get(), std::make_unique<uintptr_t>().get(), TextHolder("beehive")), 1, 0);
2923
int slot = g_Data.getLocalPlayer()->getSupplies()->inventory->getFirstEmptySlot();
3024
std::string cmd = os.str();
3125
std::string tag = "{Occupants:[{ActorIdentifier:""\"minecraft:command_block_minecart<>""\",SaveData:{Command:\"" + cmd + "\",Ticking:1b,TicksLeftToStay:1}}]}";

0 commit comments

Comments
 (0)