Comments (5)
I'll see if I can find a solution all the same :)
from sfml-tmxloader.
Solution found --- add the line:
m_tileInfo.clear();
to MapLoader::m_Unload() in MapLoaderPrivate.cpp
from sfml-tmxloader.
Ah. I haven't tried it, but I'm figuring there's something not being cleared, such as m_tileInfo, which should be in m_Unload() (that's the first place I'd look anyway). I feel I should point out, however, that if you want the state between different maps to persist between transitions then you should load them into their own instances of the map loader eg
MapLoader ml1(path), ml2(path);
ml1.load("interior.tmx");
ml2.load("exterior.tmx");
EDIT beat me to it :)
from sfml-tmxloader.
That's a good point --- you could probably implement persistence by using a stack internally? (alternatively, I could do it by using a stack of MapLoaders)
from sfml-tmxloader.
It's an interesting idea. I may add it, but if I do it won't be any time soon. Contributions are always welcome though ;)
from sfml-tmxloader.
Related Issues (20)
- Thanks Matt! HOT 3
- No compatibility with AnimatedSprite class? HOT 2
- MapObject setVisible ? HOT 3
- Terrain Tiled tmx load HOT 3
- Strange culling HOT 4
- Collision issues HOT 7
- Animated Tile with Tiled Editor HOT 4
- layer->tiles doesn't give tiles from layers HOT 3
- GetLayers() doesn't work as spected HOT 4
- Simple test fails: call for help
- Unresolved external symbol HOT 12
- Can't draw map properly if it wasn't the the first one the maploader loaded. HOT 4
- Colission with player sprite HOT 6
- Collisions detected incorrectly due to AABB having incorrect height (2x what it should be) HOT 1
- Isometric causing weird issues HOT 5
- unresolved symbol sf::Sprite::Draw in MapLoaderPublic.obj? HOT 1
- Isometric Layering offset not happening? HOT 22
- Missing vtable HOT 3
- Can not build tmxsfml project as I've set link options correctly HOT 1
- Doesn't build woth MinGW Makefiles HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sfml-tmxloader.