Changeset - r25664:40e22395c06b
[Not reviewed]
master
0 2 0
rubidium42 - 3 years ago 2021-06-12 19:09:58
rubidium@openttd.org
Cleanup: remove IConsoleWarning/IConsoleError helpers

Both did not support format parameters, so in many places IConsolePrint(CC_ERROR, "message") was used with a style different from what IConsoleError would do.
2 files changed with 0 insertions and 22 deletions:
0 comments (0 inline, 0 general)
src/console.cpp
Show inline comments
 
@@ -145,26 +145,6 @@ void CDECL IConsolePrintF(TextColour col
 
}
 

	
 
/**
 
 * It is possible to print warnings to the console. These are mostly
 
 * errors or mishaps, but non-fatal. You need at least a level 1 (developer) for
 
 * debugging messages to show up
 
 */
 
void IConsoleWarning(const char *string)
 
{
 
	if (_settings_client.gui.developer == 0) return;
 
	IConsolePrintF(CC_WARNING, "WARNING: %s", string);
 
}
 

	
 
/**
 
 * It is possible to print error information to the console. This can include
 
 * game errors, or errors in general you would want the user to notice
 
 */
 
void IConsoleError(const char *string)
 
{
 
	IConsolePrintF(CC_ERROR, "ERROR: %s", string);
 
}
 

	
 
/**
 
 * Change a string into its number representation. Supports
 
 * decimal and hexadecimal numbers as well as 'on'/'off' 'true'/'false'
 
 * @param *value the variable a successful conversion will be put in
src/console_func.h
Show inline comments
 
@@ -47,8 +47,6 @@ static inline void IConsolePrint(TextCol
 
}
 

	
 
void CDECL IConsolePrintF(TextColour colour_code, const char *format, ...) WARN_FORMAT(2, 3);
 
void IConsoleWarning(const char *string);
 
void IConsoleError(const char *string);
 

	
 
/* Parser */
 
void IConsoleCmdExec(const char *cmdstr, const uint recurse_count = 0);
0 comments (0 inline, 0 general)