add a way to get variables from a class, enforce event constructor