Made setNextShape better