Using a script for this wouldn’t be that complex -
from bge import logic
cont = logic.getCurrentController()
obj = cont.owner
# Assuming the 'Example' class is in an external module of the same name,
from Example import *
if not 'init' in obj:
obj['example'] = Example()
obj['example'].exampleFunction()
That should work.
EDIT: Of course, that’s a simple script, but if you want to run it squarely from the controller… Hmm…
According to the Blender Wiki, about Module mode…
"… Then you define a function on that module and call that function from the controller. Instead of writing “myScript.py” on the script edit box, you’ll write “myModule.myFunc” on the module edit box. This function will run every time the controller is called. But other functions and variables outside of myFunc’s scope will only run once. This is good for optimizing your code when you want to initiate variables only once then use them later.
The Python module controller supports any number of attributes, this means packages are supported automatically. As well as “myModule.myFunc” you can do “myPackage.myModule.myFunc”, nested packages work too, as does method calls on class instances like: “myPackage.myModule.myInstance.myMethod”. The python controller is passed to the python function as an argument for functions that take one arg."
So, if you define the function or variable inside of what the controller runs, it should run every frame. Also, apparently, class functions should run every frame, as well… Are you sure it’s not working correctly?