Meta set nodedef 4

It is not finished yet, but I'm still opening the pull request...
I rebased celeron55's work, and added a few fixes.