News:

A forum for users of LackeyCCG

Main Menu

Checking for updated card images?

Started by snowdrop, August 01, 2011, 01:28:41 AM

Previous topic - Next topic

snowdrop

What would be the best/recommended way to make Lackey check if any of the card images have changed and need updating? (This will happen often while we playtest..)

From what I can figure it is not any of the CardURLFiles / CardImageURLs / CardGeneralURLs methods, as they don't use checksums? At the same time it is also explicetly stated that:

Quote
"In summation, the checksummed file list is a way Lackey knows where to get a file from, if it needs to get that file (or if the one it has locally is up to date), and where to save the file to if it downloads. You can use this to install any files into a person's Lackey folder, but you should NOT use this method for the actual card image files because those are handled specially in the 3rd section. "

So, that leaves no way? And while we're on it: Why should one keep away from image hashes?

Trevor

You can use a checksum and treat card images as regular files, but doing so is usually a bad idea. If your plugin has 5000 cards, every time you tried to update the plugin, or even checked to see if there were any updates, Lackey would need to scan 5000+ files. That takes a long time, and there's no great way around it.

Generally, card images aren't changed often, or ever once uploaded, so the standard non checksum way is best.

But there are several solutions to your case of rapid image updating. You can:

1. Simply delete all image folders (or selected folders) in the sets/setimages/ folder, except for general/.

2. Change the image file names in the card data file, thus forcing them to redownload. Note the remote file names need not have anything to do with the files names that they are saved locally as. Refer to http://lackeyccg.com/tutorialplugin.html#updatelist

3. You can treat all card images as regular files and give them checksums.

4. You can zip your plugin and just have people download an exact copy.

5. You can tell people which card images they should manually delete.

and some other ways too.

snowdrop

Thanks for the swift reply & support Trevor. :)

Quote from: Trevor on August 01, 2011, 04:55:28 AM
You can use a checksum and treat card images as regular files, but doing so is usually a bad idea. If your plugin has 5000 cards, every time you tried to update the plugin, or even checked to see if there were any updates, Lackey would need to scan 5000+ files. That takes a long time, and there's no great way around it.

Generally, card images aren't changed often, or ever once uploaded, so the standard non checksum way is best.

I suspected as much...  ::) You're correct of course that  the images hardly ever change in conventional games due to companies not releasing re-prints of revised cards every time they update them.


QuoteChange the image file names in the card data file, thus forcing them to redownload. Note the remote file names need not have anything to do with the files names that they are saved locally as. Refer to http://lackeyccg.com/tutorialplugin.html#updatelist

Think that's the most appealing solution for now.

Thanks again. :)