Results 1 to 5 of 5

Thread: Error: Operator expected on old script

  1. #1
    Join Date
    Mar 2013
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default Error: Operator expected on old script

    I've just gone through and installed Simba/SRL, I used to use it back when OSR came back, I have a script from back then I'd like to use but when I attempt to compile I get that error. The line it hangs on is
    Code:
    ClickMouse2(mouse_left);
    it also has
    Code:
    {$DEFINE SMART8}
    {$I SRL-OSR/SRL.Simba}
    at the start. I'm wondering if there's something I'm missing or if because it's so old there's something I might need to update to get it to function? Thanks.

  2. #2
    Join Date
    Jan 2012
    Posts
    2,568
    Mentioned
    35 Post(s)
    Quoted
    356 Post(s)

    Default

    Nothing wrong with that line.
    What's the line before that? Probably a missing semicolon.

  3. #3
    Join Date
    Mar 2013
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Wow, you're right. I'm getting another error now though
    Code:
    Error: Can't assign "Extended" to "Int32" at line 155
    this is the chunk of code it points to: http://pastebin.com/npJ7AnSQ, specifically, the line
    Code:
     row := (((i-1)/9)+1);
    All my variables are integers. I've tried changing rows to Extended which works but gives me other errors where the row variable needs to be an integer.
    Last edited by Chryma; 12-19-2016 at 12:46 AM.

  4. #4
    Join Date
    Jan 2012
    Posts
    2,568
    Mentioned
    35 Post(s)
    Quoted
    356 Post(s)

    Default

    Quote Originally Posted by Chryma View Post
    Wow, you're right. I'm getting another error now though
    Code:
    Error: Can't assign "Extended" to "Int32" at line 155
    this is the chunk of code it points to: http://pastebin.com/npJ7AnSQ, specifically, the line
    Code:
     row := (((i-1)/9)+1);
    All my variables are integers. I've tried changing rows to Extended which works but gives me other errors where the row variable needs to be an integer.
    Your script is written with PascalScript. In Lape '/' is float division even when operands are integers.
    Change "(((i-1)/9)+1)" to "(((i-1) DIV 9)+1)"

    Or maybe just change script -> intepreter to PascalScript?

  5. #5
    Join Date
    Mar 2013
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Changing it to PascalScript fixed it completely, thanks!

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
  •