Compare commits
	
		
			No commits in common. "479fcca851097254b7e3f771f8186a9bf820678d" and "0fdd3e2c9a1a16a6f6cdb172b411ecf9467fa4ff" have entirely different histories.
		
	
	
		
			479fcca851
			...
			0fdd3e2c9a
		
	
		
| @ -1,5 +1,4 @@ | |||||||
| using System; | using System; | ||||||
| using System.Linq; |  | ||||||
| 
 | 
 | ||||||
| namespace NonaBGS.BGS { | namespace NonaBGS.BGS { | ||||||
|     public class CombatZone : LogEntry, IComparable { |     public class CombatZone : LogEntry, IComparable { | ||||||
| @ -25,8 +24,7 @@ namespace NonaBGS.BGS { | |||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         public override string ToString() { |         public override string ToString() { | ||||||
|             return string.Format("Won {0} x {1} {2} Combat Zone(s) for {3}", |             return string.Format("Won {0} x {1} {2} Combat Zone(s)", Amount, Type, Grade); | ||||||
|                 Amount, Grade, Type, Faction); |  | ||||||
|         } |         } | ||||||
|     } |     } | ||||||
| } | } | ||||||
|  | |||||||
| @ -37,9 +37,7 @@ namespace NonaBGS.BGS { | |||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         public override string ToString() { |         public override string ToString() { | ||||||
|             return string.Format("Faction Kill Bonds: {0} against {1}",  |             return string.Format("Faction Kill Bonds: {0}", Credits.FormatCredits(TotalSum)); | ||||||
|                 Credits.FormatCredits(TotalSum), |  | ||||||
|                 VictimFaction); |  | ||||||
|         } |         } | ||||||
|     } |     } | ||||||
| } | } | ||||||
|  | |||||||
| @ -43,26 +43,6 @@ namespace NonaBGS.BGS { | |||||||
|                                  "(Total value: {1} CR)\n", pages, sum); |                                  "(Total value: {1} CR)\n", pages, sum); | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|         private string BuildCargoSold(Objective objective) { |  | ||||||
|             StringBuilder builder = new StringBuilder(); |  | ||||||
|             SellCargo[] sold = objective.LogEntries |  | ||||||
|                                 .OfType<SellCargo>() |  | ||||||
|                                 .ToArray() |  | ||||||
|                                 ; |  | ||||||
| 
 |  | ||||||
|             if (sold == null && sold.Length > 0) { |  | ||||||
|                 return builder.ToString(); |  | ||||||
|             } |  | ||||||
| 
 |  | ||||||
|             foreach (SellCargo sell in sold) { |  | ||||||
|                 builder.AppendFormat("{0}\n", sell.ToString()); |  | ||||||
|             } |  | ||||||
| 
 |  | ||||||
|             builder.AppendFormat("\n"); |  | ||||||
| 
 |  | ||||||
|             return builder.ToString(); |  | ||||||
|         } |  | ||||||
| 
 |  | ||||||
|         private string BuildMicroResourcesSold(Objective objective) { |         private string BuildMicroResourcesSold(Objective objective) { | ||||||
|             var total = from entries in objective.LogEntries |             var total = from entries in objective.LogEntries | ||||||
|                         where entries.GetType() == typeof(SellMicroResources) |                         where entries.GetType() == typeof(SellMicroResources) | ||||||
| @ -219,9 +199,6 @@ namespace NonaBGS.BGS { | |||||||
|                 var micro = BuildMicroResourcesSold(objective); |                 var micro = BuildMicroResourcesSold(objective); | ||||||
|                 entries.Append(micro); |                 entries.Append(micro); | ||||||
| 
 | 
 | ||||||
|                 var sold = BuildCargoSold(objective); |  | ||||||
|                 entries.Append(sold); |  | ||||||
| 
 |  | ||||||
|                 log.Append(entries.ToString().Trim()); |                 log.Append(entries.ToString().Trim()); | ||||||
|                 log.Append("\n```\n"); |                 log.Append("\n```\n"); | ||||||
|             } |             } | ||||||
|  | |||||||
| @ -35,8 +35,7 @@ namespace NonaBGS.BGS { | |||||||
|                 e.Is(Events.MultiSellExplorationData) || |                 e.Is(Events.MultiSellExplorationData) || | ||||||
|                 e.Is(Events.SellMicroResources) || |                 e.Is(Events.SellMicroResources) || | ||||||
|                 e.Is(Events.RedeemVoucher) || |                 e.Is(Events.RedeemVoucher) || | ||||||
|                 e.Is(Events.FactionKillBond) || |                 e.Is(Events.FactionKillBond) | ||||||
|                 e.Is(Events.MarketSell) |  | ||||||
|                 ; |                 ; | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
| @ -106,14 +105,6 @@ namespace NonaBGS.BGS { | |||||||
|                     collate = true; |                     collate = true; | ||||||
|                 } else if (e.Is(Events.SellMicroResources)) { |                 } else if (e.Is(Events.SellMicroResources)) { | ||||||
|                     entry = new SellMicroResources(current_system, current_station); |                     entry = new SellMicroResources(current_system, current_station); | ||||||
|                     entry.Entries.Add(e); |  | ||||||
|                 } else if (e.Is(Events.MarketSell)) { |  | ||||||
|                     entry = new SellCargo() { |  | ||||||
|                         Faction = controlling_faction, |  | ||||||
|                         Station = current_station, |  | ||||||
|                         System = current_system |  | ||||||
|                     }; |  | ||||||
| 
 |  | ||||||
|                     entry.Entries.Add(e); |                     entry.Entries.Add(e); | ||||||
|                 } |                 } | ||||||
| 
 | 
 | ||||||
|  | |||||||
| @ -1,31 +0,0 @@ | |||||||
| using System.Text; |  | ||||||
| using System.Linq; |  | ||||||
| using EDJournal; |  | ||||||
| 
 |  | ||||||
| namespace NonaBGS.BGS { |  | ||||||
|     public class SellCargo : LogEntry { |  | ||||||
|         public override string ToString() { |  | ||||||
|             StringBuilder builder = new StringBuilder(); |  | ||||||
|             var sold = Entries.OfType<MarketSellEntry>().ToArray(); |  | ||||||
| 
 |  | ||||||
|             if (sold == null || sold.Length == 0) { |  | ||||||
|                 return builder.ToString(); |  | ||||||
|             } |  | ||||||
| 
 |  | ||||||
|             foreach (MarketSellEntry sell in sold) { |  | ||||||
|                 builder.AppendFormat("Sold {0} {1} to the {2}\n", |  | ||||||
|                     sell.Count, |  | ||||||
|                     sell.Type, |  | ||||||
|                     sell.BlackMarket ? "Black Market" : "Commodity Market" |  | ||||||
|                     ); |  | ||||||
|             } |  | ||||||
| 
 |  | ||||||
|             return builder.ToString().Trim(); |  | ||||||
|         } |  | ||||||
| 
 |  | ||||||
|         /// <summary> |  | ||||||
|         /// Selling resources to a market only helps the controlling faction |  | ||||||
|         /// </summary> |  | ||||||
|         public override bool OnlyControllingFaction => true; |  | ||||||
|     } |  | ||||||
| } |  | ||||||
| @ -25,7 +25,7 @@ | |||||||
|                     <RowDefinition Height="*"/> |                     <RowDefinition Height="*"/> | ||||||
|                 </Grid.RowDefinitions> |                 </Grid.RowDefinitions> | ||||||
|                 <ComboBox x:Name="type" Grid.Column="0" VerticalAlignment="Top" Width="Auto" IsReadOnly="True" Height="23" Margin="5" SelectedIndex="0"> |                 <ComboBox x:Name="type" Grid.Column="0" VerticalAlignment="Top" Width="Auto" IsReadOnly="True" Height="23" Margin="5" SelectedIndex="0"> | ||||||
|                     <ComboBoxItem Content="Ship"/> |                     <ComboBoxItem Content="Space"/> | ||||||
|                     <ComboBoxItem Content="On Foot"/> |                     <ComboBoxItem Content="On Foot"/> | ||||||
|                 </ComboBox> |                 </ComboBox> | ||||||
|                 <ComboBox x:Name="grade" Grid.Column="1" VerticalAlignment="Top" IsReadOnly="True" Margin="5" Height="23" Width="Auto" SelectedIndex="0"> |                 <ComboBox x:Name="grade" Grid.Column="1" VerticalAlignment="Top" IsReadOnly="True" Margin="5" Height="23" Width="Auto" SelectedIndex="0"> | ||||||
|  | |||||||
| @ -32,13 +32,6 @@ Please note that cartography data, micro resources, and vouchers only help the c | |||||||
| of a station. The tool is clever enough to exclude these if the station you turn them in at, is not | of a station. The tool is clever enough to exclude these if the station you turn them in at, is not | ||||||
| controlled by the faction you specified in the objective. | controlled by the faction you specified in the objective. | ||||||
| 
 | 
 | ||||||
| There is no entry in the journal if you win a combat zone. So you have to add those manually. Select |  | ||||||
| an objective for which you wish to log a combat zone. The faction in the objective, must be the |  | ||||||
| faction you fought for in the combat zone. Then click "Add Combat Zone Win". Select type, |  | ||||||
| either "On Foot" for Odyssey, or "Ship" for regular ones. Then select the grade (low, medium or |  | ||||||
| high), and how many you won. Then press "Accept". Select "Cancel" to abort. You can of course remove |  | ||||||
| the combat zone entries by selecting them, and pressing "DEL". |  | ||||||
| 
 |  | ||||||
|  |  | ||||||
| 
 | 
 | ||||||
| The window will then list all the journal entries it has found, and group them by objectives. You | The window will then list all the journal entries it has found, and group them by objectives. You | ||||||
|  | |||||||
| @ -41,8 +41,7 @@ | |||||||
|     <Reference Include="AutoCompleteTextBox, Version=1.1.1.0, Culture=neutral, processorArchitecture=MSIL"> |     <Reference Include="AutoCompleteTextBox, Version=1.1.1.0, Culture=neutral, processorArchitecture=MSIL"> | ||||||
|       <HintPath>packages\AutoCompleteTextBox.1.1.1\lib\net472\AutoCompleteTextBox.dll</HintPath> |       <HintPath>packages\AutoCompleteTextBox.1.1.1\lib\net472\AutoCompleteTextBox.dll</HintPath> | ||||||
|     </Reference> |     </Reference> | ||||||
|     <Reference Include="EDJournal, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL"> |     <Reference Include="EDJournal"> | ||||||
|       <SpecificVersion>False</SpecificVersion> |  | ||||||
|       <HintPath>..\edjournal\bin\Debug\EDJournal.dll</HintPath> |       <HintPath>..\edjournal\bin\Debug\EDJournal.dll</HintPath> | ||||||
|     </Reference> |     </Reference> | ||||||
|     <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> |     <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> | ||||||
| @ -76,7 +75,6 @@ | |||||||
|     </ApplicationDefinition> |     </ApplicationDefinition> | ||||||
|     <Compile Include="BGS\DiscordLogGenerator.cs" /> |     <Compile Include="BGS\DiscordLogGenerator.cs" /> | ||||||
|     <Compile Include="BGS\NonaDiscordLog.cs" /> |     <Compile Include="BGS\NonaDiscordLog.cs" /> | ||||||
|     <Compile Include="BGS\SellCargo.cs" /> |  | ||||||
|     <Compile Include="BGS\SellMicroResources.cs" /> |     <Compile Include="BGS\SellMicroResources.cs" /> | ||||||
|     <Compile Include="BGS\FactionKillBonds.cs" /> |     <Compile Include="BGS\FactionKillBonds.cs" /> | ||||||
|     <Compile Include="EDDB\PopulatedSystems.cs" /> |     <Compile Include="EDDB\PopulatedSystems.cs" /> | ||||||
|  | |||||||
		Reference in New Issue
	
	Block a user