moved tick listener into terminal directive