Handlers and Classes/Interfaces
I currently have a task that I need to have accomplished so that my mod (if you haven't already notice, I do a lot of modding) can continue. I have several instances where i need to set up a handler system (or at least that's what I've heard it being called). Basically I need a system where you can add an option to the game. This requires that the option have a loading function, saving function, etc. However since it's an API, it won't know how many or of what type the options will be. Since I am doing mostly functions, interfaces immediately pop into mind. But I've also seen handler systems implemented with class extension, where a handler has to extend a base class, where the basic structure of a handler is put. This "Class or interface problem" has plagued my code for quite awhile. So I know the differences, but when should I use them?