|
-
Jul 13th, 2006, 06:47 PM
#1
Thread Starter
Hyperactive Member
[RESOLVED] Invalid token in class?
I am currently trying to learn c# games programming.
i copied the following code from a book i have bought, and on the marked line it comes up with the error in the title of this thread. Any help as how to sort it?
c# code:
public class MainUiScreen : UiScreen, System.IDisposable
{
private Microsoft.DirectX.Direct3D.Texture buttonTextures = null;
private Microsoft.DirectX.Direct3D.Texture messageTexture = null;
private UiButton newButton = null;
private UiButton exitButton = null;
//events
public event System.EventHandler NewGame;
public event System.EventHandler Quit;
#region IDisposable Members
///<summary>
///clean up in case dispose isn't called
///</summary>
-MainUiScreen() \\it doesn't like the '-' on this line
{
Dispose();
}
///<summary>
///clean up any resources
///</summary>
...
if i remove the '-' it comes up with the error: no overload for method 'uiscreen' takes 0 arguments
please can someone help??
Thanks
GTJ
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|