speed battle: structs and classes

Started by
0 comments, last by Iron Eye 21 years, 5 months ago
I''m making a simple console game, and I noticed when I was making a monster class that I could easily do away with all the functions in it, so, as far as I can see there''d be no difference between using a class to store all the monster info, or a structure, although using a structure did seem easier. As I''m nearing completetion I''ve become concerned for speed differences. I tried to use the code off cpp-home.com that they use to take the clock cycles of contest submissions, but I can''t get it to compile in Dec C++. Any input is welcome. -Iron Eye
Cyrus Eye design
---
ConPong _//_ Google _//_ Chaos Forge - quick and easy file hosting for developers

"Games usually keep me from making my own..."
-Me
---



find your elementat mutedfaith.com.
Advertisement
There is no speed difference between the C++ class and struct constructs. They are almost identical in semantics as well.
- The trade-off between price and quality does not exist in Japan. Rather, the idea that high quality brings on cost reduction is widely accepted.-- Tajima & Matsubara

This topic is closed to new replies.

Advertisement