|
|
published 7 months, 27 days ago, submitted by
ElementCy
7 months, 27 days ago
johnnygizmo.blogspot.com — JohnyGizmo thought he would talk about a pretty cool class in XNA called GameComponent and its child Class DrawableGameComponent. These classes are made to add components to your game in a modular way. A component is something that needs to update with your game. DrawableGameComponent inherits GameComponent and adds functionality so that the component is also drawn at proper times as well. You could actually re-design our GameObject class as a DrawableGameComponent or at least inherit a class from DrawableGameComponent to give us the added functionality. Now from his reading, it seems that a lot of people think GameComponents are are really aimed at single game objects like a tank, but to add a TankManager class that would deal with the updating and drawing of all the tank objects in our game. But it certainly doesn't hurt to learn the type in an easy way.
|
|
tags:
XNA | tag it
Everyones tags: | Your tags: | |
|
|
|
Add a live kick counter to your blog >>
You can even customize the image by choosing your own colors, and then clicking
the button below to update the preview and the html code:
Simply copy and paste this HTML into your blog post.
Users who kicked this story:
No comments so far
|