MCPcopy Create free account
hub / github.com/melonjs/melonJS / unloadAll

Function unloadAll

packages/melonjs/src/loader/loader.js:718–813  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

716 * @category Assets
717 */
718export function unloadAll() {
719 let name;
720
721 // unload all binary resources
722 for (name in binList) {
723 if (binList.hasOwnProperty(name)) {
724 unload({
725 name: name,
726 type: "binary",
727 });
728 }
729 }
730
731 // unload all image resources
732 for (name in imgList) {
733 if (imgList.hasOwnProperty(name)) {
734 unload({
735 name: name,
736 type: "image",
737 });
738 }
739 }
740
741 // unload all tmx resources
742 for (name in tmxList) {
743 if (tmxList.hasOwnProperty(name)) {
744 unload({
745 name: name,
746 type: "tmx",
747 });
748 }
749 }
750
751 // unload all json resources
752 for (name in jsonList) {
753 if (jsonList.hasOwnProperty(name)) {
754 unload({
755 name: name,
756 type: "json",
757 });
758 }
759 }
760
761 // unload all video resources
762 for (name in videoList) {
763 if (videoList.hasOwnProperty(name)) {
764 unload({
765 name: name,
766 type: "json",
767 });
768 }
769 }
770
771 // unload all video resources
772 for (name in fontList) {
773 if (fontList.hasOwnProperty(name)) {
774 unload({
775 name: name,

Callers

nothing calls this directly

Calls 1

unloadFunction · 0.70

Tested by

no test coverage detected