View Single Post
10/19/15, 05:56 PM   #8
antihax
AddOn Author - Click to view addons
Join Date: Sep 2015
Posts: 23
Originally Posted by dopiate View Post
where are you getting your data?

in what format is it uploaded?

You can ask for quite a bit about a sale and put all that info together (with a separator so you can split it later) and get a fairly useful ID

in my previous post I said I have two routines to remove dupes

I parse a specific savedvariabls file and each sale is put into this format:

Code:
Amazing Deals of Tamriel,Argentum,15,1437713676,150,@Medusanomi,@dOpiate,1:0:1:0
taken as a single string in an array that is fairly unique (yours would be even better since you are rounding the time)

That is the data I need to make my program work.

But if the user deleted their savedvariables and this time it comes back with a slightly different time stamp then I drop that from the string and check for

Code:
Amazing Deals of Tamriel,Argentum,15,150,@Medusanomi,@dOpiate,1:0:1:0
now that's not perfect but what are the chances of seeing that exact string twice? you have guild,item,ppu,total sale amount,seller,buyer,"details"

the "details" are created by this code
Lua Code:
  1. local levelReq = GetItemLinkRequiredLevel(itemLink)
  2.   local vetReq = GetItemLinkRequiredVeteranRank(itemLink)
  3.   local itemQuality = GetItemLinkQuality(itemLink)  
  4.   local itemTrait = GetItemLinkTraitInfo(itemLink)
  5.   return levelReq .. ":" .. vetReq .. ":" .. itemQuality .. ":" .. itemTrait

so you can get a fairly reliable amount of data on a sale to make into some sort of identifier from.

They even added lots of new info into the itemLink with the recent patch.

-d
I just duplicated the same format as MM for the unique identifiers, it is very similar to yours. This should help a bit.