| 773 | } |
| 774 | |
| 775 | QString MinecraftInstance::getStatusbarDescription() |
| 776 | { |
| 777 | QStringList traits; |
| 778 | if (hasVersionBroken()) |
| 779 | { |
| 780 | traits.append(tr("broken")); |
| 781 | } |
| 782 | |
| 783 | QString description; |
| 784 | description.append(tr("Minecraft %1 (%2)").arg(m_components->getComponentVersion("net.minecraft")).arg(typeName())); |
| 785 | if(m_settings->get("ShowGameTime").toBool()) |
| 786 | { |
| 787 | if (lastTimePlayed() > 0) { |
| 788 | description.append(tr(", last played for %1").arg(Time::prettifyDuration(lastTimePlayed()))); |
| 789 | } |
| 790 | |
| 791 | if (totalTimePlayed() > 0) { |
| 792 | description.append(tr(", total played for %1").arg(Time::prettifyDuration(totalTimePlayed()))); |
| 793 | } |
| 794 | } |
| 795 | if(hasCrashed()) |
| 796 | { |
| 797 | description.append(tr(", has crashed.")); |
| 798 | } |
| 799 | return description; |
| 800 | } |
| 801 | |
| 802 | Task::Ptr MinecraftInstance::createUpdateTask(Net::Mode mode) |
| 803 | { |
no test coverage detected