Added a bunch of stuff for onJoin