Clothing system refactor
This commit is contained in:
@@ -1 +1,20 @@
|
||||
#include "SexToyInstance.h"
|
||||
|
||||
#include "StructUtils/InstancedStruct.h"
|
||||
|
||||
void USexToyInstance::CaptureState(FInstancedStruct& OutState) const
|
||||
{
|
||||
FSexToyInstanceState State;
|
||||
State.bActive = bActive;
|
||||
State.Battery = Battery;
|
||||
OutState.InitializeAs<FSexToyInstanceState>(State);
|
||||
}
|
||||
|
||||
void USexToyInstance::ApplyState(const FInstancedStruct& InState)
|
||||
{
|
||||
if (const FSexToyInstanceState* State = InState.GetPtr<FSexToyInstanceState>())
|
||||
{
|
||||
bActive = State->bActive;
|
||||
Battery = State->Battery;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user