changed entity/player to entity/agent