• Welcome to the largest (sim) racing website in the world!
    Blurring the line between real and virtual motorsports.

Problem using string objects when exported as .x files

Discussion in 'Bob's Track Builder' started by nikescar, May 15, 2009.

  1. nikescar


    I've been using BTB for a game I'm making and it's been working great until this problem popped up. For some reason string objects use textures differently than surfaces, terrain, regular objects, etc.

    Here is how the textures are defined in those models:
    Rural Australia\Textures\Ground\Grass\grass_E.dds

    and here is how they are defined in string objects:
    Great Britain (RBR)\Materials\Objects\Block04a_rw\mat0

    Notice the lack of file extension. It should read:
    Great Britain (RBR)\Materials\Objects\Block04a_rw\mat0.jpg
    or so I think.

    Without the extension my content importer cannot assign a content processor to the texture. Also the texture does not load when using DirectX Viewer in the DirectX SDK which leads me to believe it should have an extension.

    I've tried editing the .x file to include the extension using a hex editor but any editing whatsoever of a .x file seems to corrupt it.

    Any ideas?
  2. jharro


    convert the binary xfile to text xfile then edit it.
  3. nikescar


    I should've added that I tried that in my original post. Using DX text and then editing still produces a "Error 1 Could not read the X file. The file is corrupt or invalid. Error code: D3DXFERR_PARSEERROR."
  4. Brendon Pywell

    Brendon Pywell
    Bob's Track Builder

    Thanks for reporting the problem, it'll be fixed in the next release. :giggle:
  5. nikescar


    Well, that's cool. I thought it might be a limitation of the .x format.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.