Public Group

# making a title page

This topic is 5205 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

ok i finaly got my first windows game (pong) up and running and im really excited (hey we all had to start some were) and now im trying to make it so that you cna choose your back ground and so i need it to text out which background do you want 1,2 or 3 but i cant seem to get it too work and the game wont pause right. basicly i want an intruductory page (kinda like the title page to a book almost every game has one anyway if any one knows a good way to do this let me know THX :)

##### Share on other sites
Are you using the GDI for graphics, DirectDraw, or Direct3D?

If you're using DirectDraw, before you blt() or bltfast() the secondary surface to the primary surface, you need to use lpDDSSecondary->GetDC(hWnd, &hDC); (might not be the correct arguments - it's been a while) and then after using TextOut(), etc use lpDDSSecondary->ReleaseDC(&hDC);

##### Share on other sites
In WM_PAINT do a switch on game state

case WM_PAINT:    switch(uGameState)    {        case GAMESTATE_MENU:            // Draw Menu            break;        case GAMESTATE_GAME:            // Render game            break    }    break;

##### Share on other sites
ok cool thx umm one more question is there some kind of other library i have to include (i have all the main ones) in order to play .wav sounds
#include <windows.h>
#include "Resource.h"
#include "GameEngine.h"
#include "Bitmap.h"
#include <windows.h> // include all the windows headers
#include <windowsx.h> // include useful macros
#include <stdio.h>
#include <math.h>
#include <string.h>
#include <WINGDI.h>

yes, winmm.lib

1. 1
2. 2
3. 3
Rutin
15
4. 4
5. 5

• 13
• 26
• 10
• 11
• 9
• ### Forum Statistics

• Total Topics
633726
• Total Posts
3013571
×