fix bug in turn ordering