From 4561c7192238483ec3c68240deefd2f3b14b8c79 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20T=C5=AFma?= Date: Wed, 23 Mar 2022 08:04:05 +0100 Subject: [PATCH] Fixed broken handling of maps with basemaps --- src/map/IMG/trefile.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/map/IMG/trefile.cpp b/src/map/IMG/trefile.cpp index 8659e8b7..6c194b7b 100644 --- a/src/map/IMG/trefile.cpp +++ b/src/map/IMG/trefile.cpp @@ -290,7 +290,7 @@ void TREFile::clear() int TREFile::level(int bits, bool baseMap) { if (baseMap) { - if (!_isBaseMap && _levels.first().bits > bits) + if (!_isBaseMap && _levels.at(_firstLevel).bits > bits) return -1; if (_isBaseMap && bits > _levels.last().bits) return -1;