]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Loopify find command
authorMario <mario@smbclan.net>
Fri, 25 Dec 2015 07:08:03 +0000 (17:08 +1000)
committerMario <mario@smbclan.net>
Fri, 25 Dec 2015 07:08:03 +0000 (17:08 +1000)
qcsrc/client/commands/cl_cmd.qc

index be3ac56450b170dcc0806bcca54bc16bd1556a8d..11ee469efbac00effa9268b1ecd69d00fe86914d 100644 (file)
@@ -407,11 +407,7 @@ void LocalCommand_find(int request, int argc)
        {
                case CMD_REQUEST_COMMAND:
                {
-                       entity client;
-
-                       for (client = world; (client = find(client, classname, argv(1))); )
-                               LOG_INFO(etos(client), "\n");
-
+                       FOREACH_ENTITY_CLASS(argv(1), true, LAMBDA(LOG_INFO(etos(it), "\n")));
                        return;
                }