adding a lockfile

without this the script doesn't stop minecraft when changing the runlevel