mirror of
https://github.com/Milxnor/Project-Reboot-3.0.git
synced 2026-01-13 19:02:21 +01:00
a bit
proper vending machines like fully, performance
This commit is contained in:
@@ -14,7 +14,7 @@ void FFortItemEntry::SetStateValue(EFortItemEntryState StateType, int IntValue)
|
||||
}
|
||||
}
|
||||
|
||||
auto idx = GetStateValues().AddUnitialized2(FFortItemEntryStateValue::GetStructSize());
|
||||
auto idx = GetStateValues().AddUninitialized2(FFortItemEntryStateValue::GetStructSize()); // AddUninitialized?
|
||||
|
||||
GetStateValues().AtPtr(idx, FFortItemEntryStateValue::GetStructSize())->GetIntValue() = IntValue;
|
||||
GetStateValues().AtPtr(idx, FFortItemEntryStateValue::GetStructSize())->GetStateType() = StateType;
|
||||
@@ -27,7 +27,6 @@ void FFortItemEntry::SetStateValue(EFortItemEntryState StateType, int IntValue)
|
||||
|
||||
FFortItemEntry* FFortItemEntry::MakeItemEntry(UFortItemDefinition* ItemDefinition, int Count, int LoadedAmmo, float Durability)
|
||||
{
|
||||
bool bUseFMemoryRealloc = false; // I don't think this works because sometimes we don't free it (oops).
|
||||
auto Entry = Alloc<FFortItemEntry>(GetStructSize(), bUseFMemoryRealloc);
|
||||
|
||||
if (!Entry)
|
||||
|
||||
Reference in New Issue
Block a user