Can I connect my Nikon D3100 to a computer, in the same way as a webcam?

I've had my Nikon D3100 for a few years now, but was wondering if it is possible to use it with a stop-motion programme like Dragonframe, and if so, what hardware would I need in order to do this? Any help would be greatly appreciated.

A typical external webcam connects to a computer using a USB cable to connect the webcam to the computer's USB port.
Read the manual for your D3100. Here is the link for your convenience:
http://download.nikonimglib.com/archive2/sDcfr00jEJ5F01Yssec54ma3bq70/D3100RM_EU(En)04.pdf
You are looking for "tethering". If you find it, great. If you don't, then it is not possible to do what you want - unless you get other parts to do the monitoring - but no way to control the camera from Dragonframe.

No.
You can still do stop motion with your camera with tethering.