Adblock breaks this site

What is wrong with this?

Discussion in 'Scar/Simba Help' started by No Im Not Ogre2, Mar 13, 2009.

  1. No Im Not Ogre2

    No Im Not Ogre2 Newcomer

    Joined:
    Mar 13, 2009
    Posts:
    1
    Referrals:
    0
    Sythe Gold:
    0
    What is wrong with this?

    I'm getting this error :
    [Error] (16834:1): Type mismatch in script C:\Users\Dillon\Desktop\Good Scripts\Miners\Wizzup SMART Essence Miner - Edited.scar

    that error is for the line "rToMsg[1] := '/Sup';

    Code:
    procedure FirstMessage;
    var
    GeneralRankBMP : String;
    i : Integer;
    rToMsg0 : array [1..4] of String;
    
    begin
      GeneralRankBMP := BitmapFromString(12, 15, 'beNrTVjTWkAciU21FI' +
           'DLDgSBqIMoIqgEiNEFkrimMARLRUvx9JRBNDcQlcMEHW9SBaoAksu' +
           'HI5M4p6t/POgHVABGQjawGiIAaQSZc9gLK/v+fAmLAENw9QF3vDpk' +
           'ARYAKIAjIfr5b73VTHMKpYGUfjhj9vOAMUfBqnxFQAbJLIAygMqAa' +
           'kJMue30/a2eKJAvxHcS675dCP24KACoAIqCIKWoAAhV8Pu0B1wK0C' +
           '6gMLTyRjcWMC1xRgKkGa5SBRADzfKHi')
           
      rToMsg0[1] := '/Sup';
      rToMsg0[2] := '/Hey';
      rToMsg0[3] := '/Hello';
      rToMsg0[4] := '/Supp';
    
      GameTab(10);
        if(FindBitmap(GeneralRankBMP, x, y)) then
        begin
          i := Random(5);
          TypeSend(rToMsg0[i]);
        end;
    end;
     
  2. HyperSecret

    HyperSecret Active Member

    Joined:
    Jun 5, 2007
    Posts:
    123
    Referrals:
    0
    Sythe Gold:
    0
    What is wrong with this?

    I haven't scripted Scar forever but doesn't the Bitmap statement need to be closed with a semi-colon at the end?

    Code:
    procedure FirstMessage;
    var
    GeneralRankBMP : String;
    i : Integer;
    rToMsg0 : array [1..4] of String;
    
    begin
      GeneralRankBMP := BitmapFromString(12, 15, 'beNrTVjTWkAciU21FI' +
           'DLDgSBqIMoIqgEiNEFkrimMARLRUvx9JRBNDcQlcMEHW9SBaoAksu' +
           'HI5M4p6t/POgHVABGQjawGiIAaQSZc9gLK/v+fAmLAENw9QF3vDpk' +
           'ARYAKIAjIfr5b73VTHMKpYGUfjhj9vOAMUfBqnxFQAbJLIAygMqAa' +
           'kJMue30/a2eKJAvxHcS675dCP24KACoAIqCIKWoAAhV8Pu0B1wK0C' +
           '6gMLTyRjcWMC1xRgKkGa5SBRADzfKHi');
           
      rToMsg0[1] := '/Sup';
      rToMsg0[2] := '/Hey';
      rToMsg0[3] := '/Hello';
      rToMsg0[4] := '/Supp';
    
      GameTab(10);
        if(FindBitmap(GeneralRankBMP, x, y)) then
        begin
          i := Random(5);
          TypeSend(rToMsg0[i]);
        end;
    end;
    
    Besides that I believe it should work. I am doing c++ right now so everything isn't fresh in my mind for Scar.
     
  3. cazax

    cazax Forum Addict

    Joined:
    Nov 13, 2007
    Posts:
    457
    Referrals:
    0
    Sythe Gold:
    0
    What is wrong with this?

    GeneralRankBMP has to be declared as Integer, not as string.
     
< Need help fixing script give ne error on pasword part | Please help i cant run scripts >


 
 
Adblock breaks this site