“So you were like the female Indiana Jones,
only without the hat and whip.”
“Well – without the hat.”
“It’s getting hot in here.”
I've written about this before - Castle was not speaking about a fictional character. In Toobworld, the swashbuckling archeologist was an actual person.
Read about it here.
Not that it really matters in the long run. 'Castle' takes place in an alternate TV dimension.