I came across this problem a few months ago, and asked the MTE boards and people avoided it It’s a very deep question, and the conclusion is a bit painful. Now i’m gonna assume you have display objects being used in Tiled editor that are called in the program? When I wrote my code I would automatically try to clean out objects when I changed maps or when they are not being used as common practice and the MTE engine since you are using cleanup tries to do the same thing.
When I looked into the MTE engine I believe the cleanup tries to clean everything up but there is also a cleanup part in the map loading function which is doing a double cleanup causing problems? There is also another cleanup part for a different map part in the code…anyways I started to clean everything up manually myself as common practice and commented out the map function cleaning parts in the game engine and I haven’t gotten any problems ever since ( no errors ) . I believe I still use cleanup function from MTE before I change scenes as it does the normal map itself part, I just don’t let it do the objects of it anymore. I came to this conclusion after narrowing it down to any object on the map from Tiled causes this error when only changing scenes.
I came across this problem a few months ago, and asked the MTE boards and people avoided it It’s a very deep question, and the conclusion is a bit painful. Now i’m gonna assume you have display objects being used in Tiled editor that are called in the program? When I wrote my code I would automatically try to clean out objects when I changed maps or when they are not being used as common practice and the MTE engine since you are using cleanup tries to do the same thing.
When I looked into the MTE engine I believe the cleanup tries to clean everything up but there is also a cleanup part in the map loading function which is doing a double cleanup causing problems? There is also another cleanup part for a different map part in the code…anyways I started to clean everything up manually myself as common practice and commented out the map function cleaning parts in the game engine and I haven’t gotten any problems ever since ( no errors ) . I believe I still use cleanup function from MTE before I change scenes as it does the normal map itself part, I just don’t let it do the objects of it anymore. I came to this conclusion after narrowing it down to any object on the map from Tiled causes this error when only changing scenes.