Solved

MS VC++ 6.0 and the C library

Posted on 1998-12-23
6
215 Views
Last Modified: 2010-04-16
Hey all!

I'm reading "Tricks of the Game Programming Gurus" and
I can't get the key.c in chapter 3 to compile.

I'm missing the "bios.h" file.
Is this file not included with VC++ anymore?

What should I do?

Thanks,
Big Badger
0
Comment
Question by:BigBadger
  • 4
  • 2
6 Comments
 
LVL 86

Accepted Solution

by:
jkr earned 100 total points
ID: 1180961
The answer is as cruel as it is simple: You need a 16bit compiler, as the functions included in 'bios.h' arent supported on 32bit platforms, and as VC6 can't produce 16bit executables, the file has been removed...
0
 
LVL 86

Expert Comment

by:jkr
ID: 1180962
Ooops - well, you could of course also try to replace the functions from 'bios.h' with 32bit equivalents, but this is not simple - and as there are not necessarily 32bit equivalents of all functions, you might have to re-write the code completely...
0
 

Author Comment

by:BigBadger
ID: 1180963
Hey jkr,

Thanks for answering.
It seems like there is always another obstacle
in my way.  I'm trying to learn game programming
and this is the 4th book I've bought.  The friggin
code will never compile.

Is there still a 16 bit C compiler with inline assembler available?  
Do you know where I could find 32 bit versions
of these C functions?

How should I proceed from here?

Thanks
Big Badger
0
3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

 
LVL 86

Expert Comment

by:jkr
ID: 1180964
Well, a good choice would be the GNU C compiler, as it is free ;-)
As you were talking about game programming, i assume you want to directly use the video capabilities of the system, so 16bit DOS would eventually be the best choice (at least for the moment - think of DOS extenders like dos4gw or the one that comes with GNU C)
About the 32bit conversion: It'll be difficult - the direct disk I/O routines as well as the COM routines have been superseded by a totally different (and incompatible) programming model. The same problem occurs with almost all functions - most of the information is still available, but through a very different set of Win32 APIs...
0
 

Author Comment

by:BigBadger
ID: 1180965
Thanks jkr!
I'll look on the web for the GNU C compiler.

Big Badger
0
 
LVL 86

Expert Comment

by:jkr
ID: 1180966
If you encounter problems using it, feel free to ask ... ( i like it ;-)
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

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

Article by: SunnyDark
This article's goal is to present you with an easy to use XML wrapper for C++ and also present some interesting techniques that you might use with MS C++. The reason I built this class is to ease the pain of using XML files with C++, since there is…
Many modern programming languages support the concept of a property -- a class member that combines characteristics of both a data member and a method.  These are sometimes called "smart fields" because you can add logic that is applied automaticall…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

810 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