Skip to content

Known Bugs with UDataTableManaged #2

Description

@RyoTune

Issue for tracking any known bugs in UDataTableManaged.

Enumerator/general element count of rows is 0, larger than it should be, or causes crashes when accessed.

Tried replacing the existing UDataTableWrapper with the current UDataTableManaged, but even just the light UDataTable logging causes the issues mentioned. Tested on P3R and Clair Obscur.

if (Mod.Config.LogTablesEnabled)
{
    Log.Information($"{nameof(UDataTable_HandleDataTableChanged)} || Table: {table.Name} || Struct: {table.RowStructName}");

    var numRows = 0;
    foreach (var row in table.Values)
    {
        if (numRows < 5)
        {
            Log.Information($"\t{row.Value->NamePrivate}");
        }
        else if (numRows == 5)
        {
            Log.Information($"\t...with {table.Count - numRows} more.");
        }
        else
        {
            break;
        }

        numRows++;
    }
}

The enumerator implementation seems correct so I think it's likely something in the new related TMap types.

Accessing table rows through TryGetValue(FName) on UE 5.4.4 (Clair Obscur) fails.

Could be related to the above issue. Could also be that the current FName creation ends up creating a new new FName, instead of the existing one created by the date table/engine.

What's strange is that it worked fine in my original quick test. Clair Obscur has since updated, so maybe the pattern needs to be updated and is matching junk currently.

Adding new rows on UE 5.4.4 (Clair Obscur) currently crashes/likely doesn't work correctly when it doesn't crash.

Rirurin mentioned the layout is the same between UE 4.27.2 (P3R) where it was tested and UE 5.4.4, so the issue is unclear. Maybe some alignment or padding difference?

Issue: #1 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions