Added variable boobs physics depending on boobs support from clothing

This commit is contained in:
2026-05-31 15:58:54 +03:00
parent f59fa8d948
commit bc98ea274b
16 changed files with 49 additions and 21 deletions
@@ -82,6 +82,24 @@ float UClothingManager::GetEffectiveCoverage(const EBodyPart BodyPart)
return MaxCoverage;
}
float UClothingManager::GetBoobsSupport()
{
const UClothingItemInstance* UnderwearTop = GetSlotClothing(EClothingSlotType::UnderwearTop);
const UClothingItemInstance* Top = GetSlotClothing(EClothingSlotType::Top);
const UClothingItemInstance* Bodysuit = GetSlotClothing(EClothingSlotType::Bodysuit);
TArray<float> TotalSupports;
if (UnderwearTop)
TotalSupports.Push(UnderwearTop->GetClothingItemDefinition()->BoobsSupport);
if (Top)
TotalSupports.Push(Top->GetClothingItemDefinition()->BoobsSupport);
if (Bodysuit)
TotalSupports.Push(Bodysuit->GetClothingItemDefinition()->BoobsSupport);
return FMath::Max(TotalSupports);
}
void UClothingManager::HydrateClothing()
{
USaveSubsystem* SaveSubsystem = UGameplayStatics::GetGameInstance(GetWorld())->GetSubsystem<USaveSubsystem>();