Chams not working [C#]
So, to clarify, I've coded chams before in C++ but they aren't working in my C# code.
I used WriteByte because the C++ Color class uses unsigned char, which is the C# equivalent of byte, from what I've read. The result of this was pink enemies and blue teammates, when it should have been red enemies and green teammates.
Any ideas?
Code:
void DrawCham(uint entity, byte r, byte g, byte b, byte a)
{
myPlayer.fProcess.WriteByte((int)(entity + 0x70), r);
myPlayer.fProcess.WriteByte((int)(entity + 0x74), g);
myPlayer.fProcess.WriteByte((int)(entity + 0x78), b);
myPlayer.fProcess.WriteByte((int)(entity + 0x7C), a);
}
public void CHAMS()
{
if (Toggles.Default.Chams)
{
for (int i = 0; i < 32; i++)
{
if (myPlayer.ENTEAM(i) == myPlayer.TEAM())
{
DrawCham(myPlayer.BASEENT(i), (byte)0, (byte)255, (byte)0, (byte)255);
}
else if (myPlayer.ENTEAM(i) != myPlayer.TEAM())
{
DrawCham(myPlayer.BASEENT(i), (byte)255, (byte)0, (byte)0, (byte)255);
}
}
}
}
Any ideas?
