Курсовая работа: Моделирование систем
var i : integer;
begin
if Assigned(FParcels) then begin
for i := 0 to FParcels.Count - 1 do TParcel(FParcels[i]).Free;
FParcels.Clear;
end;
end;
procedure TQSheme.InitEmulation;
var i : integer;
begin
ClearParcelList;
ClearEventQueue;
for i := 0 to ElementCount - 1 do
Elements[i].ClearContainer;
FFinishElements := TList.Create;
end;
procedure TQSheme.FreeEmulation;
begin
FFinishElements.Free;
end;
procedure TQSheme.Emulation;
begin
try
InitEmulation;
Analize;
while FSysTime < FSysPeriod do Step;
Form1.Gauge1.Progress := 100;
//RedrawDiagram;
finally