| 404 | while (*end == ' ' && end < maxEnd) |
| 405 | { |
| 406 | end++; |
| 407 | } |
| 408 | if (*end == '=') |
| 409 | { |
| 410 | end++; |
| 411 | while (*end == ' ' && end < maxEnd) |
| 412 | { |
| 413 | end++; |
| 414 | } |
| 415 | // should be followed with '"' |
| 416 | if (*end == '"') |
| 417 | { |
| 418 | end++; |
| 419 | // scan name |
| 420 | char buf[1024]; |
| 421 | int maxC = 0; |
| 422 | ; |
| 423 | while (*end != '"' && end < maxEnd && maxC < sizeof(buf) - 1) |
| 424 | { |
| 425 | buf[maxC++] = *end++; |
| 426 | } |
| 427 | buf[maxC] = 0; |
| 428 | if (*buf) |
| 429 | { |
| 430 | name = buf; |
| 431 | } |
| 432 | } |
| 433 | } |
| 434 | break; |
| 435 | } |
| 436 | } |
| 437 | } |
| 438 | |
| 439 | // Localize briefingName. For "@KEY" / "$STR_KEY" tokens we |
| 440 | // try the mission's local stringtable.csv first — at scan |
| 441 | // time no mission has been opened yet, so the global |
| 442 | // _tableMission is empty and Localize() would return "" |
| 443 | // (or pass through the literal) for keys that live only in |
| 444 | // the mission's own CSV. Falls back to the global tables |
| 445 | // when the local CSV doesn't have the key. |
| 446 | RString displayName; |
| 447 | if (name[0] == '$' || name[0] == '@') |
no test coverage detected