Challenge: Create a New Unit Test Track


This chapter handled a lot of complex issues and you are probably as exhausted reading this as I am writing it, so I want to give you an easy task this time. Go into the TrackLine class and add a new unit test for a simple track. You just have to add a bunch of vectors and test them until you think the track looks good enough.

Figure 12-22 shows an example of such a custom track. Please note that I inverted the screenshot to be better visible in this book. You could also use an invert post-screen shader as described in Chapter 8.

image from book
Figure 12-22

If you have some energy left, try to import a track from 3D Studio Max through the TrackImporter class and then test it in the Track or Landscape class. Anyway, enjoy the landscape and track rendering code. Hopefully it is also useful for other game projects.




Professional XNA Game Programming
Professional XNA Programming: Building Games for Xbox 360 and Windows with XNA Game Studio 2.0
ISBN: 0470261285
EAN: 2147483647
Year: 2007
Pages: 138

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net