2024-04-24 13:21:22 -07:00
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "GasaCommon.h"
|
|
|
|
|
|
2024-04-26 17:08:08 -07:00
|
|
|
|
template<typename RowType>
|
|
|
|
|
inline
|
|
|
|
|
RowType* GetDataTableRowByTag(UDataTable* DT, FGameplayTag& Tag)
|
|
|
|
|
{
|
|
|
|
|
RowType* Row = DT->FindRow<RowType>(Tag.GetTagName(), TEXT(""));
|
|
|
|
|
return Row;
|
|
|
|
|
}
|
|
|
|
|
|
2024-04-24 13:21:22 -07:00
|
|
|
|
template<typename KeyType, typename ValueType>
|
|
|
|
|
inline
|
|
|
|
|
void RemoveKeys(TMap<KeyType, ValueType> Map, TArray<KeyType> Keys)
|
|
|
|
|
{
|
|
|
|
|
for (KeyType& Key : Keys )
|
|
|
|
|
{
|
|
|
|
|
Map.Remove(Key);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|