fix a bug in event_func.go, add ping func