Converting C code to C++
On page 35 of Andre''s Book Tricks of the Windows Game Programming Gurus, I would like to convert the Freakout.cpp code to C++ with actual classes and so forth because I prefer to work in C++. I know this has been done by someone, so can anyone offer me some suggestions to convert this to C++.
Thanks
....I am Perseus heir to the throne of Argos
...for over a thousand years the Jedi Knights have been the guardians of peace and justice..before the dark times..before the Empire
Casper..
...for over a thousand years the Jedi Knights have been the guardians of peace and justice..before the dark times..before the EmpireCasper..
I have never had the honor of reading that one of Andre''s books, but if you are interested in compiling it, it should work as is with a C++ compiler. As far as conversion, do you mean the engine (if there is one, remember I am working somewhat in the dark) or just the "meat" of the program? Back when I tried to convert the WGPDUMB engine to C++ classes, etc. I found that Andre has the annoying habit of making many more globals than necessary. I would put related functions and the globals that they use in one class, so you need less parameters for the functions (the globals are right on hand, so you don''t need to pass lpddsback to EVERY SINGLE FUNCTION! That really bothered me. But I must say, apart from its relative slowness, WGPDUMB is quite a nice engine. I hope my rambling has helped you at least a little bit.
--------------------
You are not a real programmer until you end all your sentences with semicolons;
--------------------
You are not a real programmer until you end all your sentences with semicolons;
Visit the ROAD Programming Website for more programming help.
--------------------
You are not a real programmer until you end all your sentences with semicolons; (c) 2000 ROAD Programming
You are unique. Just like everybody else.
"Mechanical engineers design weapons; civil engineers design targets."
"Sensitivity is adjustable, so you can set it to detect elephants and other small creatures." -- Product Description for a vibration sensor
You are not a real programmer until you end all your sentences with semicolons; (c) 2000 ROAD Programming
You are unique. Just like everybody else.
"Mechanical engineers design weapons; civil engineers design targets."
"Sensitivity is adjustable, so you can set it to detect elephants and other small creatures." -- Product Description for a vibration sensor
Thanks Yanroy. Yeah I mean just the meat of the program. I''ll follow your advice and see what happens.
Thanks
...for over a thousand years the Jedi Knights have been the guardians of peace and justice..before the dark times..before the Empire
Casper..
Thanks
...for over a thousand years the Jedi Knights have been the guardians of peace and justice..before the dark times..before the Empire
Casper..
...for over a thousand years the Jedi Knights have been the guardians of peace and justice..before the dark times..before the EmpireCasper..
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement