Moved files round & fixed up define plugin