From 43db0f03627fc2301959ca2b448a125a7ea80cb3 Mon Sep 17 00:00:00 2001 From: Jim Whitehead Date: Wed, 24 Aug 2016 09:31:05 +0200 Subject: [PATCH] Enable /wayb to take a name/title as an argument If one is not provided, just use the existing behaviour. --- TomTom.lua | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/TomTom.lua b/TomTom.lua index cd2100a..13adb16 100755 --- a/TomTom.lua +++ b/TomTom.lua @@ -1161,9 +1161,14 @@ end SLASH_TOMTOM_WAYBACK1 = "/wayb" SLASH_TOMTOM_WAYBACK2 = "/wayback" SlashCmdList["TOMTOM_WAYBACK"] = function(msg) + local title = L["Wayback"] + if msg and msg:match("%S") then + title = msg + end + local backm,backf,backx,backy = TomTom:GetCurrentPlayerPosition() TomTom:AddMFWaypoint(backm, backf, backx, backy, { - title = L["Wayback"], + title = title, }) end -- 1.7.9.5