Flanking
When you and an ally are flanking a foe, it has a harder time defending against you. A creature is off-guard (taking a –2 circumstance penalty to AC) to melee attacks from creatures that are flanking it.
To flank a foe, you and your ally must be on opposite sides of the creature. A line drawn between the center of your space and the center of your ally’s space must pass through opposite sides or opposite corners of the foe’s space. Additionally, both you and the ally have to be able to act, you must be wielding melee weapons or be able to make an unarmed attack, you can’t be under any effects that prevent you from attacking, and you must both have the enemy within reach. If you are wielding a reach weapon, you use your reach with that weapon for this purpose.
3D Flanking
Though battle grids are often two-dimensional, the game world isn’t! Sometimes you might need to visualize a creature’s space as a cube for flanking. For instance, if Valeros is underneath a flying sphinx while Lini is flying above the sphinx, they might be flanking it even if they’re piled in an odd stack on your battle grid. And if Valeros were mounted on a horse, he might be able to measure from farther off the ground than normal.
In these cases, it’s usually best to have the GM make the call on who’s flanking rather than trying to do meticulous measurements in three dimensions.
TINY CREATURES AND FLANKING
Tiny creatures usually have reach of 0 feet and need to be in a creature’s space to attack it. This makes a Tiny creature unable to flank unless it’s able to use a weapon with reach or has a melee unarmed attack with reach greater than 0 feet.
The GM might allow Tiny creatures to flank other Tiny creatures if they’re all in the same square, but this is best left for special circumstances and uses the GM’s best judgment.
AVOIDING FLANKING
Flanking is an excellent battle tactic that can cause the flanked creature to get hit much more often. Escaping and avoiding flanks can be crucial for a player character’s survival.
Movement: The most straightforward means to escape a flank is usually to Stride. It’s often worth it to avoid the hits you’d take due to being off-guard and to make enemies spend actions moving to catch you.
All-Around Vision: Some monsters are covered in eyes that face multiple directions or are otherwise hard to distract, making them immune to flanking.
Deny Advantage: Some classes, such as rogue, can gain the deny advantage class feature, makes them harder to outflank. You can’t flank a creature with deny advantage unless your level is higher than the creature’s.