Learning and the Emergence of Behavioural Rules in a Bargaining Game