Move Emitter into Robot Class

Here's the emit and on methods inside the robot class with the use of generics instead of object parameters.