private void receiveAgentCompletedMessage(MessageEngineAgCompletedCommand msg) { _numberOfIncompleteAg--; if (_numberOfIncompleteAg <= 0) { _numberOfIncompleteAg = _subscribedActorAgents.Count(); sendSSCompletedMessage(); } }
public ActorAgent(IActorRef actorTextOutput, Agent ag, IActorRef actorSolarSystem) { _actorTextOutput = actorTextOutput; _actorSolarSystem = actorSolarSystem; _agent = ag; _tickCompleteCmd = new MessageEngineAgCompletedCommand(_agent.AgentId); AgentControllerState stateForAgent = new AgentControllerState(ag); switch (_agent.Type) { //case AgentTypeEnum.Trader: // _agentC = new AgentTraderController(ag, _actorTextOutput); // break; default: _agentC = new AgentDefaultController(stateForAgent, _actorSolarSystem, _actorTextOutput); break; } Receive <MessageTick>(msg => receiveDefaultTick(msg)); }