From 1d5eee5cce347dcccacecdb6b0490447811e6507 Mon Sep 17 00:00:00 2001 From: James Whitehead II Date: Sun, 29 Jan 2012 00:37:30 +0000 Subject: [PATCH] Don't bail out immediately without floor information --- TomTom.lua | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/TomTom.lua b/TomTom.lua index db78e03..66b0ba1 100755 --- a/TomTom.lua +++ b/TomTom.lua @@ -847,14 +847,15 @@ function TomTom:AddMFWaypoint(m, f, x, y, opts) local zoneName = lmd:MapLocalize(m) - if not astrolabe:GetMapInfo(m) then - return - end - -- Get the default map floor, if necessary if not f then - local floors = astrolabe:GetNumFloors(m) - f = floors == 0 and 0 or 1 + if not astrolabe:GetMapInfo(m) then + -- guess the floor + f = 0 + else + local floors = astrolabe:GetNumFloors(m) + f = floors == 0 and 0 or 1 + end end -- Ensure there isn't already a waypoint at this location -- 1.7.9.5