gavvic Posted September 27, 2015 Share Posted September 27, 2015 Hello all, I was wondering if anyone has any working examples of how the dynamic loader functions in the new version. I've been trying to load a JSON file that contains paths to my assets and, in reading through that JSON, add those on the assetQueue. Is this possible? Quote Link to comment Share on other sites More sharing options...
Ninjadoodle Posted October 5, 2015 Share Posted October 5, 2015 I posted a similar question in the 2.0 thread. I can load assets, but can't seem to unload them when needed. Quote Link to comment Share on other sites More sharing options...
gavvic Posted October 6, 2015 Author Share Posted October 6, 2015 Hey @Ninjadoodle, How did you manage to dynamically load and access the assets? I was able to load my JSON (not through the dynamic loader), but after going through the JSON to retrieve the image paths and dynamically add them to the loader, I wasn't able to even create the sprites despite the assetQueue being empty (which I assumed meant that the assets were loaded). Similarly, when I tried the same method from the playground environment (same code and all for testing), that didn't work either. Thanks. Quote Link to comment Share on other sites More sharing options...
Ninjadoodle Posted October 8, 2015 Share Posted October 8, 2015 Hi @gavvic All i'm doing to start the loader is this ...game.addAsset('atlas1.json');game.addAsset('atlas2.json');var loader = new game.Loader('stage02');loader.start();This seems to load the assets and go to the next scene. In Panda 1.xx however, I could remove single graphics ... I'm not sure how to remove atlases, or whether it's implemented in 2.0. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.