Then you could have escaped to either C31 or E31, like Bartosz said.
I came to ask about a very similar situations. There are a number of spots on the board where an agent could get pinned by two or three hunters. As just one example, an agent on Q32 and hunters on Q31 and R32.
Since the rules clearly state that an agent can’t move through a hunter, what’s the recourse?