Results 1 to 17 of 17

Thread: How do you See Text?

  1. #1
    Join Date
    Oct 2009
    Posts
    55
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default How do you See Text?

    I wanted to know how to make something like an autresponder for my bot. I was wondering if you just type something like:

    Code:
    Procedure Responder;
    Begin
    If FindText('TEXTHERE') Then
    TypeSend('RESPONCEHere')
    End;
    Begin
    If FindText('TEXTHERE') Then
    TypeSend('RESPONCEHere')
    End;
    Begin
    If FindText('TEXTHERE') Then
    TypeSend('RESPONCEHere')
    End;
    Something like that mabey?
    Last edited by Zerghunter3000; 10-25-2009 at 12:27 AM.

  2. #2
    Join Date
    Oct 2008
    Location
    C:\Simba\Includes\
    Posts
    7,566
    Mentioned
    19 Post(s)
    Quoted
    180 Post(s)

    Default

    Some of the common ways are:
    • InChat(); - Grabs Last Chat Line and performs checks on occurence of text
    • FindNPCChatText(); - Finds a text said by a NPC in chat.
    • GetBlackText(); - Gets the black message text on ChatLine (1 to 8).


    If you want to see all the functions, look under: SRL\Core\Text.scar. Making an autoresponder can be a challenge, it takes a lot of work. If you need help, feel free to PM me. Good luck

    ~Camo
    Away for awhile, life is keeping me busy. | Want to get my attention in a thread? @Kyle Undefined; me.
    { MSI Phoenix || SRL Stats Sigs || Paste || Scripts || Quotes || Graphics }

    When posting a bug, please post debug! Help us, help you!

    I would love to change the world, but they won't give me the source code. || To be the best, you've got to beat the rest. || Logic never changes, just the syntax.
    If you PM me with a stupid question or one listed in FAQ, or about a script that is not mine, I will NOT respond.


    SRL is a Library of routines made by the SRL community written for the Program Simba. We produce Scripts for the game Runescape.


  3. #3
    Join Date
    Oct 2009
    Posts
    55
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    thx man

  4. #4
    Join Date
    Feb 2009
    Posts
    1,447
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    First, you use LastChatter to check if you were the last chatter, if you were then Exit the procedure.

    Then make a variable to store the last line of text to. Set that variable to "(Lowercase(GetChatBoxText(8, clBlue)) + ' ')" after the LastChatter check.

    Then start a case of the variable.

    Ex:

    SCAR Code:
    case LastLineOfText of
      'hey': TypeSend('hey');
      'wc?': TypeSend('99');
    end;

  5. #5
    Join Date
    Oct 2009
    Posts
    55
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    So would InChat(); thing see wut someone says, like hi, and can respond

    [Would this work?]
    Code:
    If InChat(hi); Then
    TypeSend('hi');

  6. #6
    Join Date
    Oct 2008
    Location
    C:\Simba\Includes\
    Posts
    7,566
    Mentioned
    19 Post(s)
    Quoted
    180 Post(s)

    Default

    SCAR Code:
    if(InChat('hi'))then
      TypeSend('hi');

    ~Camo

    Also, didn't see you edited your first post, so my answer isn't 100% right but Trilez said what I didn't.
    Away for awhile, life is keeping me busy. | Want to get my attention in a thread? @Kyle Undefined; me.
    { MSI Phoenix || SRL Stats Sigs || Paste || Scripts || Quotes || Graphics }

    When posting a bug, please post debug! Help us, help you!

    I would love to change the world, but they won't give me the source code. || To be the best, you've got to beat the rest. || Logic never changes, just the syntax.
    If you PM me with a stupid question or one listed in FAQ, or about a script that is not mine, I will NOT respond.


    SRL is a Library of routines made by the SRL community written for the Program Simba. We produce Scripts for the game Runescape.


  7. #7
    Join Date
    Oct 2009
    Posts
    55
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    oh do i put a begin before that or make it a procedure mabey?
    And does it work the whole time the script is going or do i have to do sumtin to make that happen?
    Last edited by Zerghunter3000; 10-25-2009 at 12:52 AM.

  8. #8
    Join Date
    Oct 2008
    Location
    C:\Simba\Includes\
    Posts
    7,566
    Mentioned
    19 Post(s)
    Quoted
    180 Post(s)

    Default

    I would make it into a procedure, so you can just call it when needed.

    ~Camo
    Away for awhile, life is keeping me busy. | Want to get my attention in a thread? @Kyle Undefined; me.
    { MSI Phoenix || SRL Stats Sigs || Paste || Scripts || Quotes || Graphics }

    When posting a bug, please post debug! Help us, help you!

    I would love to change the world, but they won't give me the source code. || To be the best, you've got to beat the rest. || Logic never changes, just the syntax.
    If you PM me with a stupid question or one listed in FAQ, or about a script that is not mine, I will NOT respond.


    SRL is a Library of routines made by the SRL community written for the Program Simba. We produce Scripts for the game Runescape.


  9. #9
    Join Date
    Oct 2009
    Posts
    55
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Well I want it so that WHENEVER it sees the text it resonds, not only when i say for it to

  10. #10
    Join Date
    Oct 2006
    Location
    Netherlands
    Posts
    3,285
    Mentioned
    105 Post(s)
    Quoted
    494 Post(s)

    Default

    The only solution is to say it alot of times, like in you mainloop and after every line of code...

  11. #11
    Join Date
    Oct 2009
    Posts
    55
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    ok ill try it lol jk ill figure sdumtin out lol
    Edgville WoodCutter Version 0.0.3 is out! Get it Now! Version 0.0.3!
    Get it here:
    http://www.villavu.com/forum/showthr...110#post648110
    Yesterday is history. - Tommorrow is a Mistery. - But today is a Gift.
    (Only if it was that simple)

  12. #12
    Join Date
    Oct 2007
    Location
    http://ushort.us/oqmd65
    Posts
    2,605
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    You have to make it check at certain times, but not certainly every other line lol.

    If you have like a checkforrandoms procedure, just stick it in there, so everytime it checks for randoms, it also checks for someone talking.
    I do visit every 2-6 months

  13. #13
    Join Date
    Oct 2009
    Posts
    55
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Well, I tried the typesend and it says:
    SCAR Code:
    Line 68: [Error] (20384:6): Unknown identifier 'LastLineOfText' in script
    ugh ok bit annoyed lol, any help?
    Edgville WoodCutter Version 0.0.3 is out! Get it Now! Version 0.0.3!
    Get it here:
    http://www.villavu.com/forum/showthr...110#post648110
    Yesterday is history. - Tommorrow is a Mistery. - But today is a Gift.
    (Only if it was that simple)

  14. #14
    Join Date
    Oct 2007
    Location
    http://ushort.us/oqmd65
    Posts
    2,605
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    They didn't give you right function.

    GetLastChatText.

    use:
    SCAR Code:
    procedure respond;
    var
      ctext : String
    begin
      GetLastChatText(ctext);
      case ctext of
        'hi' : typesend('Hi!');
      end;
    end;
    I do visit every 2-6 months

  15. #15
    Join Date
    Oct 2009
    Posts
    55
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    thx
    Edgville WoodCutter Version 0.0.3 is out! Get it Now! Version 0.0.3!
    Get it here:
    http://www.villavu.com/forum/showthr...110#post648110
    Yesterday is history. - Tommorrow is a Mistery. - But today is a Gift.
    (Only if it was that simple)

  16. #16
    Join Date
    Jan 2008
    Location
    Ontario, Canada
    Posts
    7,805
    Mentioned
    5 Post(s)
    Quoted
    3 Post(s)

    Default

    Just so you know.. you will have to use a LOT of arrays.. if you want a good responder
    Writing an SRL Member Application | [Updated] Pascal Scripting Statements
    My GitHub

    Progress Report:
    13:46 <@BenLand100> <SourceCode> @BenLand100: what you have just said shows you 
                        have serious physchological problems
    13:46 <@BenLand100> HE GETS IT!
    13:46 <@BenLand100> HE FINALLY GETS IT!!!!1

  17. #17
    Join Date
    May 2009
    Posts
    799
    Mentioned
    2 Post(s)
    Quoted
    16 Post(s)

    Default

    Quote Originally Posted by Zerghunter3000 View Post
    Well I want it so that WHENEVER it sees the text it resonds, not only when i say for it to
    Check out my tutorial about timer . That enables you to always check for ingame-text-chat while your bot is running without calling your procedure manually. - http://www.villavu.com/forum/showthread.php?t=51578

    ~caused

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •