event detection added