function logExecutionEvent(id, type, message, time) {

    if (logMode === 'l') {
      if (!eventList.executionEvents[id]) {
        eventList.executionEvents[id] =  [];
      }
      eventList.executionEvents[id].push({'type': type, 'event': message, "timestamp": time});
    } else if (logMode === 'v') {
      console.log(type + ': Agent ' + id +  ' ' + message + ' on ' + time);
    }

  }
function logExecutionEvent(id, type, message, time) {

    if (logMode === 'l') {
      if (!eventList.executionEvents[id]) {
        eventList.executionEvents[id] =  [];
      }
      eventList.executionEvents[id].push({'type': type, 'event': message, "timestamp": time});
    } else if (logMode === 'v') {
      console.log(type + ': Agent ' + id +  ' ' + message + ' on ' + time);
    }

  }
function logExecutionEvent ( id , type , message , time ) { if ( logMode === 'l' ) { if ( ! eventList . executionEvents [ id ] ) { eventList . executionEvents [ id ] = [ ] ; } eventList . executionEvents [ id ] . push ( { 'type' : type , 'event' : message , "timestamp" : time } ) ; } else if ( logMode === 'v' ) { console . log ( type + ': Agent ' + id + ' ' + message + ' on ' + time ) ; } }
records the agent's execution events in a temporary structure if log method is 'l' or outputs the same events to the console if method is 'v'
records the agent s execution events in a temporary structure if log method is l or outputs the same events to the console if method is v