Script rework