This is my original post from mmoelites figured Id share it here aswell
hey guys some of the stuff I needed for my bot was to see the current error message,... the length of that message , if the player is moving and if a player has agro or should I say "being attacked by an agro mob" return 1... simple stuff, but much needed for certain functions...
Code:
public const uint Playerbase = 0x0F48C20;
public const uint IsAgroStatic = 0x0E30A25;
public const uint ErrorMsgBase = 0x0E25380;
public const uint ErrorMsgOffs = 0x0;
//IsRunningbase+offs
public const uint RunBase1 = 0x17C;
public const uint RunBase2 = 0x270;
public const uint RunBase3 = 0x004;
public const uint RunBase4 = 0x024;
public const uint IsPlayerRunningOffset = 0x175;
Example code for _IsMoving Function...
Code:
//getrunningbase
RunningBase = Rift.ReadUInt(playerBase + PlayerData.RunBase1);
RunningBase = Rift.ReadUInt(RunningBase + PlayerData.RunBase2);
RunningBase = Rift.ReadUInt(RunningBase + PlayerData.RunBase3);
RunningBase = Rift.ReadUInt(RunningBase + PlayerData.RunBase4);
public static bool _IsMoving(BlackPosion Rift)
{
var IsMoving = 0;
IsMoving = Rift.ReadByte(RunningBase + PlayerData.IsPlayerRunningOffset);
if (IsMoving == 1)
{
Console.WriteLine("Toon is moving!!");
return (true);
}
return (false);
}
Example for _IsAgro()
Code:
public static bool _IsAgro(BlackPosion Rift)
{
var IsAgro = 0;
IsAgro = Rift.ReadByte((uint) _baseAddress(Rift) + PlayerData.IsAgroStatic);
if (IsAgro == 1)
{
Report("::Agro Detected!");
return (true);
}
return (false);
}
And last but not least the error messages!! (I hard coded the length since Im lazy and dont even need the function that much... so buzz off! lol
Code:
public static string GetErrorMessage(BlackPosion Rift)
{
var lenbase = Rift.ReadUInt((uint) _baseAddress(Rift) + 0x0E20CDC);
lenbase = Rift.ReadUInt(lenbase + 0x5E4);
lenbase = Rift.ReadUInt(lenbase + 0x340);
lenbase = Rift.ReadUInt(lenbase + 0x1D0);
lenbase = Rift.ReadUInt(lenbase + 0x0);
int strLen = Rift.ReadByte(lenbase + 0x53);
Report("Error Message Length: " + strLen);
var errorbase = Rift.ReadUInt((uint) _baseAddress(Rift) + PlayerData.ErrorMsgBase);
var ErrorMsg = Rift.ReadUnicodeString(errorbase + PlayerData.ErrorMsgOffs, strLen);
Report("Error Message: " + ErrorMsg);
if (ErrorMsg == "You are too far away")
return ("ToFarAway");
if (ErrorMsg == "You must be facing your target!")
return ("NotFacing");
else
{
return (ErrorMsg);
}
}
sorry if some of my names confuzzzzeeeees you, but hey what can you do!
plz press thanks DiS iS WhY We pOsT!
Hope this helps someone!
-jay(aceticsoft.com)
edit* and just incase anyone needs to see my _baseAddress() function
Code:
public static int _baseAddress(BlackPosion Rift)
{
int baseaddress = Rift.MainModule.BaseAddress.ToInt32();
return (baseaddress);
}
Edit*** Fixed the CurrentErrorMessage...
public const uint ErrorMsgBase = 0x0E25380; + 0x0 -->should point to CurrentErrorMessage