added some group functions to tox.c, refactored broadcast type packets