summary refs log tree commit diff stats
path: root/src/map.cpp
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2021-02-09 19:39:30 -0500
committerKelly Rauchenberger <fefferburbia@gmail.com>2021-02-09 19:39:30 -0500
commit0c2cd251fa0427b19f7c995bc7da7319d2ac80a5 (patch)
tree5ef74b3c50fa8bba3424f9e438d5fce61838c7df /src/map.cpp
parent60f10cf1c5e8b0610ebe12d11531030e6c241a42 (diff)
downloadtanetane-0c2cd251fa0427b19f7c995bc7da7319d2ac80a5.tar.gz
tanetane-0c2cd251fa0427b19f7c995bc7da7319d2ac80a5.tar.bz2
tanetane-0c2cd251fa0427b19f7c995bc7da7319d2ac80a5.zip
Maps can contain named points of interest called warps
Diffstat (limited to 'src/map.cpp')
-rw-r--r--src/map.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/map.cpp b/src/map.cpp index 1a2a250..2214d17 100644 --- a/src/map.cpp +++ b/src/map.cpp
@@ -78,6 +78,12 @@ Map::Map(std::string_view filename, Renderer& renderer) {
78 } 78 }
79 79
80 prototypes_.push_back(std::move(p)); 80 prototypes_.push_back(std::move(p));
81 } else if (object.getType() == "warp") {
82 vec2i point;
83 point.x() = object.getPosition().x;
84 point.y() = object.getPosition().y;
85
86 warpPoints_[object.getName()] = std::move(point);
81 } 87 }
82 } 88 }
83 } 89 }