sending and receiving socket events! still not quite sure what is going on