Difference between Unity's messaging system and other custom messaging systems?

I recently started looking into using messaging systems, which are new to me, and part of my learning process to better myself at c# programing and writing better, more efficient code.

I have been reading about and using Unity's own "SendMessage" system, but I recently came across some video tutorials in which the user is using a custom messaging system like this one, and I was wondering a few things:

  1. Why is he not using Unity's built-in messaging system?
  2. What's the difference between the 2?
  3. Does Unity's messaging system have any major pros or cons?

Like I mentioned above, messaging systems are new to me, and although I understand their purpose and usage, I do not know how to tell a good one from a bad one, or whether or not Unity's built in messaging system will do everything I need it to do.

The difference is in the way how messages got from the sender to the consumer/receiver. The buildin system uses reflection to call a function you provide. Reflection is somewhat slow, so if you use this extensively (every frame) this may slow down your game. Another difference (some may say drawback) is that you need to know the consumer to send him the message directly.

Other systems like that you linked rely on delegates and events (ask your favorite C# learning book or google it if you want more details). Basically this works like a mailing list subscription: an object that want to receive certain types of messages subscribes itself on a list. When the event fires, all subscribers on the list got this message. The big advantage is that you fire events no matter to whom and every object that want it will get it.

Both systems can be useful, it depends on the type of application and how you layout your code.

Hope that helps...