name=L["This section implements TomTom support for Routes. Click Start to find the nearest node in a visible route in the current zone.\n"],
order=0,
},
hit_distance={
name=L["Waypoint hit distance"],type="range",
desc=L["This is the distance in yards away from a waypoint to consider as having reached it so that the next node in the route can be added as the waypoint"],
min=5,
max=80,-- This is the maximum range of node detection for "Find X" profession skills
step=1,
order=10,
width="double",
arg="waypoint_hit_distance",
set=function(k,v)
db.defaults.waypoint_hit_distance=v
-- Yes, it has to be a new table instead of modifying the existing table.
-- This is because TomTom may still have table references to the old
-- callbacks table from a previously set waypoint and modifying it will cause
-- TomTom to malfunction (it expects the distance key to still exist)
callbacks={
distance={
[v]=TT.WaypointHit
},
}
end,
},
linebreak1={
type="description",
name="",
order=15,
},
start={
name=L["Start using TomTom"],type="execute",
desc=L["Start using TomTom by finding the closest visible route/node in the current zone and using that as the waypoint"],
handler=TT,
func="QueueFirstNode",
order=20,
},
keystart={
name="Keybind to Start",
desc="Keybind to Start",
type="keybinding",
handler=Routes.KeybindHelper,
get="GetKeybind",
set="SetKeybind",
arg="ROUTESTTSTART",
order=30,
},
linebreak2={
type="description",
name="",
order=35,
},
stop={
name=L["Stop using TomTom"],type="execute",
desc=L["Stop using TomTom by clearing the last queued node"],
handler=TT,
func="RemoveQueuedNode",
order=40,
},
keystop={
name="Keybind to Stop",
desc="Keybind to Stop",
type="keybinding",
handler=Routes.KeybindHelper,
get="GetKeybind",
set="SetKeybind",
arg="ROUTESTTSTOP",
order=50,
},
linebreak3={
type="description",
name="",
order=55,
},
direction={
name=L["Change direction"],type="execute",
desc=L["Change the direction of the nodes in the route being added as the next waypoint"],
handler=TT,
func="ChangeWaypointDirection",
order=60,
},
keychangedir={
name="Keybind to Change",
desc="Keybind to Change",
type="keybinding",
handler=Routes.KeybindHelper,
get="GetKeybind",
set="SetKeybind",
arg="ROUTESTTCHANGEDIR",
order=70,
},
},
}
-- Setup keybinds in keybinding menu
BINDING_HEADER_Routes=L["Routes"]
BINDING_NAME_ROUTESTTSTART=L["Start using Waypoints (TomTom)"]
BINDING_NAME_ROUTESTTSTOP=L["Stop using Waypoints (TomTom)"]
BINDING_NAME_ROUTESTTCHANGEDIR=L["Change direction (TomTom)"]