Compare commits
15 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| a5a89443de | |||
| e5583a3b92 | |||
| a89cbbf2c8 | |||
| db848b428f | |||
| 2e78f37d54 | |||
| c1cbe82bcd | |||
| 0aea87dcea | |||
| 385dc543ad | |||
| b309136b5c | |||
| f8a322d5c1 | |||
| 75daf25f1c | |||
| f1b737439d | |||
| 0d976de526 | |||
| 8e6378208c | |||
| 6b2b12cf2a |
@@ -25,6 +25,15 @@ jobs:
|
||||
cd ${{env.SML_DIR}}
|
||||
if ((Test-Path ${{env.SML_DIR}}/Plugins/Wwise) -eq $true){ echo "WWise already Installed Skipping.."; exit 0 }
|
||||
S:/SF/Scripts/wwise-cli.exe integrate-ue --integration-version "2022.1.5.2714" --project "${{env.SML_DIR}}/FactoryGame.uproject"
|
||||
- name: Pull WWise Project
|
||||
run: |
|
||||
cd ${{env.SML_DIR}}/SML_WwiseProject
|
||||
git fetch --all
|
||||
git reset --hard origin/main
|
||||
git lfs fetch --all
|
||||
git lfs pull
|
||||
git lfs checkout
|
||||
copy-item ${{env.SML_DIR}}/SML_WwiseProject/SML-DEV_WwiseProject.wproj ${{env.SML_DIR}}/SML_WwiseProject/SML_WwiseProject.wproj -force
|
||||
- name: "SML Headers"
|
||||
run: |
|
||||
cd S:/SF/Scripts/sml-fixer
|
||||
@@ -68,7 +77,7 @@ jobs:
|
||||
($UPlugin | convertto-json -Depth 100) -replace '\\u0026', '&' | Set-Content ${{env.SML_DIR}}/Mods/${{matrix.value}}/${{matrix.value}}.uplugin
|
||||
echo "Done"
|
||||
CompileEditor:
|
||||
needs: UpdateModUPluginDependencies
|
||||
needs: UpdateUPlugins
|
||||
runs-on: windows-2022
|
||||
outputs:
|
||||
version: ${{steps.getversion.outputs.version}}
|
||||
|
||||
@@ -1,3 +1,25 @@
|
||||
## 1.0.6 (March 06, 2025)
|
||||
- feat: SML Bump
|
||||
- feat: Bump SML
|
||||
|
||||
## 1.0.5 (January 10, 2025)
|
||||
- ci: LFS Changes
|
||||
- ci: wwise project
|
||||
|
||||
## 1.0.4 (December 17, 2024)
|
||||
- feat: Bump sml version
|
||||
- feat: Mod Adapter struct updates
|
||||
|
||||
## 1.0.3 (November 30, 2024)
|
||||
- feat: Changed forms to array
|
||||
|
||||
## 1.0.2 (November 29, 2024)
|
||||
- feat: Item filters
|
||||
- feat: Additional DS Options
|
||||
|
||||
## 1.0.1 (November 25, 2024)
|
||||
|
||||
|
||||
## 1.0.0 (November 25, 2024)
|
||||
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
{
|
||||
"FileVersion": 3,
|
||||
"Version": 1,
|
||||
"VersionName": "1.0.0",
|
||||
"SemVersion": "1.0.0",
|
||||
"VersionName": "1.0.6",
|
||||
"SemVersion": "1.0.6",
|
||||
"FriendlyName": "Refined R&D Api",
|
||||
"Description": "This Lib can be used to create Mod Compatability with Refined R&D Mods",
|
||||
"Category": "Modding",
|
||||
@@ -26,8 +26,8 @@
|
||||
{
|
||||
"Name": "SML",
|
||||
"Enabled": true,
|
||||
"SemVersion": "^3.8.0"
|
||||
"SemVersion": "^3.10.0"
|
||||
}
|
||||
],
|
||||
"GameVersion": ">=377620"
|
||||
"GameVersion": ">=383729"
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
// Fill out your copyright notice in the Description page of Project Settings.
|
||||
|
||||
|
||||
#include "DataAssets/RRDADataAssetDSItemFilter.h"
|
||||
|
||||
@@ -67,6 +67,7 @@ void URRDADataAssetSubsystem::StartScanForDataAssets() {
|
||||
ReCacheGeneratorDataAssets();
|
||||
|
||||
mDSBuildingData.Empty();
|
||||
ReCacheDSItemFilters();
|
||||
ReCacheDSModAdapterDataAssets();
|
||||
ReCacheDSAdapterCoversDataAssets();
|
||||
}
|
||||
@@ -178,6 +179,8 @@ void URRDADataAssetSubsystem::ReCacheDSModAdapterDataAssets() {
|
||||
TSet<URRDADataAssetDSModAdapter*> DataAssets;
|
||||
if (FindAllDataAssetsOfClass(DataAssets)) {
|
||||
for (URRDADataAssetDSModAdapter* DataAsset : DataAssets) {
|
||||
if (DataAsset->mBuildingClass == nullptr) continue;
|
||||
|
||||
FRRDADataHolderDSBuildingData* existingData = mDSBuildingData.Find(DataAsset->mBuildingClass);
|
||||
if (existingData == nullptr) {
|
||||
FRRDADataHolderDSBuildingData newData = FRRDADataHolderDSBuildingData();
|
||||
@@ -197,6 +200,8 @@ void URRDADataAssetSubsystem::ReCacheDSAdapterCoversDataAssets() {
|
||||
TSet<URRDADataAssetDSAdapterCovers*> DataAssets;
|
||||
if (FindAllDataAssetsOfClass(DataAssets)) {
|
||||
for (URRDADataAssetDSAdapterCovers* DataAsset : DataAssets) {
|
||||
if (DataAsset->mBuildingClass == nullptr) continue;
|
||||
|
||||
FRRDADataHolderDSBuildingData* existingData = mDSBuildingData.Find(DataAsset->mBuildingClass);
|
||||
if (existingData == nullptr) {
|
||||
FRRDADataHolderDSBuildingData newData = FRRDADataHolderDSBuildingData();
|
||||
@@ -211,6 +216,26 @@ void URRDADataAssetSubsystem::ReCacheDSAdapterCoversDataAssets() {
|
||||
UE_LOGFMT(LogRRDApi, Log, "ReCacheDSAdapterCoversDataAssets: {0}", mDSBuildingData.Num());
|
||||
}
|
||||
|
||||
void URRDADataAssetSubsystem::ReCacheDSItemFilters() {
|
||||
TSet<URRDADataAssetDSItemFilter*> DataAssets;
|
||||
if (FindAllDataAssetsOfClass(DataAssets)) {
|
||||
for (URRDADataAssetDSItemFilter* DataAsset : DataAssets) {
|
||||
if (DataAsset->mBuildingClass == nullptr) continue;
|
||||
|
||||
FRRDADataHolderDSBuildingData* existingData = mDSBuildingData.Find(DataAsset->mBuildingClass);
|
||||
if (existingData == nullptr) {
|
||||
FRRDADataHolderDSBuildingData newData = FRRDADataHolderDSBuildingData();
|
||||
newData.ItemFilters.AddUnique(DataAsset);
|
||||
mDSBuildingData.Add(DataAsset->mBuildingClass, newData);
|
||||
}
|
||||
else {
|
||||
existingData->ItemFilters.AddUnique(DataAsset);
|
||||
}
|
||||
}
|
||||
}
|
||||
UE_LOGFMT(LogRRDApi, Log, "ReCacheDSItemFilters: {0}", mDSBuildingData.Num());
|
||||
}
|
||||
|
||||
int32 URRDADataAssetSubsystem::GetAllDirtItems(TArray<TSubclassOf<UFGItemDescriptor>>& Items) const {
|
||||
if (!mDirtAssets.Num()) {
|
||||
UE_LOG(LogRRDApi, Error, TEXT("No Dirts found!"));
|
||||
@@ -308,6 +333,27 @@ bool URRDADataAssetSubsystem::HasDSAdaperCoversForBuildingClass(TSubclassOf<AFGB
|
||||
return IsValid(GetDSAdapterCoverDataAssetForBuildingClass(BuildingClass));
|
||||
}
|
||||
|
||||
TArray<URRDADataAssetDSItemFilter*> URRDADataAssetSubsystem::GetDSItemFiltersDataAssetsForBuildingClass(TSubclassOf<AFGBuildableFactory> BuildingClass) const {
|
||||
if (!BuildingClass) return TArray<URRDADataAssetDSItemFilter*>{};
|
||||
|
||||
const FRRDADataHolderDSBuildingData* data = mDSBuildingData.Find(BuildingClass);
|
||||
if (data == nullptr) return TArray<URRDADataAssetDSItemFilter*>{};
|
||||
|
||||
return data->ItemFilters;
|
||||
}
|
||||
|
||||
TArray<URRDADataAssetDSItemFilter*> URRDADataAssetSubsystem::GetAllDSItemFiltersDataAssets() const {
|
||||
TArray<URRDADataAssetDSItemFilter*> Assets;
|
||||
TArray<FRRDADataHolderDSBuildingData> buildingDatas;
|
||||
|
||||
mDSBuildingData.GenerateValueArray(buildingDatas);
|
||||
|
||||
for (FRRDADataHolderDSBuildingData& buildingData : buildingDatas) {
|
||||
Assets.Append(buildingData.ItemFilters);
|
||||
}
|
||||
return Assets;
|
||||
}
|
||||
|
||||
bool URRDADataAssetSubsystem::GetAllTurbineItems(TArray<TSubclassOf<UFGItemDescriptor>>& Items, int32 Tier) const {
|
||||
if (!mTurbineAssets.Contains(Tier)) {
|
||||
return false;
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
// Fill out your copyright notice in the Description page of Project Settings.
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "CoreMinimal.h"
|
||||
#include "DataAssets/RRDADataAssetBase.h"
|
||||
#include "Resources/FGItemDescriptor.h"
|
||||
#include "RRDADataAssetDSItemFilter.generated.h"
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
UCLASS()
|
||||
class REFINEDRDAPI_API URRDADataAssetDSItemFilter : public URRDADataAssetBase
|
||||
{
|
||||
GENERATED_BODY()
|
||||
|
||||
public:
|
||||
/* The Building class this item filter should be used on */
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category="ItemFilter")
|
||||
TSubclassOf<AFGBuildableFactory> mBuildingClass;
|
||||
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category="ItemFilter")
|
||||
int mInventoryIndex = 0;
|
||||
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category="ItemFilter")
|
||||
int mInventorySlotIndex = 0;
|
||||
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category="ItemFilter")
|
||||
TArray<TSubclassOf<UFGItemDescriptor>> mItemFilterClasses;
|
||||
};
|
||||
@@ -8,4 +8,5 @@ enum class ERRDADSInventorySlotAccessInteraction : uint8
|
||||
Ignore,
|
||||
ImportToNetworkFromSlot,
|
||||
ExportFromNetworkToSlot,
|
||||
};
|
||||
LetPlayerDecide,
|
||||
};
|
||||
|
||||
@@ -42,11 +42,11 @@ public:
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly)
|
||||
ERRDADSInventorySlotAccessInteraction mInteraction = ERRDADSInventorySlotAccessInteraction::Ignore;
|
||||
|
||||
/* Select the item resource form that will be displayed in the digital storage UI
|
||||
This will only display items of this form when players search for an item.
|
||||
/* Select the item resource forms that will be displayed in the digital storage UI
|
||||
This will only display items of these forms when players search for an item.
|
||||
*/
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly)
|
||||
EResourceForm mSlotItemForm = EResourceForm::RF_SOLID;
|
||||
TArray<EResourceForm> mSlotItemForms;
|
||||
|
||||
UPROPERTY(BlueprintReadOnly, meta=(NoAutoJson = true))
|
||||
bool mOverrideItemFilter = false;
|
||||
@@ -55,12 +55,20 @@ public:
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, meta=(EditCondition = mOverrideItemFilter))
|
||||
TArray<TSubclassOf<UFGItemDescriptor>> mItemFilter;
|
||||
|
||||
/* Adds only the filtered item from the slot to the Item Selection dropdown. */
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly)
|
||||
bool mCheckSlotItemFilter = false;
|
||||
|
||||
/* Should check if the inventory slot has an Item Filter set
|
||||
This will override the item class that the player selects with the allowed item class on the slot.
|
||||
Also disables item selection in the UI.
|
||||
*/
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly)
|
||||
bool mCheckSlotItemFilter = false;
|
||||
bool mAutomaticallySetFromSlotItemFilter = false;
|
||||
|
||||
/* This slot will represent the full inventory and will access all inventory slots */
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly)
|
||||
bool mSlotRepresentsFullInventory = false;
|
||||
};
|
||||
|
||||
USTRUCT(BlueprintType)
|
||||
@@ -84,4 +92,8 @@ public:
|
||||
/* The Inventory slots to allow access to Digital Storage */
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly)
|
||||
TArray<FRRDADSModAdapterInventorySlotAccess> mInventorySlots;
|
||||
|
||||
/* Use the inventory on the universal adapter instead of the building adapter */
|
||||
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly)
|
||||
bool mUseAdapterInventory = false;
|
||||
};
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#include "DataAssets/RRDAHeaterDataAsset.h"
|
||||
#include "DataAssets/RRDATurbineDataAsset.h"
|
||||
#include "DataAssets/RRDACoolerDataAsset.h"
|
||||
#include "DataAssets/RRDADataAssetDSItemFilter.h"
|
||||
#include "DataAssets/RRDADataAssetDSModAdapter.h"
|
||||
#include "Enums/RRDARPEnums.h"
|
||||
#include "Resources/FGItemDescriptor.h"
|
||||
@@ -66,6 +67,9 @@ struct FRRDADataHolderDSBuildingData
|
||||
|
||||
UPROPERTY()
|
||||
URRDADataAssetDSModAdapter* ModAdapter;
|
||||
|
||||
UPROPERTY()
|
||||
TArray<URRDADataAssetDSItemFilter*> ItemFilters;
|
||||
};
|
||||
|
||||
UCLASS()
|
||||
@@ -98,6 +102,7 @@ public:
|
||||
void ReCacheGeneratorDataAssets();
|
||||
void ReCacheDSModAdapterDataAssets();
|
||||
void ReCacheDSAdapterCoversDataAssets();
|
||||
void ReCacheDSItemFilters();
|
||||
|
||||
public:
|
||||
// Dirt Functions
|
||||
@@ -133,6 +138,14 @@ public:
|
||||
UFUNCTION(BlueprintCallable, Category = "RRDA|DataAsset|DS")
|
||||
bool HasDSAdaperCoversForBuildingClass(TSubclassOf<AFGBuildableFactory> BuildingClass);
|
||||
|
||||
// DS Item Filters
|
||||
|
||||
UFUNCTION(BlueprintCallable, Category = "RRDA|DataAsset|DS")
|
||||
TArray<URRDADataAssetDSItemFilter*> GetDSItemFiltersDataAssetsForBuildingClass(TSubclassOf<AFGBuildableFactory> BuildingClass) const;
|
||||
|
||||
UFUNCTION(BlueprintPure, Category = "RRDA|DataAsset|DS")
|
||||
TArray<URRDADataAssetDSItemFilter*> GetAllDSItemFiltersDataAssets() const;
|
||||
|
||||
// Turbine Functions
|
||||
UFUNCTION(BlueprintPure, Category = "RRDA|DataAsset|RP|MP")
|
||||
bool GetAllTurbineItems(TArray<TSubclassOf<UFGItemDescriptor>>& Items, int32 Tier) const;
|
||||
|
||||
Reference in New Issue
Block a user