Made the Mod NBT class a bit more universal.

some code tidy up.