@Override
    public void eventSent(EntityRef entity, Event event) {
        if (event.getClass() == AfterComponentAdded.class
                || event.getClass() == AfterComponentUpdated.class
                || event.getClass() == AfterComponentRemoved.class) {
            entityModified(entity);
        }
        if (event.getClass() == BeforeEntityUnloaded.class) {
            entityUnloaded(entity);
        }

        if (event.getClass().isAnnotationPresent(ToClientEvent.class)) {
            int entityId = internalEntityManager.getEntityId(entity);
            for (Map.Entry<String, Set<Integer>> clientKnownEntities : entitiesClientIsAwareOf.entrySet()) {
                String clientId = clientKnownEntities.getKey();
                if (clientKnownEntities.getValue().contains(entityId)) {
                    ClientCommunication clientCommunication = connectedClients.get(clientId);
                    try {
                        clientCommunication.sendEventToClient(entityId, event);
                    } catch (IOException exp) {
                        handleCommunicationErrorWithClient(clientCommunication);
                    }
                }
            }
        }
    }