Hi,
I'm trying to create a skin changer in C#, I'm using some code I found on ****** to try and make it work.
Right now, I've got the forcefullupdate working, the only problem is nothing happends.
The skin of my AK should change, but it simply does nothing after the force update.
Code:
int m_hActiveWeapon = 0x2EE8;
int m_hMyWeapons = 0x2DE8;
int m_iItemDefinitionIndex = 0x2F88;
int m_iAccountID = 0x2FA8;
int m_OriginalOwnerXuidLow = 0x3160;
int m_OriginalOwnerXuidHigh = 0x3164;
int m_iItemIDLow = 0x2FA4;
int m_iItemIDHigh = 0x2FA0;
int m_nFallbackPaintKit = 0x3168;
int m_nFallbackSeed = 0x316C;
int m_flFallbackWear = 0x3170;
int m_nFallbackStatTrak = 0x3174;
int m_iEntityQuality = 0x2F8C;
int m_szCustomName = 0x301C;
for (int i=0; i<64; i++)
{
int LocalP = OdczytajWartosc(clientO + 0x00A3A43C);
int CurrentWeaponIndex = OdczytajWartosc(LocalP + m_hMyWeapons + ((i - 1) * 0x4)) & 0xFFF; //localplayer
int CurrentWeaponEntity = OdczytajWartosc(LocalP + EntityListO + (CurrentWeaponIndex - 1) * 0x10);
int CurrentWeaponId = OdczytajWartosc(CurrentWeaponEntity + m_iItemDefinitionIndex);
int MyXuid = OdczytajWartosc(CurrentWeaponEntity + m_OriginalOwnerXuidLow);
WriteMem(CurrentWeaponEntity + m_iItemIDHigh, BitConverter.GetBytes(-1)); //When iItemIDHigh is set to non zero value, fallback values will be used.
WriteMem(CurrentWeaponEntity + m_nFallbackPaintKit, BitConverter.GetBytes(600));
WriteMem(CurrentWeaponEntity + m_nFallbackSeed, BitConverter.GetBytes(118));
WriteMem(CurrentWeaponEntity + m_nFallbackStatTrak, BitConverter.GetBytes(118));
WriteFloat(CurrentWeaponEntity + m_flFallbackWear, 0.0000001f);
WriteMem(CurrentWeaponEntity + m_iAccountID, BitConverter.GetBytes(MyXuid));
}
System.Threading.Thread.Sleep(5); //5 milisekundowa przerwa, by program nie zjadał 100% CPU.
}
}
- - - Updated - - -
Update: Managed to fix it after like an hour, thread can be closed!
- - - Updated - - -
EDIT: So, it does work now but I'm not sure how to change the knife
I'm basicly looking for which offsets to change for the knife