-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathUnit7.pas
More file actions
executable file
·55 lines (44 loc) · 1.07 KB
/
Copy pathUnit7.pas
File metadata and controls
executable file
·55 lines (44 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
unit Unit7;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ComCtrls, ExtCtrls;
type
TForm7 = class(TForm)
Panel1: TPanel;
ProgressBar1: TProgressBar;
Button1: TButton;
procedure Mouse(Sender: TObject; Shift: TShiftState; X, Y: Integer);
procedure FormShow(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
INTER: byte;
i: byte;
implementation
uses Unit2;
{$R *.dfm}
procedure TForm7.FormShow(Sender: TObject);
begin
i := 0;
ProgressBar1.Position := 0;
end;
procedure TForm7.Mouse(Sender: TObject; Shift: TShiftState; X, Y: Integer);
begin
if i < 50 then
begin
if INTER = 0 then
begin
key[i] := (X and Y xor Random(100)) mod 100;
INTER := Random(32) shl Random(100);
inc(i);
ProgressBar1.Position := i;
end
else dec(INTER);
end
else begin ModalResult := mrOk; exit; end
end;
end.