Important alert: (current site time 7/15/2013 4:48:36 PM EDT)
 

winzip icon

A Flight Simulator - direct X, real flying! COOL !!!

Email
Submitted on: 7/4/2000 2:21:01 AM
By: Keir Gordon 
Level: Advanced
User Rating: By 58 Users
Compatibility: C++ (general), Microsoft Visual C++
Views: 64945
(About the author)
 
     This is a flight simulator game made with direct X, its great, this can teach you to use directX in an easy way. You have GOT to check this out. Soon i'll have this ready for selling to the public! Check out this cool code, and vote for me! If you need help, just email me! Visit my Artificial intelligence and C++ channel at: #fuzzylogic on Dalnet

 
winzip iconDownload code

Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. Afterdownloading it, you will need a program like Winzip to decompress it.Virus note:All files are scanned once-a-day by Planet Source Code for viruses, but new viruses come out every day, so no prevention program can catch 100% of them. For your own safety, please:
  1. Re-scan downloaded files using your personal virus checker before using it.
  2. NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.

If you don't have a virus scanner, you can get one at many places on the net including:McAfee.com

 
Terms of Agreement:   
By using this code, you agree to the following terms...   
  1. You may use this code in your own programs (and may compile it into a program and distribute it in compiled format for languages that allow it) freely and with no charge.
  2. You MAY NOT redistribute this code (for example to a web site) without written permission from the original author. Failure to do so is a violation of copyright laws.   
  3. You may link to this code from another website, but ONLY if it is not wrapped in a frame. 
  4. You will abide by any additional copyright restrictions which the author may have placed in the code or code's description.

Report Bad Submission
Use this form to tell us if this entry should be deleted (i.e contains no code, is a virus, etc.).
This submission should be removed because:

Your Vote

What do you think of this code (in the Advanced category)?
(The code with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor (See voting log ...)
 

Other User Comments

7/4/2000 2:24:43 AMKeir Gordon

Hello everyone, I've been working on this code for a while, and i just posted it. Its bug free and runs great, but is quite complex, so i expect people to have alot of questions. Please just email me or leave a posting here, and i'll awnser them.
(If this comment was disrespectful, please report it.)

 
7/4/2000 2:34:50 AMKeir Gordon

One more thing... VOTE FOR ME!!!! THANKS!!
(If this comment was disrespectful, please report it.)

 
7/5/2000 11:20:03 PMCrazy Monk

That was like the sweetest code i've ever seen man. That rocked you easily have my excellent vote. Anyone who votes otherwise is insane.
(If this comment was disrespectful, please report it.)

 
7/6/2000 12:50:17 AMKeir Gordon

Well thanks! If you need any help with it email me
(If this comment was disrespectful, please report it.)

 
7/10/2000 5:00:09 PMlogix

People have been asking me, so i thought i had better tell everyone. The librarys i used came from a book called "3d graphics programming for windows 95" from microsoft.
(If this comment was disrespectful, please report it.)

 
7/13/2000 7:47:26 PMChris Ruesink

This is awesome man!
(If this comment was disrespectful, please report it.)

 
7/20/2000 5:42:22 PMGreg Duerr

It's got my vote!! Great work.
(If this comment was disrespectful, please report it.)

 
7/23/2000 9:57:25 AMVictor Procure

Sweet game man
(If this comment was disrespectful, please report it.)

 
8/14/2000 1:00:43 AMtrix001

this is cool man! u got my vote but can u create a flight simulator in visual basic.
(If this comment was disrespectful, please report it.)

 
8/23/2000 8:41:22 AMMarc Burgess

Hey, I do most (All) my programmig in Visual Basic, and am doing 3D stuff, but doing a flight sim would be pretty hard
(If this comment was disrespectful, please report it.)

 
8/31/2000 10:40:19 PMSTUART

COOL... GOOD FOR US BEGINNING WITH GRAPHICS. MANY THANX!
(If this comment was disrespectful, please report it.)

 
9/3/2000 3:14:20 PMtsi

Awesome work but how do I speed up the propeller's rotation? You get 5 stars from me :-)
(If this comment was disrespectful, please report it.)

 
1/7/2001 7:26:59 PMSteve

Is the ground supposed to move? doesn't move for me. (Awesome code by the way!)
(If this comment was disrespectful, please report it.)

 
6/20/2001 1:31:25 PMJared

Yeah Its having problems on 2K, and its MFC
(If this comment was disrespectful, please report it.)

 
7/13/2001 6:11:47 PMMiah

NOOOO MAN!!! dont use MFC! oh well, thanks for the code anyway!
(If this comment was disrespectful, please report it.)

 
7/23/2001 7:41:26 PMBrat3227

I gave this an average score. Simply because the logic is alright, but the implementation is pretty bad.
(If this comment was disrespectful, please report it.)

 
8/19/2001 12:29:56 PMJason

heh, this is pretty good but, it doesnt go anywhere. all you do is make the plane turn and stuff and when you do nothing changes. no ground point of reference or anything. Dont get me wrong i am impressed as i cant even make a tic tac toe game, but you might want to figure out how to make ground objects move below you. other then that it looks good =)
(If this comment was disrespectful, please report it.)

 
8/20/2001 8:29:41 AMAditya

Great code to work with for a starter like me. Thanks for posting it. But unfortunately I haven't used MFC. Can you give some hints on how to convert the same to Console application and where can I find documentation for 3dplus ? BTW, I have a Win2K.
(If this comment was disrespectful, please report it.)

 
10/4/2001 7:47:08 AMS. Rajagopalan

fatal error C1083: Cannot open include file: '3dPlus.h': No such file or directory How to solve this problem?
(If this comment was disrespectful, please report it.)

 
11/8/2001 1:36:38 PMannie

great work!
(If this comment was disrespectful, please report it.)

 
2/28/2002 12:21:11 AMHead of The Hickware CREW

To the guy that posted the following.....

>10/4/2001 7:47:08 AM:S. Rajagopalan
>fatal error C1083: Cannot open include
>file: '3dPlus.h': No such file or
>directory How to solve this problem?

did you even so much as LOOK in the zip for the file? haha man some ppl..... :)
(If this comment was disrespectful, please report it.)

 
3/23/2002 9:44:54 AMacidkills

nice good, but needs alot of work :) good luck.
(If this comment was disrespectful, please report it.)

 
3/23/2002 9:45:02 AMacidkills

nice good work, but needs alot of work :) good luck.
(If this comment was disrespectful, please report it.)

 
4/14/2002 10:23:42 AMCarlos

Why people still keeping the same structure as the Microsoft samples.
You should check the resources you
are utilizing cuz they dont look to
be part of the program.

Also the keyboard should be driven by
direct input for a faster reaction.

Otherwise the workaround with libraries are not bad but needs a lot of work to look professional.

Anyway you should use directly the DirectX library which is not that complicated. You can find a lot of sample in the SDK from Microsoft, and its free !

Thanks.
(If this comment was disrespectful, please report it.)

 
5/9/2002 1:51:44 AMDeepankar Sinha

Really Cool! you deserve a praise. I wish you could do more of this stuff so thst i can learn ;)
(If this comment was disrespectful, please report it.)

 
5/24/2002 3:23:26 PMBilly

This is awesome good Job but you should make the ground move other than that its awesome
(If this comment was disrespectful, please report it.)

 
5/29/2002 10:31:02 AMMukade

MARVELOUS, BUT TELL ME WHAT U EAT?? ;-/

(If this comment was disrespectful, please report it.)

 
5/31/2002 5:35:08 AMsimon

great code. shame about MFC (Mangled Fractured Code).
(If this comment was disrespectful, please report it.)

 
7/7/2002 12:14:07 PMcJ!

hOW DO I MAKE IT TAKE OFF?????
E-MAIL ME
(If this comment was disrespectful, please report it.)

 
7/9/2002 5:50:59 PMDustin Davis

its a shame that this was taken directly from the direct x SDK!!! WTF is wrong with you?
(If this comment was disrespectful, please report it.)

 
7/9/2002 11:15:26 PMKeir Gordon

I admit this isn't great code, being it was one of my first C++ projects, but it did indeed win the Code of the month award, and is one of the popular codes around here. What makes you think its from the SDK? I used a wrapper around the SDK even, becuase at the time the SDK seemed too complicated. I don't recall seeing anything like this. I did this all by hand during spring break, I doubt microsoft has the flight equations available at all. Well if your going to critisize please explain... becuase this isnt from any SDK. Or at least not one that was around when this code was posted 3 years ago.
(If this comment was disrespectful, please report it.)

 
10/14/2002 2:42:20 PMMonkeys

i am new 2 c++ please tell me which file to open.
(If this comment was disrespectful, please report it.)

 
1/19/2003 2:29:43 PMMike Falcone

open the .dsw file
(If this comment was disrespectful, please report it.)

 
1/19/2003 2:36:51 PMMike Falcone

if u get a fatal error C1083: Cannot open include file: '3dPlus.h': No such file or directory error thing, click tools then options. then click on directories. under show directories for, click include files. then click the new button (by the red x) and set the directory to "3DPLUS\INCLUDE" in the unzipped folder. then click ok and it should work.
(If this comment was disrespectful, please report it.)

 
2/20/2003 12:31:10 AM

ok man , i'm new to c++ and when i try to build this code , i get :
Linking...
LINK : fatal error LNK1104: cannot open file "nafxcw.lib"
Error executing link.exe.

i have been told to go in the project section , settings , and to all configuration , put use MFC in a shared DLL , ok i don'T even know what the hell MFC is , is there a way i could get this code to work , plz i'm using visual C++ 6.0..
later all
(If this comment was disrespectful, please report it.)

 
2/20/2003 6:47:20 AM

Damit..everytime , every source code i get from wherever , i'm always missing a file, then i finaly get to find it on the net , put it in the INCLUDE or whatever link to it , IT NEVER WORKS i never got to make other people 's source code build up or compile, it makes me wanna give up , maybe i'm missing some important information ??!! there is always files i dont have , did i miss a part ??? ARGG plz anybody , im using VC++ 6.0 ... there is ALWAYS a missing file
(If this comment was disrespectful, please report it.)

 
5/4/2003 3:07:10 PM

i had the same problem and mostly on a file called
(If this comment was disrespectful, please report it.)

 
6/26/2003 8:03:56 AM

very good i love this game <
HOOOOOOOOOOOOOO

(If this comment was disrespectful, please report it.)

 
7/14/2003 7:00:51 PMAJ1

I am getting this error after changing
to mfc shared dll: LINK : fatal error LNK1104: cannot open file "nafxcw.lib"
Any ideas why?

Thanks,
AJ1.
(If this comment was disrespectful, please report it.)

 
10/10/2003 7:47:36 PM

I have the same error... cannot open file "nafxcw.lib" any help?
(If this comment was disrespectful, please report it.)

 
12/4/2003 12:45:58 PMHitesh

HI this is really nice
i was looking for this
DO you got some acrticle on this also
nice work
(If this comment was disrespectful, please report it.)

 
3/17/2004 7:30:44 AM

Great Job man. You'll get my vote!!! :-)
(If this comment was disrespectful, please report it.)

 
5/16/2004 3:46:25 AM

very good. exelent work on this one.
(If this comment was disrespectful, please report it.)

 
5/20/2004 8:32:36 AM

great work, very good code indeed.
(If this comment was disrespectful, please report it.)

 
11/18/2004 8:35:19 PM

I have found the reasons of the file
(If this comment was disrespectful, please report it.)

 
11/18/2004 8:39:01 PM

i have found it!
Answer

The reason you get this error is because the library "nafxcw.lib" is found in
the Microsoft Visual C++, and it cannot find it. This is due to your
environment variables for Microsoft Visual C++ not being setup properly, or
you simply don't have this compiler. ADAMS/Controls with EASY5 requires both
the current supported Fortran Compiler *and* the C Compiler. See "Supported
Hardware/OS" at http://support.adams.com for more information on the current
supported/necessary compilers.
-------------------------------
i'm a Chinese student.Welcome to contact with me !
(If this comment was disrespectful, please report it.)

 
1/10/2005 6:05:56 AM

What a hell are u saying, the file is there, but when the linker found it,give me another error: protected: thiscall OnPaint ...alredy found in wincore.obj......what appen, i'm going crazy!!! GREAT WORK anyway.


Some help will be great!
(If this comment was disrespectful, please report it.)

 
6/27/2005 10:04:55 AM

About the
(If this comment was disrespectful, please report it.)

 
6/27/2005 10:07:46 AM

about the "nafxcw.lib" error. It is a setting in your project workspace. In the "Project" menu, select "Settings". The settings dialog will be displayed. In the "General" tab, and "Microsoft Foundation Classes", select "Use MFC in a shared DLL". Then recompile.
(If this comment was disrespectful, please report it.)

 

Add Your Feedback
Your feedback will be posted below and an email sent to the author. Please remember that the author was kind enough to share this with you, so any criticisms must be stated politely, or they will be deleted. (For feedback not related to this particular code, please click here instead.)
 

To post feedback, first please login.