-
-
Notifications
You must be signed in to change notification settings - Fork 324
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
NullReferenceException in Content Pipeline #739
Comments
Ok, I did some digging and debugging and the problem is that I made a tilemap that references multiple tilesets with multiple images. Tiled outputs a little different structure for these cases. The NullReferenceException was caused by the assumption that tileset.Image would always exist, which in my case is not true. The Image is now on the tile. I have tried to fix the code in the content pipeline and it compiles and builds content, but there seems to be a problem when calling LoadContent on the root .tmx. In my test app I get an error like:
That file name concerns me deeply...
My fixes can be seen here: https://github.com/obiwanjacobi/MonoGame.Extended/commit/50badecb71a04da00dc06adb6cf41dce565f1fdb -Sorry, for the mess of changes most of which are whitespace related. I have several housekeeping tools in my VS that sort usings and replace tabs with spaces etc... Any insights or suggestions would be greatly appreciated. |
Tiled software has changed over the years and thus the code has stagnated. I'm having the code move away from the content pipeline all together this summer. In the mean time if come up with a fix a PR would be welcome. |
Any idea why it is trying to load that weird file name ( |
I think it might be a good idea to build an abstraction over the specific Tile Map Editor used. There are a couple and most of them work the same. All you need are deserializers for each specific editor that all generate a common object model... |
Just starting out with MonoGame, MonoGame Extended and Tiled, so...
Trying to setup a parallax tile map in Tiled. Building the content pipeline gives an error. I probably do something weird you're not supposed to do. Is it the space in the file name....?
The tile map file:
The tile set file:
The text was updated successfully, but these errors were encountered: