Jump to content
  • Advertisement
Sign in to follow this  
Brownie

Huge Noob Question about C#

This topic is 4092 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Ok well I am starting to use Microsoft Visual C# and im following this tutorial http://blogs.msdn.com/coding4fun/archive/2006/11/02/938703.aspx at one point it says: * In the GameEngine class add the following code after the constructor. protected override void OnPaint(PaintEventArgs e) { } ok what I don't understand is what a constructor is can anyone help me? [Edited by - Brownie on May 3, 2007 7:19:00 PM]

Share this post


Link to post
Share on other sites
Advertisement
A constructor is a method within a type (we'll call the type T) that is called when an instance of that type (T) is created.

For some languages the constructor has the same name as the type that it is associated with. For instance, in your case the constructor would be called GameEngine.

It should be noted that these tutorials assume a basic understanding of the language, something you should obtain before attempting to use them.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

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

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!