Just imagine that you were walking home after the worst day of your life, minding your own business, when a pony of all things jumps out, knocks you unconscious, then demands refuge.
Well...it can happen.
(For the record, this all happens between the end of Season 2 and the start of Season 3, if anyone wanted to know...)