Humans often alter their behavior depending on the opponent's group membership, with positive (e.g., support of same-group members) or negative (e.g., stereotyping, oppression, genocide) consequences. An influential model developed by Hammond and Axelrod highlighted the emergence of macro-level "ethnocentric cooperation" from the aggregation of micro-level interactions based on arbitrary tags signaling group membership. In this paper, we replicated this model and extended it to allow a wider array of possible agents' behaviors, including the possibility of harming others. This allowed us to check whether and under which conditions xenophobia can emerge beside or in alternative to ethnocentrism. Proceedings 28th European Conference on Modelling and Simulation