Recently I’ve start develop a Flash Game. While I was designing the classes via UML, none problems I’ve found.
Now, applying to Flash, I’ve get so much confused =/
By the logic, I get that far:
Game > Game class characters/ICharacter.as > Interface characters/*.as > Characters Classes terrain/Map.as > Map Class** The problem: The Game class has 2 properties: **private var player:ICharacter; private var terrain:Map;** Now, if I have to check if player is hitting the terrain, when creating the **new Player()**, I have to pass the **terrain** property as parameter, and hold that property in Player class (Character). I dont think that is correct... By convention, we should only extend a class if the **subclass if a type of super**, and create property if the **super has a type of subclass**. This is what im doing. **Game has a Player, and has a Terrain** So, im suppose to keep this Class Design? Or I must rethink on it? Thanks in advance. :drool: