Selecting which apps are allowed to cancel shutdown
An app will always cancel shutdown if it has an open unsaved document which needs your decision as to whether to save or not.

Also, if an app goes unresponsive, the shutdown will time out.

I'm not sure that behaviour can be changed, but I'm open to ideas.