Page 1 of 1

Img resources loading

Posted: 22 April 2020, 21:53
by Mistergos
Hi there
Once again i am asking for your lights.

I develop a car race games with dozens of track.
Each track is described in a php file located in modules (dozens files in modules prefixed with RGT).
Each track has also a background image located in img width a size of 2Mo each.

My idea was that the user load only 1 track per game. But i see in the network tab of chrome that all my track images are downloaded for each game. Even those that are not required. I have no link to this image neither in php, js or css. It is all made programatically at runtime.
I do not know if this behavior is for development time only.

My question is : How can i prevent downloading of the unused images?

Thank you again for your time

Re: Img resources loading

Posted: 22 April 2020, 22:21
by Een
I think this should answer your question :)
http://en.doc.boardgamearena.com/Game_i ... ge_loading

Re: Img resources loading

Posted: 23 April 2020, 08:45
by Mistergos
Perfect. I did not see this one.
Thanks for your help