Results 1 to 4 of 4

Thread: Unknown identifier 'SmartSetDebug' in paintsmart.simba

  1. #1
    Join Date
    Jan 2012
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Unknown identifier 'SmartSetDebug' in paintsmart.simba

    So, i am trying to draw some text on smart, but it won't seem to work for me.
    This is the script i am using:
    Simba Code:
    program new;

    //{$DEFINE SMART}
    {$i SRL/SRL.simba}
    {$i srl/srl/misc/paintsmart.simba}


    {---SMART Setup consts---}
      const
        WORLD = 0;// Set a world, 0 = Random
        MEMBERS = False;// Self-explationary
    {---------------------------}                                      
      procedure DeclarePlayers;
      begin
        HowManyPlayers:= 1; // How many players will the script use
        NumberOfPlayers(HowManyPlayers);
        CurrentPlayer:= 0; // Which player to start at
        Players[0].Name:='';  // Login
        Players[0].Pass:='';  // Password?
        Players[0].Nick:='';  // Some Chars from the nick (last characters)
        Players[0].Active:= True; // Use this acc = true, otherwise False
        Players[0].Pin := ''; // Blank if the player doesn't have a bank pin
        Players[0].BoxRewards := ['Xp', 'mote', 'ostume', 'oins', 'aphire', 'ssence']; // What rewards do you want from random event boxes? some letters from the name of the item

      end;

      procedure trys;

      begin
         SMART_DrawText(100, 400, UpCharsEx, 'Hello World!', clRed);
      end;

      Procedure PrintOnSmart(TP: TStringArray; Placement: TPoint; Colour: integer);
      var
        mx, my, Pic, Pic2, I, B, H, TPH, Numb: Integer;
        TTP: TPointArray;
        Canvas: TCanvas;
      begin
        SmartSetDebug(True);
        GetClientDimensions(mx, my);
        Pic := BitmapFromString(mx, my, '');
        Pic2 := BitmapFromString(22, 19, 'meJytk7ENAjEMRVNSsgprsApr3A' +
            'iU11KySsoraRnDZ/Glr499CS6wopPPsV9sx2ntn3K+3ny5cnlasJy' +
            'WrUhwTzgDopYKhP50DpYKRMODvV4LSkAVUFgX9bks/Ss8Q9DbSjj0' +
            'QHCFF5QzzwRClABIJYFDQsjqZwKBoJBDwlweb/Ol3chb9hEq1Hvv6' +
            'pabqQRYTITh+LKE0Ez/hU/fbF1jRZr/aK5AgBtDdDUZp9E8MA0NvL' +
            '+MreYrm8ykb+VLYdTo6Cx8zuGlj2QHxKVFOg==');
        TPH := High(TP);
        for I := 0 to TPH do
        begin
          TTP := LoadTextTPA(TP[i], SmallChars, H);
          for B := 0 to High(TTP) do
          begin
            Numb := ((I + 1) * 13);
            FastSetPixel(Pic, TTP[b].x + 1, TTP[b].y + Numb + 1,8388736);
            FastSetPixel(Pic, TTP[b].x, TTP[b].y + Numb, Colour);
          end;
        end;
        Canvas := TCANVAS.Create;
        Canvas.Handle := SmartGetDebugDC;
        DrawBitmap(Pic, Canvas, Placement.x, Placement.y);
        DrawBitmap(Pic2, Canvas, 40, 100);
        FreeBitmap(Pic);
        FreeBitmap(Pic2);
      end;





     ////////////////////////////////////////////////////
     ////////////////////////////////////////////////////
     ////////////////////////////////////////////////////
     ////////////////////////////////////////////////////



    {----Setups----}
      procedure Setups;
      begin
        Smart_Server := WORLD;
        Smart_Members := MEMBERS;
        Smart_Signed := True;

        SetupSRL;
        DeclarePlayers;
        if not loggedIn then
        LogInPlayer;
      end;
    {--Setups end--}



    {---MAINLOOP DOWN HERE---}
    //////////////////////////
      procedure MainLoop;
      begin
      trys;

      end;
    /////////////////////////
    {----MAINLOOP ENDING----}

      begin
        Setups;
        MainLoop;
      end.
    (All the mess is just remaining pieces of my default script)
    And if it helps, here is the procedure in paintsmart.simba that messes up:
    Simba Code:
    procedure SMART_SetupDebug(); //for some reason it sometimes says it fucks up at this line, even though the error is with SmartSetDebug
    begin
      SmartSetDebug(True); //error seems to occur here
      SMART_Canvas := TBitmap.Create;
      SMART_Canvas.canvas.handle := SmartGetDebugDC;
      SMART_DebugSetup := true;
    end;

    Thanks in advance
    EDIT:
    Going to bed, then to work, so won't be back in some 16-20 hours.

  2. #2
    Join Date
    Jan 2012
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Bump.
    if there is no answer here, I would be happy if someone could move it to SRL Bugs

  3. #3
    Join Date
    Jun 2008
    Location
    United States
    Posts
    818
    Mentioned
    60 Post(s)
    Quoted
    90 Post(s)

    Default

    You have the SMART define commented out...
    [10/14/13:19:03] <BenLand100> this is special relatively, just cleverly disguised with yachts

  4. #4
    Join Date
    Jan 2012
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    I'm supposed to feel like a damn genious now, right?

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
  •