Yes, you can find it in the Activemodal (877) field. It's tricky to extract the values, but not impossible:
- Code: Select all
string Activemodal = AS3.Getfield(877); // Field 877: Activemodal
string Params = "";
string temp = "";
string[] WordSeparator = new string[] {"|"};
string[] ParamSeparator = new string[] {","};
string[] Modals = Activemodal.Split(WordSeparator, StringSplitOptions.None);
string[] G68Params;
foreach (string s in Modals)
{
if (s.Substring(0, 3) == "G68")
Params = s;
}
if (Params == "")
temp = "G69 (not rotated)";
else
{
Params = Params.Substring(4, Params.Length - 5);
G68Params = Params.Split(ParamSeparator, StringSplitOptions.None);
temp = "G68 A" + G68Params[0] + " B" + G68Params[1] + " " + G68Params[2];
}
MessageBox.Show(temp);
As you see, first you need to split the modals to get strings including "G69" or "G68[aa.a,bb.b,Rrr.r]". If there is a string with "G68" in the first 3 letters, then you have to cut the beginning and the end of this string and split again. The first two parameters (A and B) are only numbers, the third has the letter "R" also in it.