Agent-based flow-shop modelling in dynamic environment