halgboy_tbc
2012-04-19 17:10:43
What can I do to detect if a certain statement is written in the rs chat box (black, regular text, like "Welcome to Runescape") so I can trigger an action?
Thanks.
Thanks.
2012-04-19 17:10:43
2012-04-19 17:12:07
(*
GetChatBoxText
~~~~~~~~~~~~~~
.. code-block:: pascal
function GetChatBoxText(Line, TextCol: Integer): string;
Gets text on the line Line with colour TextCol.
(Line 1 is the top, Line 8 is the bottom line).
Colours:
- clMessage/clBlack - Black text messages ("Oh Dear you are dead", etc).
- clChat/clBlue - Chat messages from you and other players.
- clTrade/clPurple - Colour of trade request text.
- clFriend - Colour of friend and clan chat.
Works with other colours too.
.. note::
by ZephyrsFury
Example:
.. code-block:: pascal
*) (*
FindBlackChatMessage
~~~~~~~~~~~~~~~~~~~~
.. code-block:: pascal
function FindBlackChatMessage(ChatMsg: String): Boolean;
Returns True if text with color 0 in last chat line is found.
.. note::
by Wizzup?
Example:
.. code-block:: pascal
*)
2012-04-20 18:03:42
2012-04-20 18:04:41
From: halgboy_tbc
Thanks for this and also your DTM guide, which I was reading yesterday.