Upcoming Events
Unite 2010
11/10 - 11/12 @ Montréal, Canada

GDC China
12/5 - 12/7 @ Shanghai, China

Asia Game Show 2010
12/24 - 12/27  

GDC 2011
2/28 - 3/4 @ San Francisco, CA

More events...
Quick Stats
89 people currently visiting GDNet.
2406 articles in the reference section.

Help us fight cancer!
Join SETI Team GDNet!
Link to us Events 4 Gamers
Intel sponsors gamedev.net search:


  Contents

 Where Did We
 Leave Off?

 Next Piece Please
 I Can't See It!
 The New Text
 Wanna See This
 Too?

 Scoring and Levels
 Until Next Time

 Printable version
 Source & Demo

 


  The Series

 Part 1
 Part 2
 Part 3
 Part 4
 Part 5
 Part 6

 

Wanna See This Too?

I suppose now would be the time to show you the code for drawing our captions on the screen. I simply added a new function to our shapes module. Here it is ...

Popup : Draw_Captions Procedure

I have tried to keep it in the same form as the rest of what I've shown you. The code reads from a few module variables to get the current numbers to draw. It then makes a call to set the font how we want. This isn't anything new I hope. We then set our rectangle for the drawing and make the call. If you don't remember wvsprintfA() is a function that is used for formatting a string buffer ... almost exactly like sprintf().

The other thing I am doing is setting the color we will use. I don't know about you but I prefer to make things a little bit varied and stand-out-ish ( <-- Is that even a word???).

In short, this routine just calls upon a few library routines and pieces things together as needed. I can't remember if I have told you guys, or not ... but programming is like one big jigsaw puzzle. It is just a matter of finding the right pieces and putting them together correctly. There is no one right way to do it and that is why everybody creates different pictures. Make sense?




Next : Scoring and Levels