Код:
interface
type
TAI = class
public
function Health: Integer;
procedure Attack;
end;
implementation
procedure TAI.Attack;
begin
// do it
end;
function TAI.Health: Integer;
begin
Result:=0;
end;
>>
Код:
var
ai: TAI;
i: Integer;
begin
ai:=TAI.Create;
try
ai.Attack;
i:=ai.Health;
finally
ai.Free;
end;
end;
__________________
Пишу программы за еду.
__________________
|