An opportunity attack occurs when an opponent attempts to leave a melee combat without taking the necessary precautions to disengage. This situation offers the opponent the chance to launch a quick reflexive attack.
To capitalize on this opportunity, the attacker must succeed in an attack roll against the fleeing adversary. If the roll is successful, the attacker performs an attack with the weapon they are holding, inflicting appropriate damage.
The victim of the opportunity attack cannot parry or dodge this unexpected strike, reflecting the vulnerability created by their hasty retreat.