============ idInterpreter::Warning Prints file and line number information with warning. ============ */
| 491 | ============ |
| 492 | */ |
| 493 | void idInterpreter::Warning( const char *fmt, ... ) const { |
| 494 | va_list argptr; |
| 495 | char text[ 1024 ]; |
| 496 | |
| 497 | va_start( argptr, fmt ); |
| 498 | vsprintf( text, fmt, argptr ); |
| 499 | va_end( argptr ); |
| 500 | |
| 501 | if ( ( instructionPointer >= 0 ) && ( instructionPointer < gameLocal.program.NumStatements() ) ) { |
| 502 | statement_t &line = gameLocal.program.GetStatement( instructionPointer ); |
| 503 | common->Warning( "%s(%d): Thread '%s': %s", gameLocal.program.GetFilename( line.file ), line.linenumber, thread->GetThreadName(), text ); |
| 504 | } else { |
| 505 | common->Warning( "Thread '%s' : %s", thread->GetThreadName(), text ); |
| 506 | } |
| 507 | } |
| 508 | |
| 509 | /* |
| 510 | ================ |
nothing calls this directly
no test coverage detected