Added event scripts + sample

take a look if you like it o.o
```
if(this.Active)
    Deactivate();
if(active)
    Activate();
```
Simplified :) If it's active it always has to be deactivated, either because it's supposed to or because it's being restarted. No matter whether it was active before or not, if it's activated (again) Activate is called.