-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWork.pas
More file actions
219 lines (205 loc) · 5.04 KB
/
Work.pas
File metadata and controls
219 lines (205 loc) · 5.04 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
unit Work;
interface
uses
Windows, Forms,
param, jpeg, StdCtrls, Controls, Classes, ExtCtrls;
type
TWrks = class(TForm)
Button1: TButton;
Image1: TImage;
Label1: TLabel;
GroupBox1: TGroupBox;
dv: TRadioButton;
pl: TRadioButton;
ta: TRadioButton;
si: TRadioButton;
pe: TRadioButton;
me: TRadioButton;
dr: TRadioButton;
bi: TRadioButton;
pr: TRadioButton;
sh: TRadioButton;
mo: TRadioButton;
sl: TRadioButton;
Button2: TButton;
gc: TRadioButton;
procedure WtypeClick(Sender: TObject);
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure dvMouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
procedure FormActivate(Sender: TObject);
procedure FormKeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Wrks: TWrks;
implementation
uses Main;
{$R *.dfm}
procedure TWrks.WtypeClick(Sender: TObject);
begin
Button1.Enabled:=true;
end;
procedure TWrks.Button1Click(Sender: TObject);
begin
If dv.checked=true then begin
rating:=rating+1;
MainForm.Label36.Caption:='Äâîðíèê';
zarpl:=40;
close;
end;
If sh.checked=true then begin
rating:=rating+1.5;
MainForm.Label36.Caption:='Øîôåð';
zarpl:=63;
close;
end;
If mo.checked=true then begin
rating:=rating+2;
MainForm.Label36.Caption:='Ìîíòåð';
zarpl:=84;
close;
end;
If sl.checked=true then begin
rating:=rating+2.5;
MainForm.Label36.Caption:='Ñëåñàðü';
zarpl:=98;
close;
end;
If pl.checked=true then begin
rating:=rating+3;
MainForm.Label36.Caption:='Ïëîòíèê';
zarpl:=112;
close;
end;
If ta.checked=true then begin
rating:=rating+3.5;
MainForm.Label36.Caption:='Òàêñèñò';
zarpl:=132;
close;
end;
If si.checked=true then begin
rating:=rating+4;
MainForm.Label36.Caption:='Ñèñàäìèí';
zarpl:=145;
close;
end;
If pe.checked=true then begin
rating:=rating+4.5;
MainForm.Label36.Caption:='Ïåðåâîä÷èê';
zarpl:=152;
close;
end;
If me.checked=true then begin
rating:=rating+5;
MainForm.Label36.Caption:='Ìåäèê';
zarpl:=166;
close;
end;
If dr.checked=true then begin
rating:=rating+5.5;
MainForm.Label36.Caption:='×. Âîäèòåëü';
zarpl:=195;
close;
end;
If bi.checked=true then begin
rating:=rating+6;
MainForm.Label36.Caption:='Áèçíåñìåí';
zarpl:=221;
close;
end;
If pr.checked=true then begin
rating:=rating+8;
MainForm.Label36.Caption:='Ïðîãðàììèñò';
zarpl:=382;
close;
end;
If gc.checked=true then begin
rating:=rating+10;
MainForm.Label36.Caption:='Íà÷àëüíèê';
lastwork:=true;
zarpl:=500;
close;
end;
end;
procedure TWrks.Button2Click(Sender: TObject);
begin
Close;
end;
procedure TWrks.dvMouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
begin
Button1.Enabled:=true;
end;
procedure TWrks.FormActivate(Sender: TObject);
begin
Button1.Enabled:=false;
If Rating>=0 then
dv.Enabled:=true;
If Rating>=41 then
sh.Enabled:=true;
If Rating>=61 then
mo.Enabled:=true;
If Rating>=83 then
sl.Enabled:=true;
If Rating>=104 then
pl.Enabled:=true;
If Rating>=126 then
ta.Enabled:=true;
If Rating>=169 then
si.Enabled:=true;
If Rating>=197 then
pe.Enabled:=true;
If Rating>=231 then
me.Enabled:=true;
If Rating>=274 then
dr.Enabled:=true;
If Rating>=308 then
bi.Enabled:=true;
If Rating>=427 then
pr.Enabled:=true;
If Rating>=500 then
gc.Enabled:=true;
If MainForm.Label36.Caption='Íåò' then
dv.enabled:=true;
If MainForm.LaBEL36.Caption='Äâîðíèê' then
dv.checked:=true;
If MainForm.LaBEL36.Caption='Øîôåð' then
sh.checked:=true;
If MainForm.LaBEL36.Caption='Ìîíòåð' then
mo.checked:=true;
If MainForm.LaBEL36.Caption='Ñëåñàðü' then
sl.checked:=true;
If MainForm.LaBEL36.Caption='Ïëîòíèê' then
pl.checked:=true;
If MainForm.LaBEL36.Caption='Òàêñèñò' then
ta.checked:=true;
If MainForm.LaBEL36.Caption='Ñèñàäìèí' then
si.checked:=true;
If MainForm.LaBEL36.Caption='Ïåðåâîä÷èê' then
pe.checked:=true;
If MainForm.LaBEL36.Caption='Ìåäèê' then
me.checked:=true;
If MainForm.LaBEL36.Caption='×. Âîäèòåëü' then
dr.checked:=true;
If MainForm.LaBEL36.Caption='Áèçíåñìåí' then
bi.checked:=true;
If MainForm.LaBEL36.Caption='Ïðîãðàììèñò' then
pr.checked:=true;
If MainForm.LaBEL36.Caption='Íà÷àëüíèê' then
gc.checked:=true;
If MainForm.Label36.Caption='Íåò' then
Application.MessageBox('Äëà íà÷àëà óñòðîéòåñü íà êàêóþ íèáóäü ðàáîòó. Íà÷àëüíûé êàïèòàë îíî êîíå÷íî õîðîøî, íî âåäü îí íå ðåçèíîâûé, íàäî è äåíüãè çàðàáàòûâàòü.','Ïîìîùü!',MB_ICONASTERISK);
end;
procedure TWrks.FormKeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
begin
If (key=VK_ESCAPE) then
Button2.OnClick(self);
end;
end.