
Originally Posted by
riwu
try
Simba Code:
TheName:=Between(']', '?', GetLastClanMsg);
Didn't work for me.
I have made a really dirty way of doing this...
Simba Code:
function GetLastClanMsg: string;
var
P: TPoint;
cArr: TPointArray;
B: TBox;
begin
Result := '';
P := TextCoords(8);
if (FindColorsTolerance(cArr, 0, MCX1, P.y, MCX2, P.y + 13, 255)) then
begin
B := GetTPABounds(cArr);
result := Trim(GetTextAtExWrap(b.x1-1,p.y,B.x2+1,p.y+13,0,5,2,0,255,SmallCharsNS));
end;
end;
Simba Code:
Tmp := GetLastClanMsg;
Tmp := Replace(Tmp,'..',':');
Tmp := Replace(Tmp,'[','');
Tmp := Replace(Tmp,']','');
FinalMsg := Replace(Tmp,'CLAN NAME ','/');
if ((Pos('@Follow', FinalMsg) > 0) or ((Pos('@follow', FinalMsg) > 0))) then
begin
Writeln(FinalMsg);
Writeln('@Follow command activated by : ' + Between('/', ':', FinalMsg));
FindClanMember;
Wait(60000);
end;