From 273d692c656aea9777699e046862b478e9706444 Mon Sep 17 00:00:00 2001
From: DarkGod <darkgod@net-core.org>
Date: Mon, 11 Nov 2013 22:23:04 +0100
Subject: [PATCH] fix

---
 game/engines/default/engine/Map.lua | 1 +
 1 file changed, 1 insertion(+)

diff --git a/game/engines/default/engine/Map.lua b/game/engines/default/engine/Map.lua
index 2e54bc5ff3..4c99d8026a 100644
--- a/game/engines/default/engine/Map.lua
+++ b/game/engines/default/engine/Map.lua
@@ -845,6 +845,7 @@ end
 
 --- Get the screen position corresponding to a tile
 function _M:getTileToScreen(tx, ty)
+	if not tx or not ty then return nil, nil end
 	local x = (tx - self.mx) * self.tile_w * self.zoom + self.display_x
 	local y = (ty - self.my + util.hexOffset(tx)) * self.tile_h * self.zoom + self.display_y
 	return x, y
-- 
GitLab