Try
@echo off
echo Your PC will shutdown in 30 seconds! Press CTRL+C to abort.
ping -n 31 127.0.0.1>nul
shutdown /s
The PING command is a secure way of pausing the batch script for desired amount of time. More info here: How to wait in a batch script?
Pressing Ctrl-C will abort a batch script from continuing.