Using components in the XNA Game State Management example?
- by Zolomon
In the game state management example at the App Hub, they say that if you want to use components in the example you can extend the GameScreen to host other components inside itself.
I'm having a very hard time trying to tie this up.
I tried extending the GameScreen class by adding a public property of public List<DrawableGameCompnent> components { get; set; } and then add my components to that list when I initialize the current screen as well as looping over the components in the LoadContent, Update and Draw methods. However, this doesn't feel like the correct way to go - mainly because it doesn't work when I get to the implementation of my GameplayScreen.
Any thoughts?