In my experience the biggest thing you can do is check out the home inspector you intend to use by checking references from past RECENT clients.
I've bought about half a dozen properties since 1997 and I've had crap inspectors and great inspectors - the first two came recommended by my realtors at the time, and they were not very thorough and gave me form reports with check boxes filled out.
Then I wised up and started getting referrals from pros.
The other thing is - GO WITH THEM. Walk with them through the entire process. A good THOROUGH inspection should take about 3 hours. You want to see them testing ALL the electric (including receptacles with a ground tester), all the appliances, getting up on the roof, getting down under the house, testing all the plumbing, etc.
ASK QUESTIONS the whole time. Even (especially) when you know the answer. If your inspector cannot give you good answers, don't hesitate to stop the inspection and tell him or her that you're not satisfied.
Remember, you're getting ready to commit to a HUGE amount of debt and responsibility with this purchase. Treat the inspection seriously.
Good luck!
In addition to the basics, seen in this answer: What are some of the best books/resources on home inspection for first time home buyers?, the fact that someone's been messing around with the innards of the house means you should pay extra attention to the areas you know they've worked on, and whatever's around it.
You mentioned they replaced the roof. Get up into the attic and look at the job from underneath. Do you see any signs of recent leakage (wet wood, drips, ice, stains)? Water damage that looks older MAY be OK, but if the wood appears rotten or mouldy, they didn't go deep enough in their demo when re-roofing.
Windows can be problematic. If the flipper enlarged the window frames, and did so improperly, this is a whole world of problems for you. They could have taken out the header, or installed a new one improperly, putting the weight of your house on the window frame itself instead of letting studs and plates do it. They could have weakened the jack or (God forbid) king studs which transfer the weight from the header and top plate down to the foundation, again around the window frame without putting load on it. If they cut out brick, they may not have installed a proper lintil in the brickwork. All of these can make the house settle down onto your window frame, making them hard to open/close and in the extreme collapsing the frame, breaking the window and making the structure above extremely unstable.
Doors are similar; you have to have a proper header, jack stud, and king studs supporting the frame, otherwise the structure of the house will bear down and collapse the frame onto your door, and you'll never get it back out. If the flipper changed out exterior doors, you may have some security issues related to the screws in the hingeplates and the strikeplate; if those don't go into the studs on either side of the frame, the door can be kicked open pretty easily.
Plumbing is also difficult for a novice to get right. Worse than electrical IMO, but I'm more comfortable with wiring work than plumbing personally. Unlike electrical wiring, water is dependent on gravity to work properly. Slope of the pipes, proper P-traps, proper installation of T-junctions and other joints to allow for the free flow of water (and making sure the joints don't leak), all of these are things the average home flipper looking to add a sink to the master bath and rearrange the shower and tub may not be taking into account.
To check for plumbing problems, first smell all the drains. If you smell sewer gas or general decomposition, odds are someone didn't put in a trap. Or, the trap has gone dry, in which case if you run some water down the drain and then come back and smell it later, the smell should be gone.
Then, for sinks, open the tap full blast with the drain open. The water should drain quickly and should not back up. If it drains slowly or backs up, you might have an improper slope on the drain line, or the sink might be too far from a vent stack. For tubs/showers, use the faucet to fill a bucket, then pour it down the drain. Again, the tub should drain quickly (though this is a lot more water than you were running down the sink so it will take a few seconds to drain fully). Check for leaks on all pipes you can see; evidence of drips, mould, etc etc.
Best Answer
What you need is called an Energy Audit. We had one done on our home several years ago. They go through your home looking for areas lacking in energy efficiency. One of the major parts of the audit is called a Blower Door Test.
During this test they put a large fan into the door of your home and put your house under a vacuum. The result of this test - how much air the fan is able to suck into your home from leaks - determines how "tight" your home is.
Our auditor went around the home with a smoke pen to identify areas where air was coming in - around switches, electrical receptacles, doors, windows, etc. Several days later a written report was provided to us which detailed specific areas to improve, ordered from most to least cost effective.
The Canadian Natural Resources website has more information about these types of programs.