Fix missing asset register for new json resources
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
#include "Engine/Platform/FileSystem.h"
|
||||
#include "Engine/Content/Content.h"
|
||||
#include "Engine/Content/Storage/JsonStorageProxy.h"
|
||||
#include "Engine/Content/Cache/AssetsCache.h"
|
||||
#include "Engine/Content/AssetReference.h"
|
||||
#include "Engine/Serialization/JsonWriters.h"
|
||||
#include "Engine/Localization/LocalizedStringTable.h"
|
||||
@@ -54,7 +55,7 @@ bool CreateJson::Create(const StringView& path, StringAnsiView& data, StringAnsi
|
||||
LOG(Warning, "Failed to create directory");
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
rapidjson_flax::StringBuffer buffer;
|
||||
@@ -91,6 +92,10 @@ bool CreateJson::Create(const StringView& path, StringAnsiView& data, StringAnsi
|
||||
{
|
||||
asset->Reload();
|
||||
}
|
||||
else
|
||||
{
|
||||
Content::GetRegistry()->RegisterAsset(id, String(dataTypename), path);
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user