Results 1 to 5 of 5

Thread: What can i do???

  1. #1
    Join Date
    Oct 2006
    Posts
    10
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default What can i do???

    Well im want to start scripting very well but i dont know what kind of scripts can i do topractice and learn new things....
    What can i do???ill give my first and Last script ive done but i need some help too...is an auto talker (very easy) but i wanted to meke it with orm and i dont know why i cant use it very well...See it for urself:
    SCAR Code:
    ////////////////////////////////////////////////
    ////////////ChErRy'S AuTo TaLkEr////////////////
    ////////////////////////////////////////////////
    program CherrysAutoTalker;
    {.include SRL/SRL.scar}
    var
      frmDesign : TForm;
      Panel1 : TPanel;
      Label1 : TLabel;
      Label2 : TLabel;
      Button1 : TButton;
      Edit1 : TEdit;
      Edit2 : TEdit;
      Write : string;
      Delay : integer;

    procedure ClickButton(Sender: TObject);
    Begin
    Write := Edit1.Text;
    Delay := StrToInt(Edit1.Text);
    End;

    Procedure InitForm;
    Begin
    frmDesign := CreateForm;
    frmDesign.Left := 274;
    frmDesign.Top := 134;
    frmDesign.Width := 339;
    frmDesign.Height := 197;
    frmDesign.Caption := 'frmDesign';
    frmDesign.Color := clBtnFace;
    frmDesign.Font.Color := clWindowText;
    frmDesign.Font.Height := -11;
    frmDesign.Font.Name := 'MS Sans Serif';
    frmDesign.Font.Style := [];
    frmDesign.Visible := False;
    frmDesign.PixelsPerInch := 96;
    Panel1 := TPanel.Create(frmDesign);
    Panel1.Parent := frmDesign;
    Panel1.Left := -1;
    Panel1.Top := 0;
    Panel1.Width := 330;
    Panel1.Height := 162;
    Panel1.Caption := 'Panel1';
    Panel1.TabOrder := 0;
    Label1 := TLabel.Create(Panel1);
    Label1.Parent := Panel1;
    Label1.Left := 12;
    Label1.Top := 36;
    Label1.Width := 60;
    Label1.Height := 13;
    Label1.Caption := 'What to say:';
    Label2 := TLabel.Create(Panel1);
    Label2.Parent := Panel1;
    Label2.Left := 23;
    Label2.Top := 77;
    Label2.Width := 30;
    Label2.Height := 13;
    Label2.Caption := 'Delay:';
    Button1 := TButton.Create(Panel1);
    Button1.Parent := Panel1;
    Button1.Left := 120;
    Button1.Top := 129;
    Button1.Width := 75;
    Button1.Height := 25;
    Button1.Cursor := crHandPoint;
    Button1.Caption := 'Start';
    Button1.ModalResult := 1;
    Button1.TabOrder := 0;
    Edit1 := TEdit.Create(Panel1);
    Edit1.Parent := Panel1;
    Edit1.Left := 86;
    Edit1.Top := 34;
    Edit1.Width := 191;
    Edit1.Height := 22;
    Edit1.TabOrder := 1;
    Edit2 := TEdit.Create(Panel1);
    Edit2.Parent := Panel1;
    Edit2.Left := 86;
    Edit2.Top := 72;
    Edit2.Width := 192;
    Edit2.Height := 22;
    Edit2.TabOrder := 2;
    Edit2.Text := 'in miliseconds';
    End;

    procedure SafeInitForm;
    var
      v: TVariantArray;
    begin
      setarraylength(V, 0);
      ThreadSafeCall('InitForm', v);
    end;

    procedure ShowFormModal;
    begin
      frmDesign.ShowModal;
    end;

    procedure SafeShowFormModal;
    var
      v: TVariantArray;
    begin
      setarraylength(V, 0);
      ThreadSafeCall('ShowFormModal', v);
    end;


    Procedure Talk;
    Begin
    Wait(Delay+random(50));
    TypeSend(Write);
    Wait(Delay+random(50));
    End;

    begin
    SafeInitForm;
    SafeShowFormModal;
    ActivateClient;
    Repeat
    Talk;
    until (false)
    end.

  2. #2
    Join Date
    Feb 2007
    Location
    SparklesProd.com
    Posts
    2,406
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    Nice, you seem to have the form creating down to a tee :P

    I'd advise you to just read the intermediate / Advanced tuts and then make something you've always wanted to, study a similiar script if you must to get ideas.

  3. #3
    Join Date
    Oct 2006
    Posts
    10
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    yes but why does my script dont work????i dont know...

  4. #4
    Join Date
    Sep 2006
    Posts
    5,219
    Mentioned
    4 Post(s)
    Quoted
    1 Post(s)

    Default

    See my FAQ

  5. #5
    Join Date
    Oct 2006
    Posts
    10
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    ya i saw it but i dont know what happens to my script XD i want to know that XD

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
  •