You should check for fuel pressure when the truck will not start. On the metal fuel rails for the fuel injectors there will be a schrader valve. It looks like a tire valve stem. Press the needle valve down in the schrader valve and see if you get a big spray of fuel. You may have a bad fuel pump or fuel pump relay. But check and see if you have fuel pressure when the Ranger will not start when hot. Let me know what you find. Don't replace anything just yet.
Do not use a tire pressure guage. You will need a fuel pressure guage. A tire pressure guage only measures air pressure. It will not measure fuel pressure and the system needs to be enclosed when testing fuel pressure. You do not want any fuel leaks. Fire hazard may happen.
Below is a fuel pressure guage.
Plus if the fuel pumps were burning up, the relay may be burned up also.
Try a couple of test.
Unplug the IAC and start the truck and see if it stalls. You may have a vacuum leak.
The only way to find out if you have any bad sensors is to get the codes from the engine computer. The connectors to connect to are under the hood. Below are a couple of diagrams to use to get any codes. You will need a jumper wire
No special equipment hookup is required. STI is jumpered to SIG RTN at Self-Test Input (STI) connector and the Data Link Connector (DLC).
Then count the check engine light flashes for any codes and write them down. They will be 2 digit codes.