New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error Initializing Texture - File Doesn't Exist #8
Comments
Hi there, could you provide your level file and texture folder? |
This looks to be because the 'content root folder' doesn't have a trailing back-slash, so .NET is assuming it's a file and not a folder. I'll fix this so that it forces the trailing slash. |
This should now be fixed. Please let me know if you're still having issues with it. |
I'm closing this, but do let me know if there's still an issue |
Looks to be resolved. Thanks! |
I encountered an issue on load where textures would not properly initialize. It seems that after the error messages all go away (once for every single texture in the level) the textures seem to load ok but its very annoying. This issue also crops up upon placing textures within the level.
From what I can tell via debugging and the error provided is that this is an issue of the texture item's relative path also containing the parent folder.
For Example:
Content Root Folder: C:\Project\Content
Content Root Folder contains a sub folder called "Sprites" and as such texture item's relative path should be: Sprites/file.ext
Error message states it can't find the file: C:\Project\Content\Content\Spites\file.ext (notice the duplicate entry for "Content")
In debugging I was able to find that within the initialiseTexture method of the TextureItemEditor.cs file, the parameter textureFileName was "Content\Sprites\file.ext" - I traced this up a few steps and found it came from some properties collections and got nervous about changing anything much further and decided to post my findings here.
The text was updated successfully, but these errors were encountered: