Game crashes when spawning prop with separate .ytd texture dictionary


I am having an issue with my FiveM server where my game crashes when I spawn a prop or load it with a ymap that has a .ydr, .ytyp, and .ytd file. The issue only occurs when the textures are in a separate .ytd texture dictionary. When the textures are embedded in the .ydr file, the game does not crash. For more context, when I load it into codewalker everything seems and works fine with the ydr ytyp and ytd, its just in game that causes the problem.

The size of the .ytd file is just under 500KB so I don’t think texture size is the issue. I have checked the crash log but I am having trouble understanding what the stuff means.

I have tried using all textures with dimensions to the power of 2 and replacing spaces in names with underscore, still have the same issue with same crash message (also it worked with embedded textures in the ydr so this isnt the issue).

Can anyone help me understand why my game is crashing and suggest any potential solutions?

I have attached all relevant files.

Thank you. (1.5 MB)
fxmanifest.lua (56 Bytes)
_manifest.ymf (480 Bytes)
prop_mega_quad_20x20.ydr (19.6 KB)
prop_mega_quad_20x20.ytyp (475 Bytes)
prop_mega_quad_textures+hidr.ytd (463.7 KB)
rainbow.ymap (1.1 KB)