Introduction to OOP: Chapter 6: Case Study: A Billiards Game [next] [previous] [audio] [real] [text]

Objects must be initialized

procedure Wall.initialize 
	(left, top, right, bottom : integer; cf : real);
begin
		(* initialize conversion factor *)
	convertFactor := cf;
	link := nil;
	
		(* set up region for wall *)
	SetRect (region, left, top, right, bottom);
end;
Intro OOP, Chapter 6, Slide 5