• Welcome to SC4 Devotion Forum Archives.

New type of Cleanitol for advanced users?

Started by legoman786, May 12, 2011, 05:23:38 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

legoman786

Hey guys,

I thought of a rather revolutionary new way to keep the plugins folder clean. I've had issues with Cleanitol files regarding that it gets rid of some rather important bats/props/textures/you name it because certain authors needed them gone.

I don't know about you, but I'm sure my folder is chock full of duplicates because of that issue I mentioned above.

Instead of exerting a lot of time and energy into making a friendly Cleanitol file, why not make an advanced Cleanitol that removes dupes based on file hashes?

Don't know what a file hash is? (this explanation is coming from a knowledgeable non-software programmer, so forgive me if I butcher something)

A file hash is like a fingerprint, or DNA, is to a person. Each file has it's own hash, and takes more than changing it's name to separate it from others. And, just like a fingerprint, it can be easily identifiable with the correct tools. Now, if it were to detect a dupe with a different name, there would be a red flag. What kind of red flag? Well, it would ask the user to keep or backup the file, just like the Cleanitol does now. This way, authors who re-upload files that are one and the same in previous uploads, don't need to worry (to a certain extent of course) about people receiving dupes.

Now, as I said, I'm no software developer who plays SC4 on his free time, or other variations of full-time employee.

That's why I come to you, in the sub-folder of the Cleanitol, to maybe pique somebody's interest.


What say ye of SC4D? Is this a feasible road of opportunity? Or a road that leads into the endless pit that is the Black Hole Waste Management Company?

JoeST

File hashes are fragile, and would change every time you saved the file, which would make maintaining cleanitol files rather hard. It would probably be a lot easier and more accurate to just parse each file for duplicate TGI's. Since the game only uses the last (first?) of the duplicates, and I think dat-packer does the same.
Copperminds and Cuddleswarms

Lowkee33

@Joe: The last.  Thats how we override SimCity.Dat.

Totally agree with Joe here.  Datapacker will tell you when files have conflicting data, it will say "file superseded".  In most cases, I think you would be safe removing the smaller of the two files.  Otherwise the files are mods, and should probably be more organized, but they don't take much space anyway.

legoman786

Using a mixture of the DatPacker and Clone Cleaner (Lite version is free), I've managed to find (and remove) 40+ dupes.


A lot less than I was anticipating, but hey... Reduced the size of my plugins folder AND SC4 loads a lot quicker.

JoeST

you dont even need this 'Clone Cleaner' thing, DatPacker will remove all duplicates.
Copperminds and Cuddleswarms