Do you want to be a father to the child in question? Like, would you stick around to help raise the kid?
If you don't want to be in the child's life, are you okay paying child support for 18 years? Do you have the financial means to do so even if you didn't want to be an active father?
Society, and many here, would probably tell you the responsible thing to do is raise the child you helped create, or at least financially support it, lest you be branded a 'deadbeat dad'.
Leaving morality and judgement out of it,
If you don't want to be a father and don't want to financially support the kid, you could just ghost the mom-to-be and hope she doesn't coming knocking down the line for some child support. Are you okay with doing such a thing?
If a woman has become pregnant with your child, you are responsible for that happening. No one forced you to put your d!ck inside her and there is always inherent risk of pregnancy when you have sex. If you are indeed in such a situation that you've mentioned, you ultimately placed yourself there with your decisions... You should know this obviously.
You may find that your personal desires going forward may conflict with what would weigh less heavily on your conscience. Keep that in mind when answering the clarifying questions I asked above.