diff --git a/src/main/scala/org/scadcop/solver/decentralized/mgm2/AgentBehaviour.scala b/src/main/scala/org/scadcop/solver/decentralized/mgm2/AgentBehaviour.scala index cc0ffcb4e1c3d2276eb2705047d638130412c535..92f1b8274715affc849338a2921e9296954948d7 100755 --- a/src/main/scala/org/scadcop/solver/decentralized/mgm2/AgentBehaviour.scala +++ b/src/main/scala/org/scadcop/solver/decentralized/mgm2/AgentBehaviour.scala @@ -384,8 +384,9 @@ class AgentBehaviour(variable: Variable, stay using mind // When it receives an offer it does NOTHING - case Event(MakeOffer(_), mind) => + case Event(MakeOffer(someOffer), mind) => if (debug) println(s"$variable in $stateName has received MakeOffer") + sender ! Reject(someOffer) stay using mind //when it receives a neighbour's delta and the neighbourDeltas is partial @@ -422,8 +423,9 @@ class AgentBehaviour(variable: Variable, stay using mind // When it receives an offer it does NOTHING - case Event(MakeOffer(_), mind) => + case Event(MakeOffer(someOffer), mind) => if (debug) println(s"$variable in $stateName has received MakeOffer and ignores it") + sender ! Reject(someOffer) stay using mind // When it receives a neighbour's delta and the neighbourDeltas is partial @@ -505,7 +507,7 @@ class AgentBehaviour(variable: Variable, // When its partner tells it to go case Event(GiveGo(_), mind) => - if (debug) println(s"$variable in $stateName has received GiveGo and stahes it") + if (debug) println(s"$variable in $stateName has received GiveGo and stashes it") stash stay using mind