Issue with adding a script from the wiki

Hello,

I’ve been trying for over a day to get this to work, but I really don’t understand what’s wrong.
I took the “c# Messenger Extended” scripts from the wiki. I used it in a project a few days ago and it worked fine.
But right not, I can’t add it to a object on the scene, I keep getting the “script must derive from monobehaviour” error.

When I saw this, I actually went back to the other project to see what’s going on and found out that it stopped working there as well.

I’ve reinstalled unity a few times, I started new projects,I recopied the code from the wiki, neither with any results.

Any help would be appreciated. Thanks.

The error means what it says, you cannot attach that script to a game object. All the functions in that code are declared as ‘static’. Static functions don’t need an instance so you can call those functions from any script in your project.

You can see example code of how to use it down the bottom in the unit test.