but i dont quite understand this code
Just what is it you don't understand about this code. It is a fairly straight-forward use of classes.
Are you sure that you actually understand what a class is and how to use them?
Ofcourse this code does not have all the code necessary, but that is to prevent you from simply copying my code. For this to work, you will have to implement all the functions.
This post has been edited by Lillefix: 23 August 2009 - 04:23 AM