You could have pulled something. Since its in your knee, you most likely pulled a ligament. Or you could have simply sprained it. If the pain continues more than a week, its probably a ligament and you need to get it checked out. For now, keep weight off of it and ice it down.