DataTable error

Caught signal

FItemStruct* UDataTable::FindRow<FItemStruct>(FName, char16_t const*, bool) const Address = 0x18ff0ffdf [/Users/Shared/Epic Games/UE_4.25/Engine/Source/Runtime/Engine/Classes/Engine/DataTable.h, line 197] [in UE4Editor-CLLS-3508.dylib]
UItem::create(int, int, UDataTable*, UObject*) Address = 0x18ff0f507 [/Users//Documents/Unreal Projects/CLLS/Source/CLLS/itemlogic.cpp, line 13] [in UE4Editor-CLLS-3508.dylib]
UCraftingLogic::doneCrafting() Address = 0x18ff0755a [/Users//Documents/Unreal Projects/CLLS/Source/CLLS/CraftingLogic.cpp, line 56] [in UE4Editor-CLLS-3508.dylib]
UCraftingLogic::execdoneCrafting(UObject*, FFrame&, void*) Address = 0x18ff1226e [/Users//Documents/Unreal Projects/CLLS/Intermediate/Build/Mac/UE4Editor/Inc/CLLS/CraftingLogic.gen.cpp, line 131] [in UE4Editor-CLLS-3508.dylib]
UFunction::Invoke(UObject*, FFrame&, void*) Address = 0x102a09bfc (filename not found) [in UE4Editor-CoreUObject.dylib]
UObject::CallFunction(FFrame&, void*, UFunction*) Address = 0x102c4c1e8 (filename not found) [in UE4Editor-CoreUObject.dylib]
UObject::execLetBool(UObject*, FFrame&, void*) Address = 0x102c5b41e (filename not found) [in UE4Editor-CoreUObject.dylib]
ProcessLocalScriptFunction(UObject*, FFrame&, void*) Address = 0x102c4db2f (filename not found) [in UE4Editor-CoreUObject.dylib]
void ProcessScriptFunction<void ()(UObject, FFrame&, void*)>(UObject*, UFunction*, FFrame&, void*, void ()(UObject, FFrame&, void*)) Address = 0x102c4d4a4 (filename not found) [in UE4Editor-CoreUObject.dylib]
ProcessLocalFunction(UObject*, UFunction*, FFrame&, void*) Address = 0x102c4e818 (filename not found) [in UE4Editor-CoreUObject.dylib]
ProcessLocalScriptFunction(UObject*, FFrame&, void*) Address = 0x102c4db2f (filename not found) [in UE4Editor-CoreUObject.dylib]
UFunction::Invoke(UObject*, FFrame&, void*) Address = 0x102a09bfc (filename not found) [in UE4Editor-CoreUObject.dylib]
UObject::ProcessEvent(UFunction*, void*) Address = 0x102c54747 (filename not found) [in UE4Editor-CoreUObject.dylib]
void TScriptDelegate<FWeakObjectPtr>::ProcessDelegate<UObject>(void*) const Address = 0x1120a8723 (filename not found) [in UE4Editor-UMG.dylib]
void TMulticastScriptDelegate<FWeakObjectPtr>::ProcessMulticastDelegate<UObject>(void*) const Address = 0x1120a8581 (filename not found) [in UE4Editor-UMG.dylib]
non-virtual thunk to UListView::OnItemClickedInternal(UObject*) Address = 0x112015c2c (filename not found) [in UE4Editor-UMG.dylib]
ITypedUMGListView<UObject*>::HandleItemClicked(UObject*) Address = 0x1121383e6 (filename not found) [in UE4Editor-UMG.dylib]
TBaseUObjectMethodDelegateInstance<false, UListView, void (UObject*)>::ExecuteIfSafe(UObject*) const Address = 0x112139c86 (filename not found) [in UE4Editor-UMG.dylib]
SObjectTableRow<UObject*>::OnMouseButtonUp(FGeometry const&, FPointerEvent const&) Address = 0x11213c4e8 (filename not found) [in UE4Editor-UMG.dylib]
FSlateApplication::RoutePointerUpEvent(FWidgetPath const&, FPointerEvent const&) Address = 0x10a2a7225 (filename not found) [in UE4Editor-Slate.dylib]
FSlateApplication::ProcessMouseButtonUpEvent(FPointerEvent const&) Address = 0x10a2660e1 (filename not found) [in UE4Editor-Slate.dylib]
FSlateApplication::OnMouseUp(EMouseButtons::Type, FVector2D) Address = 0x10a2b0252 (filename not found) [in UE4Editor-Slate.dylib]
FMacApplication::ProcessMouseUpEvent(FDeferredMacEvent const&, TSharedPtr<FMacWindow, (ESPMode)0>) Address = 0x10a1a6f2a (filename not found) [in UE4Editor-ApplicationCore.dylib]
FMacApplication::ProcessEvent(FDeferredMacEvent const&) Address = 0x10a1a0978 (filename not found) [in UE4Editor-ApplicationCore.dylib]
FMacApplication::ProcessDeferredEvents(float) Address = 0x10a1a06df (filename not found) [in UE4Editor-ApplicationCore.dylib]
FSlateApplication::TickPlatform(float) Address = 0x10a27e518 (filename not found) [in UE4Editor-Slate.dylib]
FSlateApplication::Tick(ESlateTickType) Address = 0x10a27dc72 (filename not found) [in UE4Editor-Slate.dylib]
FEngineLoop::Tick() Address = 0x101280c12 (filename not found) [in UE4Editor]
GuardedMain(char16_t const*) Address = 0x10128a7af (filename not found) [in UE4Editor]
-[UE4AppDelegate runGameThread:] Address = 0x1012a707f (filename not found) [in UE4Editor]
-[FCocoaGameThread main] Address = 0x1017f1931 (filename not found) [in UE4Editor-Core.dylib]
Unknown() Address = 0x7fff36d3b7a2 (filename not found) [in Foundation]
_pthread_start Address = 0x7fff6e8ac109 (filename not found) [in libsystem_pthread.dylib]
thread_start Address = 0x7fff6e8a7b8b (filename not found) [in libsystem_pthread.dylib]

I tried to access a datatable row. This error would make sense if the key was missing, but the thing is, the row I was calling exists. Do any of y’all know what I did wrong?

UPDATE: I think the error might have to do with an inability to access the datatable from C++. How do I access a datatable from c++, or should I switch to using something else to save data?

What’s going on in itemlogic.cpp ?

itemlogic.cpp has a static function that calls the find database row. It works when I pass the datatable from a blueprint.
Here’s the code:

UItem* UItem::create(int iteminitname,int quant,UDataTable* itemsdatatable,UObject* pota) {

UItem* x = NewObject<UItem>(pota);

FItemStruct* structdata = itemsdatatable->FindRow<FItemStruct>(FName(FString::FromInt(iteminitname)),“”);

if(structdata != nullptr)

{

x->id = structdata->id;

x->name = structdata->name;

x->quantity = quant;

x->maxquantity = structdata->maxquantity;

x->isEquipped = false;

x->location = “inventory”;

x->type = structdata->type;

x->slot = structdata->slot;

x->boosts = structdata->boosts;

x->itemImage = structdata->itemImage;

x->description = structdata->description;

x->tags->set(structdata->tags);

}

for(int i = 0; i < structdata->inventoryfunc_array.Num();i++)

{

x->FunctionBinds.Emplace(UFunctionBindings::FunctionBindingConstruct(x,structdata->display_name_strings*,structdata->inventoryfunc_array*,x));

}

return x;

}

Okay, I ran a UE_LOG. The datatable is equal to a null pointer. How do I set it?

You can use FObjectFinder or set a uproperty in derived blueprint