baldurk said:
I like C
#21
Posted 28 July 2003 - 12:11 PM
#22
Posted 28 July 2003 - 12:30 PM
When he was asked, why he has done that, he said, that he wants to code OO... :lol:
-----
"Human stupidity is something you can rely on." -- M.A.
"I didn't design life." -- J.G.
"It's almost finished..." -- EHD
#23
Posted 28 July 2003 - 12:42 PM
btw.. you know why they're called "good coding practises"?
because they help you to make the compiler detect your own errors when you forget them. because they help you to make your system not crash just because you made a logic error in your program. etc.
and mainly because they help saving repetitive typing.
-Loving a Person is having the wish to see this Person happy, no matter what that means to yourself.
-No matter what it means to myself....
#24
Posted 28 July 2003 - 10:22 PM
Certainly, good programming practices helps a lot, but excesively good practices can make a clear sky become a storm day. Like Bjorn said: In C is easy to shot yourself in the foot. C++ makes it harder, but when you do it, you blow your whole leg.
#25
Posted 30 July 2003 - 06:07 AM
as for the quote you can find his explenation here
also keep in mind that C++ isn't an OOP languate it's multiparadigm
hope that clearifies things a bit.
#26
Posted 30 July 2003 - 06:22 AM
as always first: if its the only option (except for example asm) on a platform, use it (or the asm, if it fits your needs bether:D)..
what ever fits your needs
on every platform where there is a c++ compiler available (and thats about all the big ones today..), there is NO need to use C anymore.
the C language got a bit cleaned up in c++ (no stupid typedef struct _name {} name, and similar), and got a lot of additional features, the c++ part namely.
the C programming paradigms are still useful. functions, procedural programming. that all fits well into the c++ world as well.
but there is NO need to use straight C anymore. today c++ is "in", too, so you get much bether support and much faster c++ compilers, too :D
-Loving a Person is having the wish to see this Person happy, no matter what that means to yourself.
-No matter what it means to myself....
#27
Posted 30 July 2003 - 07:06 AM
#28
Posted 30 July 2003 - 08:17 AM
-Loving a Person is having the wish to see this Person happy, no matter what that means to yourself.
-No matter what it means to myself....
#29
Posted 19 August 2003 - 03:19 AM
I think C++ is like an addon to C. It just improves the features available in C.
I love C++ since it sounds a bit crazier then C.
I think lots of people use C++ :yes: .
As a matter of fact, :rolleyes: I think C++ is the standard language for game programming.
The Lion King</span>
#30
Posted 20 November 2003 - 11:59 PM
0100
0010
0001
#31
Posted 21 November 2003 - 03:59 AM
I find that it is far easier to produce cleaner code in cpp than in c.
as for teh speed issue- I really don't think it matters anymore. Unless you are *really* good you can't make sure that you put in all the features you want and also take care of OOPing your code and deliver on the same deadline using C. (but that could only be my opinion though...)
(in very simple words, my vote is for cpp)
#32
Posted 21 November 2003 - 04:01 AM
starboarder2001 said:
I think C# would be perfect for programming tools to use in your game. And the performance hit when using managed DirectX is not really that significant. It's supposed to be just a 5% performance hit at worst on average.
I say go for it. C# is great to work with, slick and clean.
- Me blog
#33
Posted 21 November 2003 - 09:18 AM
#34
Posted 22 November 2003 - 01:20 AM
and then again. why do all always first ask "is it fast?" if they compare languages? a language can not be fast. the produced code can. and it could be fast, or slow, for any language. it doesn't mather.
-Loving a Person is having the wish to see this Person happy, no matter what that means to yourself.
-No matter what it means to myself....
#35
Posted 22 November 2003 - 10:33 AM
davepermen said:
and then again. why do all always first ask "is it fast?" if they compare languages? a language can not be fast. the produced code can. and it could be fast, or slow, for any language. it doesn't mather.
#36
Posted 22 November 2003 - 02:12 PM
you run in debugmode if you have those issues. C is NOT faster at all than c++, because all C can can be done in c++ EQUALLY. just rename your file from .C to .CPP and you can compile it again, and the compiler will spit out the 100% exact same asm again.
and speed is never the main most important thing. its the LAST thing.
-Loving a Person is having the wish to see this Person happy, no matter what that means to yourself.
-No matter what it means to myself....
#38
Posted 23 November 2003 - 09:34 AM
Nope they do it because it's faster.
Just because you can't use the language right doesn't mean it's slow.
Sure there are features in C++ that cost clock cycles but if that is a big concern then simply don't use them.
Equvivalent C and C++ code will be just as fast the C++ code being a bit more readable. You're simply talking out of your ass with really nothing that argues your point. You simply can't compare printf to cout and classes with virtual functions to calling a staticly bound function you'll have to simulate them in C to get a fair comparison. Heck calling member functions is SLOWER in C than in C++ because the C++ got native support for it. In MSVC++ this translates to that in C you have to manually push a pointer to the struct you're working on onto the stack wheras in C++ the same pointer is stored in a register.
Please grow up do some real research (no asking you'r 1337 h4x0r friends doesn't count)
#39
Posted 23 November 2003 - 02:40 PM
baldurk : nope... g++ is gcc. it's the same compiler :) g++ is just calling gcc with a few extra parameters.
oh boy i thought that this kind of discussion died out years ago. are we really still in the stone ages ? sure the whole industry codes in c++. of course they do that because it is slower and inferior to c.
i'm down with the casual inline assembly but i'm not going to make a fire using a flint when i have a lighter in my pocket ;)
#40
Posted 23 November 2003 - 03:16 PM
anubis said:
The key to writing efficent code in any language is understanding the underlying thoughts and design decisions built into the language. And that is simpler todo with C because it's basicly a highl level assembler (and that's actually one of its design goals) C++ is designed in quite a diffrent way and people not using it the right way end shooting themself in the foot constantly blame the language without even trying to understand how things work.
C++ is not a simple language but it's every bit as flexible and efficent as C.
Sometimes I actually wonder it it wouldn't have been better if the legacy from C hadn't been as strong :/ the language wouldn't been as widespread but maybe just maybe people that don't care about actually learning a new language wouldn't have migrated and then claimed C++ to be C with classes...
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users












