#pragma once #include "UI/ViewModels/UiViewCommon.h" /** * The cargo display (requirement U11, DESIGN_UE.md 4.6): the hold as a picture. Order lists the chunks in the order they * arrived ("ferrite", "cobalt", "pearl"); the picture fills cells bottom-up in that order, and while unloading the cells * empty top-down because the list shrinks from the end. */ struct FCargoDisplayModel { int32 Cap = 8; TArray Order; float BioFu = 0.f; float BioCapFu = 4.f; bool bUnloading = false; int32 Used() const { return Order.Num(); } bool IsFull() const { return Cap > 0 && Order.Num() >= Cap; } int32 CountOf(FName Ore) const { int32 N = 0; for (const FName& O : Order) { N += (O == Ore) ? 1 : 0; } return N; } };