The command shutdown can be given a time parameter.
shutdown -s -f -t 7200
This would forcefully shut down the computer after 2 hours. It is possible to abort the task using shutdown -a though. Placing this in a batch file, and placing that batch file in the start menu, startup folder will run this every time this user logs on.
If aborting the shutdown becomes an issue, it is possible to accomplish the same using Task Scheduler.
Create a new task. For event, select At log on
, choose Specific user, and select his user.
Below, check Delay task for
, and change it to 2 hours. (you will have to manually type it in, but it will work) Press ok.
In the Event tab, press new, and select program from the dropdown list.
Below at program choose: shutdown
Below that at parameters, specify: -s -f -t 0
Press ok twice.
The task has been made and whenever this user logs in, after 2 hours, without any warning, the computer will be turned off. Any unsafed items will be gone. Unfortunately this is not something you want to change, because otherwise at shutdown it will allow the user to cancel the shutdown and continue to work normally.
In theory, you could copy the task, delay the 2nd for 130 minutes, and use these settings, and alter the first one and remove the -f option. That will first shutdown but allow the user to cancel in case any documents are open. If they continue to work, at 2 hours and 10 minutes, the pc is shutdown forcefully and they lose any work they had open.