Delegation question
Delegation question
- Subject: Delegation question
- From: email@hidden
- Date: Thu, 27 Sep 2001 08:37:45 -0400
Hi,
I'm trying to create a map editor for a war strategy game. I have a
MapView class that displays the map and a Controller class that reads
input from the GUI.
I have a palette that lets you pick the type of hex you want to place on
the map.
What I don't understand is how to get the paletteHex data from the
Controller class to the MapView class. To pass from one to the other I
would have to instantiate one within the other to use an instance
method. I don't think I would want more than one instance of either of
these two.
Would I want to use a class method? Or is this what
delegation/notification is for? Can anyone recommend the proper/best way
to get this information from one to the other? Thanks.
Ken Botwinick