Jump to content
  • Advertisement
Sign in to follow this  
  • entries
    686
  • comments
    1952
  • views
    387956

Objects for dummies

Sign in to follow this  
Stompy9999

201 views

Well, I'm going to recode the engine for Stompy this weekend. Here is a screenie of the origional one:



The origional used pure C code and was a mess of procedural code. This time I'm using some OOP to handle all of my game objects. All game objects will be inherited from a single abstract base class with this prototype:


class CObject
{

public:

SObject m_Sdata;

virtual CObject();
virtual ~CObject();

virtual void m_Handle() = 0;
virtual void m_Draw() = 0;

};





This my first time using classes in my game so we'll see how it goes...
Sign in to follow this  


0 Comments


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!