Skip to content

Commit 3285bf7

Browse files
committed
Print direct command line responses to standard output instead of using the log system
Using logging for these just makes them bloated and hard to read and overally just not neat at all.
1 parent 52e5b51 commit 3285bf7

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

src/main.cpp

+10-10
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ static void set_allowed_options(OptionList *allowed_options)
300300

301301
static void print_help(const OptionList &allowed_options)
302302
{
303-
dstream << _("Allowed options:") << std::endl;
303+
std::cout << _("Allowed options:") << std::endl;
304304
print_allowed_options(allowed_options);
305305
}
306306

@@ -313,37 +313,37 @@ static void print_allowed_options(const OptionList &allowed_options)
313313
if (i->second.type != VALUETYPE_FLAG)
314314
os1 << _(" <value>");
315315

316-
dstream << padStringRight(os1.str(), 24);
316+
std::cout << padStringRight(os1.str(), 24);
317317

318318
if (i->second.help != NULL)
319-
dstream << i->second.help;
319+
std::cout << i->second.help;
320320

321-
dstream << std::endl;
321+
std::cout << std::endl;
322322
}
323323
}
324324

325325
static void print_version()
326326
{
327-
dstream << PROJECT_NAME_C " " << g_version_hash << std::endl;
327+
std::cout << PROJECT_NAME_C " " << g_version_hash << std::endl;
328328
#ifndef SERVER
329-
dstream << "Using Irrlicht " << IRRLICHT_SDK_VERSION << std::endl;
329+
std::cout << "Using Irrlicht " << IRRLICHT_SDK_VERSION << std::endl;
330330
#endif
331-
dstream << "Build info: " << g_build_info << std::endl;
331+
std::cout << "Build info: " << g_build_info << std::endl;
332332
}
333333

334334
static void list_game_ids()
335335
{
336336
std::set<std::string> gameids = getAvailableGameIds();
337337
for (std::set<std::string>::const_iterator i = gameids.begin();
338338
i != gameids.end(); ++i)
339-
dstream << (*i) <<std::endl;
339+
std::cout << (*i) <<std::endl;
340340
}
341341

342342
static void list_worlds()
343343
{
344-
dstream << _("Available worlds:") << std::endl;
344+
std::cout << _("Available worlds:") << std::endl;
345345
std::vector<WorldSpec> worldspecs = getAvailableWorlds();
346-
print_worldspecs(worldspecs, dstream);
346+
print_worldspecs(worldspecs, std::cout);
347347
}
348348

349349
static void print_worldspecs(const std::vector<WorldSpec> &worldspecs,

0 commit comments

Comments
 (0)