diff --git a/BGS/Cartographics.cs b/BGS/Cartographics.cs
index c0e2cdf..14f3d7e 100644
--- a/BGS/Cartographics.cs
+++ b/BGS/Cartographics.cs
@@ -26,7 +26,7 @@ namespace NonaBGS.BGS {
public override string ToString() {
StringBuilder builder = new StringBuilder();
- builder.AppendFormat("Sold {0} CR worth of Cartographics Data", TotalSum);
+ builder.AppendFormat("Sold {0} worth of Cartographics Data", Credits.FormatCredits(TotalSum));
return builder.ToString();
}
diff --git a/BGS/SellMicroResources.cs b/BGS/SellMicroResources.cs
index 5daa3e3..4062b8a 100644
--- a/BGS/SellMicroResources.cs
+++ b/BGS/SellMicroResources.cs
@@ -22,7 +22,7 @@ namespace NonaBGS.BGS {
}
public override string ToString() {
- return string.Format("Sell Micro Resources: {0} CR", TotalSum);
+ return string.Format("Sell Micro Resources: {0}", Credits.FormatCredits(TotalSum));
}
}
}
diff --git a/BGS/Vouchers.cs b/BGS/Vouchers.cs
index b5832d8..b9c7f41 100644
--- a/BGS/Vouchers.cs
+++ b/BGS/Vouchers.cs
@@ -31,7 +31,7 @@ namespace NonaBGS.BGS {
public override string ToString() {
StringBuilder builder = new StringBuilder();
- builder.AppendFormat("{0} Vouchers: {1} CR", TotalSum, Type);
+ builder.AppendFormat("{0} Vouchers: {1}", Type, Credits.FormatCredits(TotalSum));
return builder.ToString();
}
diff --git a/Journal/Credits.cs b/Journal/Credits.cs
new file mode 100644
index 0000000..946d8f3
--- /dev/null
+++ b/Journal/Credits.cs
@@ -0,0 +1,21 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace NonaBGS.Journal {
+ public class Credits {
+ public static string FormatCredits(int amount) {
+ if ((amount % 1000000) == 0) {
+ amount /= 1000000;
+ return string.Format("{0}M CR", amount);
+ } else if ((amount % 1000) == 0) {
+ amount /= 1000;
+ return string.Format("{0}K CR", amount);
+ }
+
+ return string.Format("{0} CR", amount);
+ }
+ }
+}
diff --git a/Journal/MissionCompletedEntry.cs b/Journal/MissionCompletedEntry.cs
index efba6c0..5455698 100644
--- a/Journal/MissionCompletedEntry.cs
+++ b/Journal/MissionCompletedEntry.cs
@@ -101,7 +101,7 @@ namespace NonaBGS.Journal {
}
if (donated > 0) {
- builder.AppendFormat(" ({0} CR)", donated);
+ builder.AppendFormat(" ({0})", Credits.FormatCredits(donated));
}
readable_name = builder.ToString().Trim();
diff --git a/nonabgs.csproj b/nonabgs.csproj
index 2dfa151..123953f 100644
--- a/nonabgs.csproj
+++ b/nonabgs.csproj
@@ -75,6 +75,7 @@
+