views:

8

answers:

0

Hey i need some general advice on how to structure my project. i am trying to make a simple strategygame where some object move around in a "worldspace" and youve got several different tactical views, which show diffent areas of the game. nothing special. but since i'm a rather unexperienced programmer, some things are not quiet clear to me.

I managed to get the model almost working but now i am thinking of the best way to connect my model the my views. The views are Subclasses of Cocos Layers. Since im just starting id like to keep it as simple as possible, as long as it doesnt break the performance. ive read some things about MVC and key-value-coding and observing, but im having problems to take it to use. Neither am i sure if its the right way to go for a game. so i'd be realy glad if someone could point me into the right direction and maybe give a little example how to do things like this. i have the following scenario:

there is a model with objects for everthing could be in a view. A CCLayer-subclass has some standard sprites for this view (with some properties which need to be updated from the model every step) and a variable number of enemys which can enter or leave the view while the view is active. the view has some callbacks for special effects which can be called from the model (controller) And there is the controller to connect both. and the way the controller does that is my problem.

i hope some understands my problem, as you may have noticed im having some problems pointing it out exactly. so if you need further information, pls ask. thanks a lot