make mmp more comfortable for another plugins
move a lot of code to mmp