From 8271b1519e095ee3e7245cde2f0b54561c3ec619 Mon Sep 17 00:00:00 2001 From: hop311 Date: Tue, 14 Nov 2023 21:42:00 +0000 Subject: Bookmark loading + province and building cleanup --- src/openvic-simulation/types/Date.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/openvic-simulation/types/Date.cpp') diff --git a/src/openvic-simulation/types/Date.cpp b/src/openvic-simulation/types/Date.cpp index c5eac41..e695e45 100644 --- a/src/openvic-simulation/types/Date.cpp +++ b/src/openvic-simulation/types/Date.cpp @@ -204,6 +204,10 @@ Date Date::operator++(int) { return old; } +bool Date::in_range(Date start, Date end) const { + return start <= *this && *this <= end; +} + std::string Date::to_string() const { std::stringstream ss; ss << *this; -- cgit v1.2.3-56-ga3b1