Removes type as member variable from message structs.

type can now be queried by the message::message_to_type(message) function.
Removed the need for default constructors on messages.

Needed to change the serialization api a bit.