Skip to content

Commit

Permalink
Merge branch 'new-frontiers-14:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
Lokey82 authored Mar 9, 2024
2 parents a4ac3d5 + e785325 commit 324b290
Show file tree
Hide file tree
Showing 77 changed files with 11,099 additions and 157 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,25 +94,27 @@ public void UpdateState(GeneralStationRecordConsoleState state)

StationRecordsFilterType.SelectId((int) _currentFilterType);

if (state.JobList != null)
{
JobListing.Visible = true;
PopulateJobsContainer(state.JobList);
}

if (state.RecordListing == null)
{
RecordListingStatus.Visible = true;
RecordListing.Visible = false;
RecordListing.Visible = true;
RecordListingStatus.Text = Loc.GetString("general-station-record-console-empty-state");
RecordContainer.Visible = false;
RecordContainerStatus.Visible = false;
RecordContainer.Visible = true;
RecordContainerStatus.Visible = true;
return;
}

RecordListingStatus.Visible = false;
RecordListing.Visible = true;
RecordContainer.Visible = true;
PopulateRecordListing(state.RecordListing!, state.SelectedKey);
if (state.JobList != null)
{
JobListing.Visible = true;
PopulateJobsContainer(state.JobList);
}

RecordContainerStatus.Visible = state.Record == null;

if (state.Record != null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,15 @@ private void UpdateUserInterface(Entity<GeneralStationRecordConsoleComponent> en
return;
}

var jobList = _stationJobsSystem.GetJobs(owningStation.Value);

var listing = _stationRecords.BuildListing((owningStation.Value, stationRecords), console.Filter);

switch (listing.Count)
{
case 0:
_ui.TrySetUiState(uid, GeneralStationRecordConsoleKey.Key, new GeneralStationRecordConsoleState());
GeneralStationRecordConsoleState emptyState = new(null, null, null, jobList, console.Filter);
_ui.TrySetUiState(uid, GeneralStationRecordConsoleKey.Key, emptyState);
return;
case 1:
console.ActiveKey = listing.Keys.First();
Expand All @@ -89,8 +92,6 @@ private void UpdateUserInterface(Entity<GeneralStationRecordConsoleComponent> en

if (console.ActiveKey is not { } id)
return;
var jobList = _stationJobsSystem.GetJobs(owningStation.Value);


var key = new StationRecordKey(id, owningStation.Value);
_stationRecords.TryGetRecord<GeneralStationRecord>(key, out var record, stationRecords);
Expand Down
64 changes: 64 additions & 0 deletions Resources/Changelog/Changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3575,3 +3575,67 @@ Entries:
message: Fixed rusty wall replacement
id: 4854
time: '2024-03-04T23:55:37.0000000+00:00'
- author: Spessmann
changes:
- type: Add
message: >-
Added the ship, SV Point, a science ship purchasable from the scrap
terminal.
id: 4855
time: '2024-03-06T02:45:06.0000000+00:00'
- author: Letholldus
changes:
- type: Add
message: >-
Adds the NC Hauler-Class Cargo and Salvage vessel to the game and the
Frontier outpost shipyard
id: 4856
time: '2024-03-08T01:24:03.0000000+00:00'
- author: Cheackraze
changes:
- type: Fix
message: Fixed job selector not showing up in empty records consoles
id: 4857
time: '2024-03-08T02:07:06.0000000+00:00'
- author: erhardsteinhauer
changes:
- type: Tweak
message: >-
Now tt is possible to print AstroGrass and AstroIce on Tile-Meister
5000.
id: 4858
time: '2024-03-08T02:14:57.0000000+00:00'
- author: Wolfking6116
changes:
- type: Fix
message: Centcom has recalled their faulty Anomaly Generator units!
id: 4859
time: '2024-03-08T13:53:08.0000000+00:00'
- author: erhardsteinhauer
changes:
- type: Tweak
message: >-
FlatpackVend sells flatpacked machines instead of circuits now
(renamed).
- type: Tweak
message: >-
JRPAKMAN, PAKMAN, SUPERPAKMAN, thrusters, gyroscopes and some other
machines are sold as flatpacks at cargo now.
- type: Tweak
message: >-
Particularly big musical instruments are sold as flatpacks from Autotune
vendomat.
id: 4860
time: '2024-03-08T15:13:09.0000000+00:00'
- author: Wolfking6116
changes:
- type: Add
message: Pilot and Mercenary corpses are being found across the Sector...
id: 4861
time: '2024-03-08T16:52:17.0000000+00:00'
- author: erhardsteinhauer
changes:
- type: Add
message: Now you can make a sawn-off PKA. But should you though?
id: 4862
time: '2024-03-08T17:55:56.0000000+00:00'
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ ent-CrateVendingMachineRestockAstroVend = { ent-CrateVendingMachineRestockAstroV
ent-CrateVendingMachineRestockAmmo = { ent-CrateVendingMachineRestockAmmoFilled }
.desc = { ent-CrateVendingMachineRestockAmmoFilled.desc }
ent-CrateVendingMachineRestockCircuitVend = { ent-CrateVendingMachineRestockCircuitVendFilled }
.desc = { ent-CrateVendingMachineRestockCircuitVendFilled.desc }
ent-CrateVendingMachineRestockFlatpackVend = { ent-CrateVendingMachineRestockFlatpackVendFilled }
.desc = { ent-CrateVendingMachineRestockFlatpackVendFilled.desc }
ent-CrateVendingMachineRestockCuddlyCritterVend = { ent-CrateVendingMachineRestockCuddlyCritterVendFilled }
.desc = { ent-CrateVendingMachineRestockCuddlyCritterVendFilled.desc }
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ ent-CrateVendingMachineRestockAstroVendFilled = AstroVend restock crate
ent-CrateVendingMachineRestockAmmoFilled = Liberation restock crate
.desc = Contains two restock boxes for the Liberation vending machine.
ent-CrateVendingMachineRestockCircuitVendFilled = CircuitVend restock crate
.desc = Contains two restock boxes for a CircuitVend vending machine.
ent-CrateVendingMachineRestockFlatpackVendFilled = FlatpackVend restock crate
.desc = Contains two restock boxes for a FlatpackVend vending machine.
ent-CrateVendingMachineRestockCuddlyCritterVendFilled = CuddlyCritterVend restock crate
.desc = Contains two restock boxes for a CuddlyCritterVend vending machine.
Expand Down
2 changes: 1 addition & 1 deletion Resources/Maps/_NF/Outpost/frontier.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36648,7 +36648,7 @@ entities:
- type: Transform
pos: 49.5,4.5
parent: 2173
- proto: VendingMachineCircuitVend
- proto: VendingMachineFlatpackVend
entities:
- uid: 4469
components:
Expand Down
2 changes: 1 addition & 1 deletion Resources/Maps/_NF/POI/anomalouslab.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10471,7 +10471,7 @@ entities:
parent: 1
- type: Anchorable
delay: 999999
- proto: VendingMachineCircuitVend
- proto: VendingMachineFlatpackVend
entities:
- uid: 318
components:
Expand Down
2 changes: 1 addition & 1 deletion Resources/Maps/_NF/POI/grifty.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5163,7 +5163,7 @@ entities:
- type: Transform
pos: 3.5447173,5.482584
parent: 1
- proto: VendingMachineRestockCircuitVend
- proto: VendingMachineRestockFlatpackVend
entities:
- uid: 626
components:
Expand Down
2 changes: 1 addition & 1 deletion Resources/Maps/_NF/POI/lodge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10028,7 +10028,7 @@ entities:
- type: Transform
pos: 9.5,10.5
parent: 1
- proto: VendingMachineCircuitVend
- proto: VendingMachineFlatpackVend
entities:
- uid: 512
components:
Expand Down
Loading

0 comments on commit 324b290

Please sign in to comment.