Hello guys, i’m having trouble importing assets in my navigator.
I’ve created a 3d card game with 42 cards (each card is a gltf.file 1.6Mo), here is the code
It works once in 10. (when i’m importing only 4 cards it’s perfectly runs).
Would you have some advices to optimize the performance and the loading time?
yes, you right about task name.
I think @Dshah_H is right - load starts running all tasks and you add over 120 observers, where need only 3. Just need move observers from loop?
I did, it’s looks like it’s working better, but it’s still struggling to load 4 pages.
Here is a capture of the memory, the page size is 250Mo. How could I shorten the loading time?
@Arthur_Boulli, why card gltf has that heavy weight? Perhaps heavy geometry or not needed elements?
I think for card will need one mesh, that you can clone and 42+1 texture (simbols and reverse side). And one texture is a half of image, UV can solve it.
In web we must think about content size, as example not load all textures before game. Perhaps will usefull lazy loading, prefetching, .webp, .gzip and etc) for resources. 1.5 Mb is too many just for card model.
Probably gameplay based on card models and model need be heavy-weight? If not - you can optimize content.