Solved

Visual C++ and games:  MFC or not?

Posted on 2000-03-17
10
453 Views
Last Modified: 2013-12-04
  Here's a simple one here for any game programmers out there. I'm learning Visual C++ (6.0) and after a couple months of going through books on programming, I'm going to try to whip up a simple game to apply what I've learned to something I'm actually interested in.  
   My question is, when I create a new application, should I use a MFC application or a start a non-MFC Win32 application?  
    I'm leaning towards non-MFC because MFC seems to add a lot of things I don't want, like that grey toolbar at the top when I'd rather add my own interface, and I don't quite understand much of what a generic MFC application starts me with, so it's easier to decide where to start with an empty one.  However, I'm not sure where to begin anyways, so I may as well start with the right application type.  Any advice?
-Delion
0
Comment
Question by:Delion
  • 4
  • 3
  • 3
10 Comments
 
LVL 5

Expert Comment

by:knowlton
ID: 2629820
First of all, what genre of game will you be developing?  Will it be an FPS or something else?

I just finished writing a very simple game in MFC.  I can send it to you if you want.  Just e-mail me at knowltonfamily@yahoo.com.  I will send you the game and source code.

My understanding is that the MFC part is just a wrapper for the API calls that are made in the end anyway.

If you want to have a easy to program Windows interface to your game, you'll probably want to use MFC.

If that is not important to you, then i would use straight Win32 API calls.

I understand that Quake III Arena was written in Visual C++ 6.0...I think in just straight Win32 no MFC.  So, it is a valid programming environment for games, definitely.

Good luck,

Tom
0
 
LVL 5

Expert Comment

by:knowlton
ID: 2629829
Also, most of your intense graphics work will be done in DirectX or OpenGL.
0
 
LVL 4

Accepted Solution

by:
nils pipenbrinck earned 25 total points
ID: 2630011
We use visual C++ 6.0 without any mfc at all.. the window api stuff is well... not more than ca. 100 lines of code. There is really no need to use mfc, since we just open a window to make directX happy (it won't run without a window.. even if you are in fullscreen mode).

Then we switch to DirectDraw fullscreen mode and stay in it until the user quits the game.

Since mfc does nothing to make your live with directx or opengl easier there is really no reason to waste the memory with tons of mfc classes lying around without beeing used.

we've used this approach in two commercial games, and I'm pretty sure the percentence of games using mfc is below .. Hm.. 10%?

btw.. it might be a good idea to use mfc if you're not going into fullscreen mode.. card games and solitair style puzzle games are a different thing.

Nils
0
 

Author Comment

by:Delion
ID: 2630061
 Thanks for the responses- Knowl, right now I'm trying to just get something simple working, so it'll be simple bitmaps displayed or something else easy.  However, I'll want to go towards 3d engines eventually (heh- it'll be a while, probably).  Anyway, I know nothing about DirectX or OpenGL, so I'll go research them for a bit.  Thanks to both of you for the help :)
-Delor
0
 
LVL 4

Expert Comment

by:nils pipenbrinck
ID: 2630110
if you have problems with directx (maybe you're looking for a !simple! example code that opens a window, switches into fullscreen and draws some pixels) let us know..

I have tons of such stuff here..

Nils
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 5

Expert Comment

by:knowlton
ID: 2630116
nils:

What games have you written, and for what company?

At some point I would like to get into game development and would curious to learn more about it.

Thanks,

Tom
0
 

Author Comment

by:Delion
ID: 2631930
  Heh- thanks, nils.  I'll be sure to e-mail you for that simple program if I can't figure it out in a day or two.
-Delor
0
 

Author Comment

by:Delion
ID: 2634022
  Hmmm- Nils, could cou sent me the simple program?  It'd be a great place for me to start.  My e-mail is jdmoyer@earthlink.net
-Delion
0
 
LVL 4

Expert Comment

by:nils pipenbrinck
ID: 2634052
Hi knowlton..

Well, I worked on the game Killer-Loop (a futuristic racing game released last december) on PC and playstation. I also did a small ski jumping game which was only published here in germany. (a 3 month project.. a very shitty game, but it sold very good).

Currently we're doing a port of killerloop for the dreamcast console. it'll be released under a new name which I don't know at the moment..

Delion:

I'll send you a small VC 6 project if you give me your email :)



Nils
0
 

Author Comment

by:Delion
ID: 2634364
My e-mail is jdmoyer@earthlink.net
Thanks!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: ErwindeVries
Released on the 7th of September this real time strategy game sets a new bar for any real time strategy game. R.U.S.E. is a game made by Eugen Systems and published by Ubisoft and released for the PC, Playstation 3 and the Xbox 360. The setting o…
As game developers, we quickly learn that Artificial Intelligence (AI) doesn’t need to be so tough.  To reference Space Ghost: “Moltar, I have a giant brain that is able to reduce any complex machine into a simple yes or no answer. (http://www.youtu…
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now