Moved core scripts to its own file + minor item script adjustments