I remember a long time ago watching an episode of a TV show. I think it might have been Red Dwarf, but I'm not sure.
Here are some notable details that I remember about it: A female character flies away from the ship and goes down to a planet and somehow dies. She then meets what looks like her father. Her "father" then tells her that she has died and he has come to take her to the afterlife. The female character, however, refuses. After some dialogue, she figures out that what she is seeing is not her father, but rather a sort of alien being that preys on sentient beings by convincing them to come with it into its realm. In doing so, the alien being is somehow fed. However, the alien being can only acquire victims if they agree to come with it voluntarily. Once the being's cover is blown, it leaves the female character alone, but remarks that one day, she will come into its realm and will feed it for a long time.
After that scene has taken place, the woman awakens to find that the rest of the ship's crew managed to recover and revive her. One of the other crewmembers apologizes for taking so long and explains that a parasite in the woman's brain was sabotaging their attempts at resuscitation, but they have gotten rid of it and everything should be fine now.
Was that really an episode of Red Dwarf, or am I misremembering? What is the name of that episode?