Skip to content

Commit

Permalink
map search fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Eruyome committed Dec 11, 2017
1 parent 37e8162 commit 7bf881f
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 5 deletions.
Binary file modified Fallback.exe
Binary file not shown.
4 changes: 4 additions & 0 deletions resources/Updates_Trade.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
The following is a list of what has been updated, starting with 1.1.0

2.6.3
================================================================================================
Fixed an issue that caused the new maps not being searched correctly.

2.6.2
================================================================================================
Added the new mods available on poe.trade.
Expand Down
2 changes: 1 addition & 1 deletion resources/VersionTrade.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
TradeReleaseVersion := "v2.6.2"
TradeReleaseVersion := "v2.6.3"
TradeAHKVersionRequired := "1.1.26.00"
21 changes: 17 additions & 4 deletions resources/ahk/TradeMacro.ahk
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,13 @@ TradeFunc_Main(openSearchInBrowser = false, isAdvancedPriceCheck = false, isAdva
Item.xtype := ""
Item.UsedInSearch := {}
Item.UsedInSearch.iLvl := {}
For key, val in Item.UsedInSearch {
If (isObject(val)) {
Item[key] := {}
} Else {
Item[key] :=
}
}

RequestParams := new RequestParams_()
RequestParams.league := LeagueName
Expand Down Expand Up @@ -638,17 +645,19 @@ TradeFunc_Main(openSearchInBrowser = false, isAdvancedPriceCheck = false, isAdva

If (Item.IsMap) {
; add Item.subtype to make sure to only find maps
If (not RegExMatch(Item.Name, "i)The Beachhead.*", isHarbingerMap)) {
RegExMatch(Item.Name, "i)The Beachhead.*", isHarbingerMap)
RegExMatch(Item.SubType, "i)Unknown Map", isUnknownMap)
If (not isHarbingerMap and not isUnknownMap) {
RequestParams.xbase := Item.SubType
} Else {
RequestParams.xbase := ""
}

RequestParams.xtype := ""
If (not Item.IsUnique) {
console.log(isHarbingerMap)
If (StrLen(isHarbingerMap)) {
; Beachhead Map workaround (unique but not flagged as such on poe.trade)
RequestParams.name := Item.Name
RequestParams.name := Item.Name
} Else {
RequestParams.name := ""
}
Expand All @@ -658,6 +667,11 @@ TradeFunc_Main(openSearchInBrowser = false, isAdvancedPriceCheck = false, isAdva
If (InStr(Name, "Ivory Temple")){
RequestParams.xbase := "Ivory Temple Map"
}

If (StrLen(isUnknownMap)) {
RequestParams.xbase := Item.BaseName
Item.UsedInSearch.type := Item.BaseName
}
}

; handle gems
Expand Down Expand Up @@ -748,7 +762,6 @@ TradeFunc_Main(openSearchInBrowser = false, isAdvancedPriceCheck = false, isAdva
If (TradeOpts.Debug) {
;console.log(RequestParams)
}

Payload := RequestParams.ToPayload()

If (openSearchInBrowser) {
Expand Down

0 comments on commit 7bf881f

Please sign in to comment.