A script node lets you attach a MEL script to a scene, and have the script run whenever the scene is opened (loaded from disk) or closed (when you open another scene file or start a new scene).
Refer to MEL script nodes for information on script nodes.