The onCreated() part is called for each joined class, if you pre-join a class (put the join outside of any function) or you join a class in an onCreated() function.
Other events only choose the first event handler they find. That makes it possible to overwrite the event handler of a class. If you overwrite the event handler and want still that the original event handler is executed, call classname::function yourself, like
PHP Code:
function onCreated() {
join("myitems");
// no need to call myitems::onCreated() here since it is executed anyway
}
function onPlayerEnters() {
echo("player enters!");
myitems::onPlayerEnters();
}
We should may be add a wiki page for the Graal script classes.