Fixes for new modloader api