()
| 387 | } |
| 388 | |
| 389 | public void run() |
| 390 | { |
| 391 | this.running = true; |
| 392 | |
| 393 | try |
| 394 | { |
| 395 | this.startGame(); |
| 396 | } |
| 397 | catch (Throwable throwable) |
| 398 | { |
| 399 | CrashReport crashreport = CrashReport.makeCrashReport(throwable, "Initializing game"); |
| 400 | crashreport.makeCategory("Initialization"); |
| 401 | this.displayCrashReport(this.addGraphicsAndWorldToCrashReport(crashreport)); |
| 402 | return; |
| 403 | } |
| 404 | |
| 405 | while (true) |
| 406 | { |
| 407 | try |
| 408 | { |
| 409 | while (this.running) |
| 410 | { |
| 411 | if (!this.hasCrashed || this.crashReporter == null) |
| 412 | { |
| 413 | try |
| 414 | { |
| 415 | this.runGameLoop(); |
| 416 | } |
| 417 | catch (OutOfMemoryError var10) |
| 418 | { |
| 419 | this.freeMemory(); |
| 420 | this.displayGuiScreen(new GuiMemoryErrorScreen()); |
| 421 | System.gc(); |
| 422 | } |
| 423 | } |
| 424 | else |
| 425 | { |
| 426 | this.displayCrashReport(this.crashReporter); |
| 427 | } |
| 428 | } |
| 429 | } |
| 430 | catch (MinecraftError var12) |
| 431 | { |
| 432 | break; |
| 433 | } |
| 434 | catch (ReportedException reportedexception) |
| 435 | { |
| 436 | this.addGraphicsAndWorldToCrashReport(reportedexception.getCrashReport()); |
| 437 | this.freeMemory(); |
| 438 | logger.fatal("Reported exception thrown!", reportedexception); |
| 439 | this.displayCrashReport(reportedexception.getCrashReport()); |
| 440 | break; |
| 441 | } |
| 442 | catch (Throwable throwable1) |
| 443 | { |
| 444 | CrashReport crashreport1 = this.addGraphicsAndWorldToCrashReport(new CrashReport("Unexpected error", throwable1)); |
| 445 | this.freeMemory(); |
| 446 | logger.fatal("Unreported exception thrown!", throwable1); |
nothing calls this directly
no test coverage detected