Modify pendulum waves script