Can moving a piece for an unrelated reason accidentally deliver check via the flying-general rule?
These answers restate the rules implemented by our open-source engine, which follows the WXF laws and is regression-tested against the official 110-diagram repetition casebook. Where an answer refers to a specific position, that position lives on the linked reference page, where the build verifies it against the engine before publishing.
Direct answer
Yes, and it happens more often than players expect. If your piece was the sole occupant of the central file, separating the two generals, moving it anywhere else for a completely unrelated reason, capturing something, developing a piece, anything, immediately opens that file. The instant it does, the two generals face each other, which puts your opponent in check under the flying-general rule, regardless of what you were actually trying to do.
Why this is easy to miss
A player calculating a capture or a developing move is usually focused entirely on that move's own consequences, not on what else happens to be sitting on the central file at the time. A piece can spend the whole game on that file without ever being noticed as doing double duty, right up until the move that removes it.
Turning it into a real weapon
Strong players sometimes look for exactly this: a piece on the central file that they want to move anyway, for its own good reason, and check whether moving it also happens to deliver check for free. A move that achieves two things at once, its normal purpose plus an unexpected check, is a small but genuine source of extra tempo.
Related questions
Does the piece have to be a major piece for this to work?
No, any piece at all on the central file counts, right down to a lone soldier.
Can this happen by accident and actually hurt the player who triggers it?
Rarely, since delivering check is usually good for the player delivering it, but it can commit you to a line you had not fully calculated.