SRL Archive - OSR Help

How do I tell simba to look for text on line 9 (the line where I type text)


rsbots2013

2013-05-30 18:59:36

What the title says OSRS SRL please

thank you

EngageTheRage

2013-05-30 19:36:10

what i understand that as is:

you want it to read in what the user typing into the chat box, before pressing enter?

to do that

typedText := GetTextAtExWrap(6, 457, 494, 472, 0, 6, 2, 16711680, 10, 'SmallChars07');
MyDeBug('gametext is: ' + typedText));

gamtext is everything you type out (the blue)

rsbots2013

2013-05-30 20:34:45

I want my script to find what I wrote beside my name in the chat box at the very bottom and if found be able to start a new procedure.

ChatBox:
Line 1
Line 2
Line 3
Line 4
Line 5
Line 6
Line 7
Line 8
——————————
Nameofcharacter: hello //I want the script to look for "hello"
——————————
All : Game : Public : Private : Clan : Trade : Report

begin
if (Simba checks the screen for "hello") then

Ashaman88

2013-06-02 09:17:36

Check out the chat.simba file - it should have the functions you want. (Findchatmessage and such). Can't remember all of them off the top of my head

EngageTheRage

2013-06-02 09:24:49

From: rsbots2013
I want my script to find what I wrote beside my name in the chat box at the very bottom and if found be able to start a new procedure.

ChatBox:
Line 1
Line 2
Line 3
Line 4
Line 5
Line 6
Line 7
Line 8
——————————
Nameofcharacter: hello //I want the script to look for "hello"
——————————
All : Game : Public : Private : Clan : Trade : Report

begin
if (Simba checks the screen for "hello") then


yeah the code i put up you can then check what typedText is …

typedText := GetTextAtExWrap(6, 457, 494, 472, 0, 6, 2, 16711680, 10, 'SmallChars07');
writeln('gametext is: ' + typedText));

if typedText = 'hello' then
begin
// do what you like
end;

rj

2013-06-02 09:39:57

Does it have to be your name? Can't you just make it search for the blue color, or count color tolerance so when you type something it finds it?

EngageTheRage

2013-06-02 10:34:35

Yeah the thing I put gets all the blue text on that line, so not your name.