If there is an orcish attack there should be reason for it. There are resources in A that the forces directing the orcs want? A is close to the steppes where orcs are, and its patrols are guarding another direction? The orc chief's wife eloped with someone from town?
Something causes that orc attack. Once you decided there was going to be an orc attack on A, it needs to be grounded in the world.
All of the things that ground it, they'll have some exposure to the PCs. There was a temple of ioun in A (in which the artifact was stored). There where some well dressed half orcs (kids of the baron and the ex-chiefess). There was one overworked tired guard at the entrance.
None of these say "there is an orc attack coming", so PCs leaving aren't choosing to avoid the orc attack. But they did ground the attack in the world, and if the PCs had investigated they'd have some clues, and afterwards if they defended it and worked out why they might remember the events as foreshadowing.
Then the PCs move to B. And you want to move the orc attack. Which means you either have to have a completely different reason for the orcs to attack, not have the forshadowing hooks, or reuse the foreshadowing hooks.
If the orc attack is some modular thing completely divorced from the rest of the world, yes moving it so it follows the PCs has no additional problems. But the very fact the orc attack was a modular thing disconnected from the world is as side effect of wanting to be able to follow the PCs, and it itself is a problem, and once you connect the event to the world and expose those connections they become less mobile.
OTOH, having a "orc mercenaries attack" encounter designed, then using it because you have reason for the some mercenaries to attack, is different. The reasoning provides connection snd drives it, not the schedule of the encounter.
However, the PCs going from A to B should change things enough that the encojnter you'll pull out of the bag at B is different than A. Even if you have A be overrun, and use a tweaked version for a later encounter at C.