modified some scripts