Skip to content

Commit

Permalink
v1.56.3 BETA merge
Browse files Browse the repository at this point in the history
- still beta, poe 1 and 2 changes
- map-tracker: streamlined kill-tracking, improved poe2 support
- item-info: re-enabled for uniques in poe2 to check dps
  • Loading branch information
Lailloken authored Dec 23, 2024
2 parents 6875bd2 + 188c1b6 commit f36df9e
Show file tree
Hide file tree
Showing 15 changed files with 77 additions and 144 deletions.
7 changes: 3 additions & 4 deletions Lailloken UI.ahk
Original file line number Diff line number Diff line change
Expand Up @@ -298,11 +298,11 @@ Init_client()
Sleep, 2000
}
WinGetPos, x, y, w, h, ahk_group poe_window
Gui, Test: New, -DPIScale +LastFound +AlwaysOnTop +ToolWindow -Caption
Gui, Screen_Test: New, -DPIScale +LastFound +AlwaysOnTop +ToolWindow -Caption
WinSet, Trans, 0
Gui, Test: Show, % "NA x" x + w//2 " y" y + h//2 " Maximize"
Gui, Screen_Test: Show, % "NA x" x + w//2 " y" y + h//2 " Maximize"
WinGetPos, xScreenOffset_monitor, yScreenOffSet_monitor, width_native, height_native
Gui, Test: Destroy
Gui, Screen_Test: Destroy
;WinGetPos, x, y, w, h, ahk_class Shell_TrayWnd
vars.monitor := {"x": xScreenOffset_monitor, "y": yScreenOffSet_monitor, "w": width_native, "h": height_native, "xc": xScreenOffset_monitor + width_native / 2, "yc": yScreenOffSet_monitor + height_native / 2}
LLK_Log("measured monitor resolution and position: " width_native "x" height_native ", " xScreenOffset_monitor ", " yScreenOffSet_monitor)
Expand Down Expand Up @@ -1045,7 +1045,6 @@ Loop_main()
vars.general.inactive := 0
LLK_Overlay("show")
}

Leveltracker_Fade()
location := vars.log.areaID ;short-cut variable
If (vars.cloneframes.enabled
Expand Down
6 changes: 6 additions & 0 deletions data/changelog.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
[
[
["1.56.3", 15603],
"still beta, poe 1 and 2 changes",
"map-tracker: streamlined kill-tracking, improved poe2 support",
"item-info: re-enabled for uniques in poe2 to check dps"
],
[
["1.56.2", 15602],
"still beta, mainly poe2 changes",
Expand Down
8 changes: 6 additions & 2 deletions data/english/help tooltips.json
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@
"click a box to open the color-palette, right click to reset"
],
"iteminfo marking class": [
"colors used to highlight class-specificly (un)desired mods",
"colors used to highlight class-specifically (un)desired mods",
"click a box to open the color-palette, right click to reset"
],
"iteminfo item-tier": [
Expand Down Expand Up @@ -388,7 +388,11 @@
],
"maptracker rename": [
"tags and renames boss maps for easier searching",
"example: <boss: elder> instead of <absence of value and meaning>"
"example:\n<boss: elder> instead of <absence of value and meaning>"
],
"maptracker rename 2": [
"tags and renames boss maps for easier searching",
"example:\n<boss: xesht> instead of <twisted domain (boss)>"
],
"maptracker character": [
"your character's name, class, and level will be logged",
Expand Down
2 changes: 1 addition & 1 deletion data/english/map-info 2.txt
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ ID = 044

[Monsters fire additional Projectiles]
type = monsters
text = extra proj: +%
text = extra proj: +
ID = 045

[Monsters have increased Area of Effect]
Expand Down
2 changes: 1 addition & 1 deletion data/versions.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"_release": [15602, "https://github.com/Lailloken/Lailloken-UI/archive/refs/heads/main.zip"]
"_release": [15603, "https://github.com/Lailloken/Lailloken-UI/archive/refs/heads/main.zip"]
}
70 changes: 0 additions & 70 deletions modules/GUI.ahk
Original file line number Diff line number Diff line change
Expand Up @@ -769,76 +769,6 @@ RGB_Picker(RGB := "")
Return picked_rgb
}

/*
RGB_Picker(current_rgb := "")
{
local
global vars, settings
static palette
If !palette
{
palette := []
palette.Push(["330000", "660000", "990000", "CC0000", "FF0000", "FF3333", "FF6666", "FF9999", "FFCCCC"])
palette.Push(["331900", "663300", "994C00", "CC6600", "FF8000", "FF9933", "FFB266", "FFCC99", "FFE5CC"])
palette.Push(["333300", "666600", "999900", "CCCC00", "FFFF00", "FFFF33", "FFFF66", "FFFF99", "FFFFCC"])
palette.Push(["193300", "336600", "4C9900", "66CC00", "80FF00", "99FF33", "B2FF66", "CCFF99", "E5FFCC"])
palette.Push(["003300", "006600", "009900", "00CC00", "00FF00", "33FF33", "66FF66", "99FF99", "CCFFCC"])
palette.Push(["003319", "006633", "00994C", "00CC66", "00FF80", "33FF99", "66FFB2", "99FFCC", "CCFFE5"])
palette.Push(["003333", "006666", "009999", "00CCCC", "00FFFF", "33FFFF", "66FFFF", "99FFFF", "CCFFFF"])
palette.Push(["001933", "003366", "004C99", "0066CC", "0080FF", "3399FF", "66B2FF", "99CCFF", "CCE5FF"])
palette.Push(["000033", "000066", "000099", "0000CC", "0000FF", "3333FF", "6666FF", "9999FF", "CCCCFF"])
palette.Push(["190033", "330066", "4C0099", "6600CC", "7F00FF", "9933FF", "B266FF", "CC99FF", "E5CCFF"])
palette.Push(["330033", "660066", "990099", "CC00CC", "FF00FF", "FF33FF", "FF66FF", "FF99FF", "FFCCFF"])
palette.Push(["330019", "660033", "99004C", "CC0066", "FF007F", "FF3399", "FF66B2", "FF99CC", "FFCCE5"])
palette.Push(["000000", "202020", "404040", "606060", "808080", "A0A0A0", "C0C0C0", "E0E0E0", "FFFFFF"])
}
hwnd_GUI := {}
Gui, RGB_palette: New, -Caption -DPIScale +LastFound +ToolWindow +AlwaysOnTop +Border HWNDhwnd +E0x02000000 +E0x00080000 HWNDhwnd_palette
Gui, RGB_palette: Color, Black
Gui, RGB_palette: Font, % "s" settings.general.fSize, % vars.system.font
Gui, RGB_palette: Margin, % settings.general.fWidth, % settings.general.fWidth
For index0, val0 in palette
For index, val in val0
{
style := (A_Index = 1) ? "Section " (index0 != 1 ? "ys x+-1" : "") : "xs y+" (LLK_IsBetween(index, 5, 6) ? settings.general.fWidth / 5 : -1), columns := index0
If (current_rgb = val)
{
Gui, RGB_palette: Add, Text, % style " Center 0x200 BackgroundTrans w" settings.general.fWidth * 2 " h" settings.general.fWidth * 2 " c" (index >= 5 ? "Black" : "White"), X
style := "xp yp"
}
Gui, RGB_palette: Add, Progress, % style " Disabled BackgroundBlack c" val " w" settings.general.fWidth * 2 " h" settings.general.fWidth * 2 " HWNDhwnd", 100
hwnd_GUI[hwnd] := val
}
Gui, RGB_palette: Show, % "NA x10000 y10000"
WinGetPos,,, w, h, ahk_id %hwnd_palette%
xPos := vars.general.xMouse - (vars.general.xMouse - vars.monitor.x + w >= vars.monitor.w ? w - settings.general.fWidth : settings.general.fWidth)
yPos := vars.general.yMouse - (vars.general.yMouse - vars.monitor.y + h >= vars.monitor.h ? h - settings.general.fWidth : settings.general.fWidth)
KeyWait, LButton
Gui, RGB_palette: Show, % "x" xPos " y" yPos
While (vars.general.wMouse != hwnd_palette) && !timeout
{
If !start
start := A_TickCount
If (A_TickCount >= start + 1000) && (vars.general.wMouse != hwnd_palette)
timeout := 1
Sleep 10
}
While Blank(picked_rgb) && (vars.general.wMouse = hwnd_palette)
{
If hwnd_GUI.HasKey(vars.general.cMouse) && (hover_last != vars.general.cMouse)
hover_last := vars.general.cMouse
Else hover_last := ""
If GetKeyState("LButton", "P")
picked_rgb := hwnd_GUI[hover_last]
Sleep 10
}
KeyWait, LButton
Gui, RGB_palette: Destroy
Return picked_rgb
}
*/

ToolTip_Mouse(mode := "", timeout := 0)
{
local
Expand Down
26 changes: 19 additions & 7 deletions modules/client log.ahk
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,7 @@
Loop, Parse, % vars.log.parsing, `,, %A_Space%
If Blank(vars.log[A_LoopField]) && !Blank(%A_LoopField%)
vars.log[A_LoopField] := %A_LoopField%
If vars.poe_version && Blank(vars.log.areaname) && !Blank(areaID)
vars.log.areaname := Log_Get(areaID, "areaname")

vars.log.level := !vars.log.level ? 0 : vars.log.level, settings.general.lang_client := settings.general.lang_client ? settings.general.lang_client : "unknown"
If !mode
vars.log.access_time := A_TickCount - start
Expand Down Expand Up @@ -208,15 +207,27 @@ Log_FindLines(log_array, data)
Log_Get(log_text, data)
{
local

global vars, settings

If (data = "areaname")
If !LLK_StringCompare(log_text, ["map"])
If !LLK_StringCompare(log_text, ["map", "breach"])
%data% := log_text
Else
{
If RegExMatch(log_text, "Hideout.*_Claimable")
If LLK_StringCompare(log_text, ["breach"])
{
If settings.maptracker.rename
Return "boss: xesht"
Else Return "twisted domain (boss)"
}
Else If RegExMatch(log_text, "Hideout.*_Claimable")
Return LLK_StringCase(StrReplace(StrReplace(log_text, "_claimable"), "maphideout") . " hideout")
%data% := StrReplace(SubStr(log_text, 4), "_noboss") . (!InStr(log_text, "_noboss") && !InStr(log_text, "unique") && !InStr(log_text, "losttowers") ? " (boss)" : "")
%data% := StrReplace(SubStr(log_text, 4), "_noboss")
If InStr(%data%, "uberboss_")
%data% := (settings.maptracker.rename ? "boss:" : "") . StrReplace(%data%, "uberboss_") . (settings.maptracker.rename ? "" : " (boss)")
Else If LLK_StringCompare(%data%, ["unique"])
%data% := "unique:" (InStr(%data%, "merchant") ? " nameless seer" : SubStr(%data%, 7))
Else %data% .= (!InStr(log_text, "_noboss") && !InStr(log_text, "unique") && !InStr(log_text, "losttowers") ? " (boss)" : "")
Loop, Parse, % %data%
%data% := (A_Index = 1) ? "" : %data%, %data% .= (A_Index != 1 && RegExMatch(A_LoopField, "[A-Z]") ? " " : "") . A_LoopField
}
Expand Down Expand Up @@ -394,10 +405,11 @@ Log_Parse(content, ByRef areaID, ByRef areaname, ByRef areaseed, ByRef arealevel
parse := SubStr(loopfield, InStr(loopfield, vars.lang.log_killed.1)), parse := Lang_Trim(parse, vars.lang.log_killed)
Loop, Parse, parse
parse := (A_Index = 1) ? "" : parse, parse .= IsNumber(A_LoopField) ? A_LoopField : ""

If (vars.maptracker.refresh_kills = 1)
vars.maptracker.map.kills := [parse], LLK_ToolTip(Lang_Trans("maptracker_kills", 2),,,,, "Lime"), vars.tooltip_mouse := "", vars.maptracker.refresh_kills := 2
Else If (vars.maptracker.refresh_kills > 1) && Maptracker_Towncheck()
vars.maptracker.map.kills.2 := parse, LLK_ToolTip(Lang_Trans("maptracker_kills", 2),,,,, "Lime"), vars.maptracker.refresh_kills := 3
vars.maptracker.map.kills.2 := parse, LLK_ToolTip(Lang_Trans("maptracker_kills", 2),,,,, "Lime"), vars.maptracker.refresh_kills := 3, vars.maptracker.last_kills := parse
}

If settings.features.maptracker && settings.maptracker.mechanics && vars.maptracker.map.id && (vars.log.areaID = vars.maptracker.map.id)
Expand Down
11 changes: 6 additions & 5 deletions modules/clone-frames.ahk
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
Else ;when calling this function to update clone-frames, destroy old GUIs just in case
{
For cloneframe in vars.cloneframes.list
Gui, % StrReplace(cloneframe, " ", "_") ": Destroy"
Gui, % "cloneframe_" StrReplace(cloneframe, " ", "_") ": Destroy"
vars.cloneframes.enabled := 0, vars.cloneframes.list := {}, vars.cloneframes.editing := ""
}

Expand All @@ -25,7 +25,7 @@
If (key = "settings")
key := "settings_cloneframe" ;dummy entry for clone-frame creation
vars.cloneframes.list[key] := {"enable": !Blank(check := ini[key].enable) ? check : 1}
Gui, % StrReplace(key, " ", "_") ": New", -Caption +E0x80000 +E0x20 +LastFound +AlwaysOnTop +ToolWindow +OwnDialogs HWNDhwnd
Gui, % "cloneframe_" StrReplace(key, " ", "_") ": New", -Caption +E0x80000 +E0x20 +LastFound +AlwaysOnTop +ToolWindow +OwnDialogs HWNDhwnd
vars.hwnd.cloneframes[key] := hwnd
If vars.cloneframes.list[key].enable
vars.cloneframes.enabled += 1
Expand All @@ -51,7 +51,7 @@ Cloneframes_Hide()
For cloneframe in vars.cloneframes.list
{
If vars.hwnd.cloneframes[cloneframe] && WinExist("ahk_id " vars.hwnd.cloneframes[cloneframe])
Gui, % StrReplace(cloneframe, " ", "_") ": Hide"
Gui, % "cloneframe_" StrReplace(cloneframe, " ", "_") ": Hide"
If vars.hwnd.cloneframe_borders.main && WinExist("ahk_id " vars.hwnd.cloneframe_borders.main)
Gui, cloneframe_border: Hide
If vars.hwnd.cloneframe_borders.second && WinExist("ahk_id " vars.hwnd.cloneframe_borders.second)
Expand Down Expand Up @@ -199,15 +199,16 @@ Cloneframes_Show()
If !val.enable && !(vars.cloneframes.editing && cloneframe = vars.cloneframes.editing) || (cloneframe = "settings_cloneframe")
{
If WinExist("ahk_id " vars.hwnd.cloneframes[cloneframe])
Gui, % StrReplace(cloneframe, " ", "_") ": Hide"
Gui, % "cloneframe_" StrReplace(cloneframe, " ", "_") ": Hide"
If vars.hwnd.cloneframe_borders.main && WinExist("ahk_id " vars.hwnd.cloneframe_borders.main) && !vars.cloneframes.editing
Gui, cloneframe_border: Hide
If vars.hwnd.cloneframe_borders.second && WinExist("ahk_id " vars.hwnd.cloneframe_borders.second) && !vars.cloneframes.editing
Gui, cloneframe_border2: Hide
continue
}

If !WinExist("ahk_id " vars.hwnd.cloneframes[cloneframe])
Gui, % StrReplace(cloneframe, " ", "_") ": Show", NA
Gui, % "cloneframe_" StrReplace(cloneframe, " ", "_") ": Show", NA
pBitmap := Gdip_BitmapFromScreen(vars.monitor.x + val.xSource "|" vars.monitor.y + val.ySource "|" val.width "|" val.height)
width := val.width* val.xScale/100, height := val.height* val.yScale/100
hbmBitmap := CreateDIBSection(width, height), hdcBitmap := CreateCompatibleDC(), obmBitmap := SelectObject(hdcBitmap, hbmBitmap), gBitmap := Gdip_GraphicsFromHDC(hdcBitmap)
Expand Down
2 changes: 1 addition & 1 deletion modules/item-checker.ahk
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ Iteminfo(refresh := 0) ; refresh: 1 to refresh it normally, 2 for clipboard pars
If (refresh = 2)
Return

If !vars.poe_version && !db.item_bases.HasKey(item.class) || (item.itembase = "Timeless Jewel") || vars.poe_version && (item.rarity = "unique" || !vars.omnikey.poedb[item.class]) ;|| (item.name = "Impossible Escape")
If !vars.poe_version && !db.item_bases.HasKey(item.class) || (item.itembase = "Timeless Jewel") || vars.poe_version && !vars.omnikey.poedb[item.class] ;|| (item.name = "Impossible Escape")
{
LLK_ToolTip(Lang_Trans("ms_item-info") ":`n" Lang_Trans("iteminfo_unsupported"), 2,,,, "red"), LLK_Overlay(vars.hwnd.iteminfo.main, "destroy")
Return
Expand Down
11 changes: 0 additions & 11 deletions modules/leveling tracker.ahk
Original file line number Diff line number Diff line change
Expand Up @@ -724,17 +724,6 @@ Leveltracker_Import(profile := "")
Try vars.leveltracker["pob" profile] := LevelTracker_PobImport(StrReplace(act, "pob-code:"), profile)
}

/*
While (SubStr(gem_notes, 0) = "`n")
gem_notes := SubStr(gem_notes, 1, -1)
IniDelete, ini\leveling tracker.ini, Gem notes%profile%
If gem_notes
{
StringLower, gem_notes, gem_notes
gem_notes := StrReplace(gem_notes, "&", "&&")
IniWrite, % gem_notes, ini\leveling tracker.ini, Gem notes%profile%
}
*/
build_gems_all := build_gems_skill_str build_gems_supp_str build_gems_skill_dex build_gems_supp_dex build_gems_skill_int build_gems_supp_int build_gems_none ;create single gem-string for gear tracker feature

IniDelete, ini\leveling tracker.ini, Gems%profile%
Expand Down
21 changes: 7 additions & 14 deletions modules/lootfilter.ahk
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,9 @@ Lootfilter_Base(mode)
For index, match in LLK_HasRegex(vars.lootfilter.bases, "i)" (InStr(val, """") ? "^""" : "") StrReplace(val, """") . (InStr(val, """") ? """$" : ""), 1, 1)
search_results[match] := vars.lootfilter.bases[match]

;If !InStr(val, """")
For key in vars.lootfilter.bases
If !search_results[key] && InStr(val, StrReplace(key, """"))
search_results[key] := 1
For key in vars.lootfilter.bases
If !search_results[key] && InStr(val, StrReplace(key, """"))
search_results[key] := 1
}
vars.lootfilter.search := [search.1, search_results]
}
Expand Down Expand Up @@ -122,7 +121,7 @@ Lootfilter_Base(mode)

If (mode = "load")
{
vars.lootfilter.modifications_backup := LLK_CloneObject(modifications) ; modifications.Clone()
vars.lootfilter.modifications_backup := LLK_CloneObject(modifications)
FileGetTime, timestamp1, % file1, M
If FileExist(file2)
{
Expand Down Expand Up @@ -228,10 +227,7 @@ Lootfilter_ChunkModify(chunk, action, object := "", stack_size := 0)
insert_line := "", loopfield := A_LoopField
For key, val in object
If (index != 1) && !LLK_StringCompare(loopfield, ["basetype", "class"]) && !InStr(chunk, key) && !InStr(modified_chunk, key)
{
;insert_line := InStr(key, "color") ? "Set" key " " val : key " " val
modified_chunk .= "`r`n" (InStr(key, "color") ? "Set" key " " val : key " " val)
}
Else If InStr(loopfield, key)
{
end := 0
Expand Down Expand Up @@ -301,7 +297,7 @@ Lootfilter_GUI(cHWND := "", side := "", activation := "")
}
LLK_Overlay(vars.hwnd.lootfilter.main, "destroy"), vars.lootfilter.search := vars.hwnd.lootfilter.main := ""
vars.lootfilter.pending := (vars.lootfilter.pending = 2) ? 2 : 0
vars.lootfilter.filter := vars.lootfilter.filter_backup.Clone(), vars.lootfilter.modifications := LLK_CloneObject(vars.lootfilter.modifications_backup) ; vars.lootfilter.modifications_backup.Clone()
vars.lootfilter.filter := vars.lootfilter.filter_backup.Clone(), vars.lootfilter.modifications := LLK_CloneObject(vars.lootfilter.modifications_backup)
Return
}
Else If (check = "basefilter")
Expand Down Expand Up @@ -372,7 +368,7 @@ Lootfilter_GUI(cHWND := "", side := "", activation := "")
{
If !LLK_Progress(vars.hwnd.lootfilter.apply_bar, "LButton",, 0) && !(dev_mode := (settings.general.dev && LLK_Progress(vars.hwnd.lootfilter.apply_bar, "RButton",, 0)))
Return
vars.lootfilter.filter_backup := vars.lootfilter.filter.Clone(), vars.lootfilter.modifications_backup := LLK_CloneObject(vars.lootfilter.modifications) ; vars.lootfilter.modifications.Clone()
vars.lootfilter.filter_backup := vars.lootfilter.filter.Clone(), vars.lootfilter.modifications_backup := LLK_CloneObject(vars.lootfilter.modifications)
FileDelete, % vars.lootfilter.config_folder "LLK-UI*.filter"
file_dump := "# LLK-UI modded filter, base file: " settings.lootfilter.active
For index, chunk in vars.lootfilter.filter
Expand Down Expand Up @@ -449,9 +445,6 @@ Lootfilter_GUI(cHWND := "", side := "", activation := "")
Else If (vars.system.click = 1) && !Blank(pick := RGB_Picker(RGB_Convert(original := vars.lootfilter.selection.modifications[control])))
rgb := RGB_Convert(pick), vars.lootfilter.selection.modifications[control] := rgb.1 " " rgb.2 " " rgb.3 " " SubStr(original, InStr(original, " ",, 0) + 1)
Else Return
;GuiControl, % "+Background" pick, % vars.hwnd.lootfilter["selection_" control "_back"]
;GuiControl, % (control = "textcolor" ? "+c" : "+Background") pick, % vars.hwnd.lootfilter["selection_" control "_preview"]
;GuiControl, % "movedraw", % vars.hwnd.lootfilter["selection_" control "_preview"]
}
Else If InStr(check, "_discard")
{
Expand Down Expand Up @@ -666,7 +659,7 @@ Lootfilter_GUI(cHWND := "", side := "", activation := "")
Else If (index = 2)
style := "xp-" settings.lootfilter.hLabel/5 " yp-" settings.lootfilter.hLabel/5 " wp+" settings.lootfilter.hLabel*0.4 " hp+" settings.lootfilter.hLabel*0.4
Else style := "xp-" settings.lootfilter.hLabel/5 " y" yText - 1 " wp+" settings.lootfilter.hLabel*0.4 " h" settings.lootfilter.hLabel
;Else style := ""

Gui, %GUI_name%: Add, Text, % style " Border BackgroundTrans gLootfilter_GUI HWNDhwnd"
Gui, %GUI_name%: Add, Progress, % "Disabled HWNDhwnd2 xp yp wp hp Background" (RGB_Convert(Blank(vars.lootfilter.selection.modifications[val]) ? colors[val] : vars.lootfilter.selection.modifications[val])), 0
vars.hwnd.lootfilter["selection_" val] := hwnd, vars.hwnd.lootfilter["selection_" val "_back"] := vars.hwnd.help_tooltips["lootfilter_" val] := hwnd2
Expand Down
Loading

0 comments on commit f36df9e

Please sign in to comment.