thirdy / durian

Path of Exile Items watcher
http://thirdy.github.io/durian/
GNU General Public License v2.0
35 stars 10 forks source link

Add an option to not alert when results are not the same upon finishing Automated search #25

Closed thirdy closed 8 years ago

thirdy commented 8 years ago

suggested by Morsexier in his twitch channel

thirdy commented 8 years ago

implemented, config key is:

automated.search.notify.newonly
thirdy commented 8 years ago

Reopening as the current way of determining an item is new or not can be improved.

Right now it's (thread-id + name + buyout). I think all the mods and stats should be included as well. For example, an item that was pure but corrupted.

thirdy commented 8 years ago

done, the formula is now this:

        public int toUUID() {
            String explicitModsUUID = explicitMods.stream().map(Mod::toUUID).collect(Collectors.joining(":"));
            String implicitModuuid = implicitMod != null ? implicitMod.toUUID() : null;
            List<String> uuidList = asList(thread, name, buyout, String.valueOf(corrupted), socketsRaw, quality, 
                    physDmgRangeAtMaxQuality, physDmgAtMaxQuality, eleDmgRange, attackSpeed, dmgAtMaxQuality, crit, level, eleDmg,
                    armourAtMaxQuality, evasionAtMaxQuality, energyShieldAtMaxQuality, block, mapQuantity, implicitModuuid, explicitModsUUID);
            String uuid = uuidList.stream().collect(Collectors.joining(":"));
            return Integer.valueOf(uuid.hashCode());
        }