Every accusation from Trump is some random line he pulled out of his ass on the spot, and people like you keep falling for it and trying to divine some grand strategy out of it.
Yeah, I'm sure Trump raving about Obama invading Iran was part of a galaxy brain geopolitical master plan hatched back when he was just a real estate developer / minor reality TV star who wouldn't even run for president for another 5 years and not just random attempts to go viral.
That's the "unfulfilled wish" part I was referring to.
There are exceptions -- birtherism comes to mind -- but that's what they are, exceptions. In general, though, accusations from Republicans reliably reflect things they are either already doing, planning to do, or wish they could get away with.
He can just have wanted to punish Iran or something without it being a full blown plan. Trump assassinated an Iranian general during his first term [1].