Udp implementation fixes

Intention:
Fix the current udp implementation to workaround the most pressing errors with old clients.
While the new version is reasonable faster (especialy if connection to new version server) it can't compete to a complete protocol switch (e.g. TCP, maybe enet but I don't have any comparison)

This pull request is intended as discussion and review base, please comment and show up issues.

This pull is based uppon following other pulls:
https://github.com/minetest/minetest/pull/1067
https://github.com/minetest/minetest/pull/1068
https://github.com/minetest/minetest/pull/1054