|
You last visited: Today at 04:43
Advertisement
On Inventory Packet / "ITC"
Discussion on On Inventory Packet / "ITC" within the S4 League Hacks, Bots, Cheats & Exploits forum part of the S4 League category.
06/18/2016, 06:18
|
#1
|
elite*gold: 0
Join Date: Mar 2016
Posts: 70
Received Thanks: 176
|
On Inventory Packet / "ITC"
Da ich einfach nur heulen könnte wenn ich diese dreckigen ASM & c++ snippets sehe, poste ich hier mal hier den C++ Code des packets aus meinem privaten Projekt.
Code:
void __cdecl CS4::S4_OnInventoryPacket(uint32_t i_iInventoryPacket, uint32_t i_iInventoryPointer)
{
bool(__thiscall *getItemAmountOfInventoryPacket)(uint32_t i_iEcx, uint32_t &i_pBindedValue, uint32_t i_pSize) = (bool( __thiscall *)(uint32_t, uint32_t&, uint32_t)) /*Srsly?*/;
void(__cdecl *extractItemfromPacket)(uint32_t i_iPacket, void* i_pBuffer) = (void(__cdecl *)(uint32_t, void*)) /*Srsly?*/;
void(__thiscall *insertItemfromBuffer)(uint32_t i_pInventory, void* i_pBuffer) = (void(__thiscall *)(uint32_t, void*)) /*Srsly?*/;
uint32_t a_iItemAmount = 0;
printf("ITC -> Inventory call : 0x%x 0x%x\n", i_iInventoryPacket, i_iInventoryPointer);
printf("\t<Normal>\n");
{
SItem a_oTempItem;
ZeroMemory(&a_oTempItem, sizeof(a_oTempItem));
bool a_fIsInventoryValid = getItemAmountOfInventoryPacket(i_iInventoryPacket, a_iItemAmount, sizeof(a_iItemAmount));
if (!a_fIsInventoryValid)
{
return;
}
printf("\t -> Received %i Items\n", a_iItemAmount);
for (uint32_t i = 0; i < a_iItemAmount; i++)
{
extractItemfromPacket(i_iInventoryPacket, &a_oTempItem);
insertItemfromBuffer(i_iInventoryPointer, &a_oTempItem);
}
}
}
Wer logisch nachdenkt, könnte jetzt 1&1 zusammenfügen und noch z.b. so etwas in der Funktion hinten dranhängen:
Code:
printf("\t<Hacked>\n");
{
insertItemfromBuffer(i_iInventoryPointer, /*Srsly?*/);
}
Credits:
Decrypted
(Ant) = Jeder ITC hat eig. etwas mit ihm zu tuen durch sein damaliges CE Script was gepostet wurde.
Quote:
Originally Posted by Apflmus
Wenn man sich mal die Sources von manchen Leuten an sieht, egal ob AutoIT oder C++, sehe ich pure Vergewaltigung, das tut mir schon im Herzen weh.
|
Selber Gedanke.
|
|
|
06/18/2016, 09:45
|
#2
|
elite*gold: 0
Join Date: Nov 2014
Posts: 741
Received Thanks: 2,648
|
The Question here is why you didn't change the Packet Buffer ?
Code:
for (uint32_t i = 0; i < a_iItemAmount; i++)
{
extractItemfromPacket(i_iInventoryPacket, &a_oTempItem);
insertItemfromBuffer(i_iInventoryPointer, &a_oTempItem);
}
i used simple that function in the new ITC it looks like
Code:
for (auto it = InventoryStack.begin(); it < InventoryStack.end(); it++)
{
a_oTempItem = it->second;
//extractItemfromPacket(i_iInventoryPacket, &a_oTempItem);
insertItemfromBuffer(i_iInventoryPointer, &a_oTempItem);
}
but the opensource is **** i said it everywhere :3
You can also Grab K1ramox Packet Mananger OpenSource to make it based on the Packet Buffer. Its a methode which i could recommend
{
Character_CurrentItemInfo_Ack = 1004,
Item_InventoryInfo_Ack = 1005,
}
Credits K1ramox
|
|
|
06/18/2016, 10:35
|
#3
|
elite*gold: 0
Join Date: Mar 2016
Posts: 70
Received Thanks: 176
|
Quote:
Originally Posted by Sycode'
...
|
Because i just wanted to post the normal way like mentioned.
|
|
|
06/18/2016, 10:50
|
#4
|
elite*gold: 0
Join Date: Nov 2014
Posts: 741
Received Thanks: 2,648
|
Quote:
Originally Posted by Decrypted
Because i just wanted to post the normal way like mentioned.
|
Sorry but there isn't a normal way. You can also create the items later while you are in the inventory. An Item Creator hasn't a normal way ..you can do it like you want. :8
|
|
|
06/18/2016, 11:25
|
#5
|
elite*gold: 0
Join Date: Jun 2016
Posts: 10
Received Thanks: 6
|
95% der S4 Section sind doch eh zu dumm um das anzuwenden. ^^
|
|
|
06/18/2016, 11:28
|
#6
|
elite*gold: 0
Join Date: Mar 2016
Posts: 70
Received Thanks: 176
|
Quote:
Originally Posted by Sycode'
Sorry but there isn't a normal way. You can also create the items later while you are in the inventory. An Item Creator hasn't a normal way ..you can do it like you want. :8
|
Normal Way = How S4 Do It ... This isn´t an ITC-Thread its "ITC"
Quote:
Originally Posted by »Unknown«
95% der S4 Section sind doch eh zu dumm um das anzuwenden. ^^
|
Das ist mir egal. Es gibt genug die einfach nichts auf EPVP schreiben, wie ich eig. auch.
|
|
|
06/18/2016, 13:47
|
#7
|
elite*gold: 0
Join Date: Nov 2014
Posts: 741
Received Thanks: 2,648
|
Quote:
Originally Posted by Decrypted
Normal Way = How S4 Do It ... This isn´t an ITC-Thread its "ITC"
Das ist mir egal. Es gibt genug die einfach nichts auf EPVP schreiben, wie ich eig. auch.
|
ITC -> Item Creator -> Jede Methode um ein Item zu erstellen
|
|
|
06/18/2016, 13:50
|
#8
|
elite*gold: 0
Join Date: Jun 2014
Posts: 29
Received Thanks: 2
|
Can anyone send me a link where i can download the faithdev injector pls
|
|
|
06/18/2016, 14:34
|
#9
|
elite*gold: 26
Join Date: Jan 2012
Posts: 3,474
Received Thanks: 18,844
|
That's how I did it in the past when I tried to deal with it for the first time. The item struct and rmiID may changed over time. It still needs some more detours which you gotta figure out on your own.
Code:
namespace rmiIDs
{
static const uint16_t Item_InventoryInfo_Ack = 0xEA65;
}
namespace Functions
{
typedef bool(__fastcall *tProcessReceivedMessage)(void *, void *, Proud::CMessage *, void *);
tProcessReceivedMessage oProcessReceivedMessage = nullptr;
}
namespace S4
{
struct Effect
{
uint32_t EnchantID;
uint32_t Period;
uint64_t PurchaseTime;
uint32_t uk = 0;
bool __isEnchant = false; // defined by my own to seek out if the enchant counter needs to become increased
};
struct Item
{
uint64_t UniqueID;
uint32_t ItemID;
uint32_t PriceType;
uint32_t PeriodType;
uint16_t Period;
uint32_t Color;
uint64_t PurchaseDate;
uint32_t Energy;
// uint32_t EffectCounter;
std::vector<S4::Effect> Effects;
uint32_t MP;
// uint32_t EnchantCount;
};
}
void loadInventory(Proud::CMessage *pMessage)
{
std::vector<S4::Item> vInventory; // container which holds the "new" inventory
pMessage->Clear();
pMessage->Write(static_cast<uint16_t>(rmiIDs::Item_InventoryInfo_Ack));
pMessage->Write(static_cast<uint32_t>(vInventory.size()));
for (const auto &item : vInventory)
{
pMessage->Write(static_cast<uint64_t>(item.UniqueID));
pMessage->Write(static_cast<uint32_t>(item.ItemID));
pMessage->Write(static_cast<uint32_t>(item.PriceType));
pMessage->Write(static_cast<uint32_t>(item.PeriodType));
pMessage->Write(static_cast<uint16_t>(item.Period));
pMessage->Write(static_cast<uint32_t>(item.Color));
pMessage->Write(static_cast<uint64_t>(item.PurchaseDate));
pMessage->Write(static_cast<uint32_t>(item.Energy));
pMessage->Write(static_cast<uint32_t>(item.Effects.size()));
auto EnchantCounter = 0;
for (const auto &effect : item.Effects)
{
pMessage->Write(static_cast<uint32_t>(effect.EnchantID));
pMessage->Write(static_cast<uint32_t>(effect.Period));
pMessage->Write(static_cast<uint64_t>(effect.PurchaseTime));
pMessage->Write(static_cast<uint32_t>(effect.uk));
if (effect.__isEnchant)
++EnchantCounter;
}
pMessage->Write(static_cast<uint32_t>(item.MP));
pMessage->Write(static_cast<uint32_t>(EnchantCounter));
}
}
// detour
bool __fastcall hProcessReceivedMessage(void *ecx, void *edx, Proud::CMessage *pMessage, void *pHostTag)
{
if (pMessage != nullptr)
{
uint16_t rmiID;
pMessage->Read(rmiID);
if (rmiID == rmiIDs::Item_InventoryInfo_Ack)
loadInventory(pMessage);
pMessage->SetReadOffset(0);
}
return Functions::oProcessReceivedMessage(ecx, edx, pMessage, pHostTag);
}
|
|
|
06/18/2016, 16:32
|
#10
|
elite*gold: 0
Join Date: Mar 2016
Posts: 70
Received Thanks: 176
|
Quote:
Originally Posted by Sycode'
ITC -> Item Creator -> Jede Methode um ein Item zu erstellen 
|
English. Can you read it?
"Normal Way = How S4 Do It" srsly learn to read
|
|
|
06/18/2016, 17:18
|
#11
|
elite*gold: 0
Join Date: Nov 2014
Posts: 741
Received Thanks: 2,648
|
Quote:
Originally Posted by Decrypted
English. Can you read it?
"Normal Way = How S4 Do It" srsly learn to read
|
No i can't. Finn
But say "Normal Way of S4" next time kkkkkk ? and adding items is also a normal way of s4 (if you buy or craft)...
|
|
|
06/18/2016, 17:20
|
#12
|
elite*gold: 0
Join Date: Jun 2011
Posts: 13
Received Thanks: 0
|
???? I dont understand XD
|
|
|
06/18/2016, 17:30
|
#13
|
elite*gold: 0
Join Date: Mar 2016
Posts: 70
Received Thanks: 176
|
Quote:
Originally Posted by Sycode'
No i can't. Finn
But say "Normal Way of S4" next time kkkkkk ? and adding items is also a normal way of s4 (if you buy or craft)...
|
Np Virus.Bat
|
|
|
06/18/2016, 19:43
|
#14
|
elite*gold: 10
Join Date: Dec 2013
Posts: 1,224
Received Thanks: 3,095
|
Quote:
Originally Posted by Decrypted
Virus.Bat
|
Ich frage mich warum ihn bis heute keiner wegen multiaccounting bannen lässt... Sein einer soulcr4ck acc ist ja noch nicht gebannt.
@topic pretty usefull for us. thanks
|
|
|
06/18/2016, 20:10
|
#15
|
elite*gold: LOCKED
Join Date: Oct 2014
Posts: 1,258
Received Thanks: 12,469
|
Quote:
Originally Posted by TheMokko
Ich frage mich warum ihn bis heute keiner wegen multiaccounting bannen lässt... Sein einer soulcr4ck acc ist ja noch nicht gebannt.
@topic pretty usefull for us. thanks
|
I thought you'd retire from elitepvpers. Why not leave already?
|
|
|
All times are GMT +1. The time now is 04:43.
|
|