• My Pages
  • Comments
  • Add Link
  • Subscribe
  • Subscribe User
  • Edit (GUI)
  • Edit (Text)
  • Rename Page
  • Copy Page
  • Load Page
  • Save Page
  • Delete Page
  • Attachments
  • Check Spelling
  • Diffs
  • Info
  • Revert to this revision
  • XML
  • Render as Docbook
  • Print View
  • Raw Text
  • Delete Cache
  • Like Pages
  • Local Site Map
  • Remove Spam
  • Package Pages
  • Sync Pages
    • Diff for "Command"
    Differences between revisions 8 and 9
    Revision 8 as of 2013-11-17 21:20:13
    Size: 2146
    Editor: Inanna
    Comment:
    Revision 9 as of 2013-11-17 21:20:24
    Size: 2147
    Editor: Inanna
    Comment:
    Deletions are marked like this. Additions are marked like this.
    Line 22: Line 22:
    Echos: Echoes:

    Usage:

    command "command [parameters]"

    Example:

    command "invite NewDude"

    This script will allow you to utilize the in-line commands in the scripting window. The in-line command plus all arguments for it should be encased in quotation marks. In the example above, instead of typing \invite NewDude in the commands window, you could use it via script with the line command "invite NewDude".

    You can mix variables into the command script, exclude them from the quotes as you would any other expression. For example:

    var = "SomeDude"
    command "who " + var

    You can find a list of all the In-Line Commands here: InLineCommands.

    The results returned from these commands will be stored in $result, which you can echo or set to a variable or process with the various functions in the bot. For example:

    command "quickarmyreport"
    echo $result
    
    Echoes:
    16:17:10 Page: 1/53
    [42957]ATT Attack Reports from City1(111,111) to Target(111,333) on Sun Nov 17 2013 01:15:10 PM
    [42914]ATT Scout Reports from City2(111,222) to Barbarian's city(111,444) on Sun Nov 17 2013 01:01:28 PM
    [42905]ATT Scout Reports from City2(111,222) to Barbarian's city(111,455) on Sun Nov 17 2013 12:57:48 PM
    [42898]ATT Scout Reports from City2(111,222) to Barbarian's city(111,466) on Sun Nov 17 2013 12:54:09 PM
    [42891]ATT Scout Reports from City2(111,222) to Barbarian's city(111,477) on Sun Nov 17 2013 12:48:58 PM
    [42885]ATT Scout Reports from City2(111,222) to Barbarian's city(111,488) on Sun Nov 17 2013 12:45:15 PM


    ScriptControlStructures

    Command (last edited 2014-06-30 20:39:22 by Inanna)