Click here to Skip to main content
15,892,674 members
Articles / Multimedia / DirectX

Invasion - A computer game using DirectDraw

Rate me:
Please Sign up or sign in to vote.
4.92/5 (30 votes)
4 Jun 20022 min read 380.6K   7.6K   76  
This "Space Invaders"-like game was originally writen in DirectX 6, but I've changed some things so that you can use it with the latest version of the DirecX SDK. It uses just the Windows API and DirectX library (no MFC here). Have fun!
  • invasion_src.zip
    • ALPHA.BMP
    • backdrop2.bmp
    • BASETSD.H
    • Blaster.wav
    • Blub.wav
    • Ddutil.cpp
    • Ddutil.h
    • DSUTIL.H
    • Dsutil.hpp
    • Explosion.BMP
    • explosion.wav
    • Explosion2.bmp
    • Explosion3.bmp
    • EXTRAS.BMP
    • GameOver.wav
    • GETEXTRA.WAV
    • icon1.ico
    • INVASION.BMP
    • Invasion.dsp
    • Invasion.dsw
    • RESOURCE.H
    • resource.rc
    • SELECT.BMP
    • Ship.bmp
    • ShipExplode.BMP
    • SHOOT.BMP
    • SHOOT2.BMP
    • SHOOTUFO.BMP
    • SKID.WAV
    • STATUS.BMP
    • Tap.wav
    • Ufo.bmp
    • Ufo.hpp
    • Ufo2.bmp
    • Ufo3.BMP
    • UFOSHOOT.WAV
    • Winmain.cpp
  • invasion_demo.zip
    • Invasion.exe
//Microsoft Developer Studio generated resource script.
//
#include "resource.h"

#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"

/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS

/////////////////////////////////////////////////////////////////////////////
// Portuguese (Brazil) resources

#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_PTB)
#ifdef _WIN32
LANGUAGE LANG_PORTUGUESE, SUBLANG_PORTUGUESE_BRAZILIAN
#pragma code_page(1252)
#endif //_WIN32

/////////////////////////////////////////////////////////////////////////////
//
// Bitmap
//

IDB_UFO                 BITMAP  DISCARDABLE     "Ufo.bmp"
IDB_FUNDO               BITMAP  DISCARDABLE     "backdrop2.bmp"
IDB_SHIP                BITMAP  DISCARDABLE     "Ship.BMP"
IDB_SHOOT               BITMAP  DISCARDABLE     "shoot.BMP"
IDB_BOOM                BITMAP  DISCARDABLE     "Explosion.BMP"
IDB_UFOSHOOT            BITMAP  DISCARDABLE     "shootufo.BMP"
IDB_INVASION            BITMAP  DISCARDABLE     "invasion.bmp"
IDB_SHIPEXPLODE         BITMAP  DISCARDABLE     "ShipExplode.BMP"
IDB_ALPHA               BITMAP  DISCARDABLE     "ALPHA.bmp"
IDB_SELECT              BITMAP  DISCARDABLE     "select.bmp"
IDB_STATUSBAR           BITMAP  DISCARDABLE     "status.bmp"
IDB_EXTRA               BITMAP  DISCARDABLE     "extras.bmp"
IDB_SHOOT2              BITMAP  DISCARDABLE     "shoot2.bmp"
IDB_UFO2                BITMAP  DISCARDABLE     "Ufo2.bmp"
IDB_BOOM2               BITMAP  DISCARDABLE     "Explosion2.bmp"
IDB_UFO3                BITMAP  DISCARDABLE     "Ufo3.BMP"
IDB_BOOM3               BITMAP  DISCARDABLE     "Explosion3.bmp"

#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//

1 TEXTINCLUDE DISCARDABLE 
BEGIN
    "resource.h\0"
END

2 TEXTINCLUDE DISCARDABLE 
BEGIN
    "#include ""afxres.h""\r\n"
    "\0"
END

3 TEXTINCLUDE DISCARDABLE 
BEGIN
    "\r\n"
    "\0"
END

#endif    // APSTUDIO_INVOKED


/////////////////////////////////////////////////////////////////////////////
//
// Icon
//

// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDI_UFO                 ICON    DISCARDABLE     "icon1.ico"

/////////////////////////////////////////////////////////////////////////////
//
// WAV
//

STOP                    WAV     DISCARDABLE     "skid.wav"
SHOOT                   WAV     DISCARDABLE     "Blaster.wav"
BOOM                    WAV     DISCARDABLE     "Explosion.wav"
UFOSHOOT                WAV     DISCARDABLE     "ufoshoot.wav"
ENTER                   WAV     DISCARDABLE     "Blub.wav"
SELECT                  WAV     DISCARDABLE     "Tap.wav"
GETEXTRA                WAV     DISCARDABLE     "getextra.wav"
GAMEOVER                WAV     DISCARDABLE     "GameOver.wav"
#endif    // Portuguese (Brazil) resources
/////////////////////////////////////////////////////////////////////////////



#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//


/////////////////////////////////////////////////////////////////////////////
#endif    // not APSTUDIO_INVOKED

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Web Developer
Brazil Brazil
Mauricio Ritter lives in Brazil, in the city of Porto Alegre. He is working with software development for about 8 years, and most of his work was done at a bank, within a home and office banking system.
Mauricio also holds MCSD, MCSE, MCDBA, MCAD and MCT Microsoft certifications and work as a trainer/consultant in some MS CTEC in his city.
Mauricio also works in his own programming site, aimed to Brazilian Developers: http://www.dotnetmaniacs.com.br

In his spare time he studys korean language...

Comments and Discussions