Table Row as reference rather than referenced by name?

Is it possible to reference a specific row from a DataTable inside an Actor or Object as a direct reference to specific row rather than by table row name?

From experience there seems to be a lot of errors by designers and other people who are creating objects where either the row name changes or is deleted and then there are issues that are not overly difficult to track and fix but its extra work that is annoying.

Our process issue aside is there a way to hard reference a row in another actor / object or is name reference the only way?

1 Like

Yup.

Use this:

#include "Classes/Engine/DataTable.h"

// ItemID TO spawn
UPROPERTY(EditAnyWhere, BlueprintReadWrite, Category = "Item Spawner")
FDataTableRowHandle ItemToSpawn;

Then designer should select datatable first then all rows from that datatable would be in the dropdown menu ^^

PS: Changing row names would be still an issue because if row referenced somewhere else but row name changed in the datatable reference is nulled out, because of invalid row name… so must be set again

1 Like

Yep this will work for now thanks.