Render Delegation
© 2000 - Zachary Booth Simpson. Copied with permission from http://www.mine-control.com/zack. If you find any of this work useful, please sign Zack's guest book: http://www.mine-control.com/cgi/gbook-zbs.cgi. IntentPass-off special render cases to Model code. ProblemGeneric View code often becomes clotted with special cases, especially near the end of a project. Render Delegation gets the special cases out of the View code and into Model subclasses. SolutionAn example clot in View code:if (typeToDraw==DARTH_VADERS_SHIP) drawSpecialShieldEffect(); StructureNot available at this time. ExamplesNo examples at this time. Email kevin@gamedev.net to contribute. Issues and RisksUse Render Delegation when: Related PatternsRender Delegation passes draw commands from View to Model. Discuss this article in the forums
See Also: © 1999-2011 Gamedev.net. All rights reserved. Terms of Use Privacy Policy
|