Does “Prevent computer from sleeping…” remain in effect even if I close the lid?
Closing the lid will put the system to sleep, no matter what settings you employ.  This is considered the equivalent of selecting “Sleep” from the Apple menu.  The only way the laptop will stay awake after closing the lid, is if you have an external monitor attached to it and the laptop is being powered by its wall plug (i.e. it is not running off its battery). In which case, it is considered to be in “clamshell” mode and the computer will stay awake and output its video to the external monitor.  In all other cases, closing the lid will put the system to sleep, and no software can override that.