ID:1052985
 
(See the best response by Jemai1.)
What I am trying to do right now is come up with a way to store roughly 8000 150x150 jpg images (around 30mb all together) locally on a player's PC without them being stored in the game's resource.

What I want, is to be able to make an image pack, allow players to download this pack separately from the game itself and store them on their own computer and allow the game to reference them using local html addresses .

This is mainly because the game's resource file has already cracked the 100mb mark, I'd rather not add another 30mb to it.

I've already tried just referencing the images using plain html but byond doesn't seem to recognize any images stored on the user's computer except what is in the cache. Is there any way to change that?

I really don't want to store these images on an image hosting site if I don't have to because of the volume of the images.
You'll want to check out client.Export() to push files to the client.

http://www.byond.com/docs/ref/info.html#/client/proc/Export

BYOND won't automatically know if a file is on the computer ... export the files to a specific location and use them from there :)
In response to A.T.H.K
A.T.H.K wrote:
You'll want to check out client.Export() to push files to the client.

http://www.byond.com/docs/ref/info.html#/client/proc/Export

BYOND won't automatically know if a file is on the computer ... export the files to a specific location and use them from there :)

That wouldn't work seeing as how client.Export can only store one file on a player's machine at any given time.

From: http://www.byond.com/docs/ref/info.html#/client/proc/Export

When a file is exported to the player's computer, it replaces any previous file stored by a game with the same world.hub value.
In response to ExPixel
ExPixel wrote:
That wouldn't work seeing as how client.Export can only store one file on a player's machine at any given time.

That makes no sense .. whats the point in Export if you can only export one file...

When a (insinuates more than one) file is exported to the player's computer, it replaces (WHY! that's stupid..) any previous file stored by a game with the same world.hub value.

Have you tried it though? I don't actually have the time.

[edit] sorry phone cut off your text :/ hopefully the reference is just out of date...
Sorry, I guess I didn't explain this well enough. The goal here is to have these image files 100% separate from the game with the game only referencing their location to display them in html windows.

Basically having a Zip file on our forum containing the file tree and images appropriate for the game to work with but stored separately but when placed in the appropriate folder on their PC, would allow the game to recognize them via local html img tags.

I don't want these images running through in-game functions in any way since our main host is already complaining that we're coming close to hitting his bandwidth cap every so often.

The nature of the game means hundreds of players will be viewing a few hundred of these images each, every day on a regular basis.
Well that's not really going to work unless each person saves the files in the specified location then you could possibly do a browse() or link() or shell() to that location, my idea with Export was to make the user download that HTML file from a external host and have it save in that specified location so you could show it easier..
Well if they have to save it in a specified location, that's not really an issue. The problem is that just saving an image as like

C:\GAMEIMAGES\Img0001.jpg

and then using -img src="C:\GAMEIMAGES\Img0001.jpg"- (replacing the -'s with the < and >) to show the image, the game wont display it even if you have that file in that exact location on your PC.
Sorry can you show the code to what you are doing? you can escape special characters using \

so games's would be games\'s
Best response
Resources may be distributed from a website to save bandwidth on the machine hosting the game. Simply zip up the .rsc file, upload it to a web site, and put the URL in the preload_rsc var of the client.
client/preload_rsc = "http://mywebsite.com/resources.zip"

See the reference for more details.
Can't believe I forgot that....