OS - WindowsXX
This is my very first game _ very similar to the well known game 'Stratego':
http://www.geocities.com/c_pruell/MecnelsTactics.zip
I added a short description of the game to...
Type: Posts; User: Mecnels
OS - WindowsXX
This is my very first game _ very similar to the well known game 'Stratego':
http://www.geocities.com/c_pruell/MecnelsTactics.zip
I added a short description of the game to...
class A{}
class B{
A obj1; // class B contains an object of the class A
public:
void GetAddressForA (A*&xxx); // ('a reference on a pointer to
// objects of the class A' - Is a parameter...
ooops forgot to mention you need to press 'E' at any time to immediately stop it. sorry.
Thx to you all, I've found a good resource due to your help.
:cool:
This is my prog's code:
http://www.geocities.com/c_pruell/twoyearsago.txt
And this is the program, to some extent I'm satisfied with this simple 'game':...
the part after
int result;
could be written like this:
do{
cin >> number;
result=search(id_nums,18,number);
if(result==-1)
Some here will tell you using graphics and sound is sooo difficult, and they will tell you to learn the basics of C++ before even thinking of graphics. Don't believe them! It is not sooo difficult....
You must declare friends inside the fraction class, think you are the compiler and get to this line
friend fraction operator+(fraction first,fraction second);
The compiler can't decide who's...
Please excuse me if I offended you. I didn't want this.
But separating abstract classes and virtual functions is though impossible.
Oh. I was interested in how long (hours) would it take you to do this:
// A Fullscreen DirectDraw Surface, black (maybe 800x600)
// At the center of the screen stationary: The Sun (make a...
to you: hundreds of virtual declarations cause hundreds of 4-byte-of-memory-consuming Virtual Function Pointers, if you have heard of them. (Don't do this, especially if the virtual functions in the...
Hi.
As I am an amateur programmer, my attitude to programming is 'sportsmanlike', as other people like the challenge of a tennis match or beating the world record in non-stop singing. Do you know of...
If you have been programming in C++ for a while and know the basics (What is a pointer? What is a function? What does the operator 'new' do? What is a class?) it is a good idea to start windows...
// don't write hundreds of virtual function declarations into your
// abstract base class, try this:
template <typename T> StandardReturnValue Fn ( T ){
}
// this is usually my first thought...
This really helped me out of my misery.
Abstract classes support ,human way of thinking'; example: say your sister is in the kitchen, and you are somewhere else in the house (maybe programming an abstract class). If your sister tells you...
Operators like + or / should be friends of your fraction class.
The easiest example where + as a member function fails is an expression like 7+somefraction. "7" can't be treated as a fraction...
As I learned at the ,MSDN library' one can send a WM_SETFONT message to a Static control. My problem: There are dozens of pages dealing with fonts there, and I don't intend to create a font. I would...
So I used a dialog box resource editor to create a template resource for my win32 application. I wrote this code:
#include<windows.h>
#include "resource.h" // defines DD_FORMVIEW
LRESULT...
When clicking the Menuitem "New" on my IDE, I can choose to create a new Resource File or a new Resource Script.
I have heard one can create Menu Resources this way, and the name of the resource can...
How many bytes of Videomemory does a 800x600x16bit surface need ?
Imagine you have to write a program which fulfills this task:
Example for input:
(1,3,5) + s x (1,-1,-4) + t x (4, 3, 7) (A plain given in this form)
The result presented by the program should be...
So I got an Apache Web Server, installed it on my PC, and, though I've got a dynamically changing IP-address, my folder htdocs is accessible from the internet (what I see is an index.html page). I...
How to calculate the amount of videomemory a 800x600 16-bit surface uses?
Also, if a game runs with 50 frames (screen updates) per second: Would you say this is fast or slow? How many different...
I've heard of char and LPSTR. What is name*=""? Besides, default-parametres must be assigned from right to left, I think.