mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-09-03 07:27:24 +00:00
refactor: use std ranges functions where applicable
This commit is contained in:
@@ -25,7 +25,7 @@ void GameIW3::AddZone(Zone* zone)
|
||||
|
||||
void GameIW3::RemoveZone(Zone* zone)
|
||||
{
|
||||
const auto foundEntry = std::find(m_zones.begin(), m_zones.end(), zone);
|
||||
const auto foundEntry = std::ranges::find(m_zones, zone);
|
||||
|
||||
if (foundEntry != m_zones.end())
|
||||
m_zones.erase(foundEntry);
|
||||
|
@@ -25,7 +25,7 @@ void GameIW4::AddZone(Zone* zone)
|
||||
|
||||
void GameIW4::RemoveZone(Zone* zone)
|
||||
{
|
||||
const auto foundEntry = std::find(m_zones.begin(), m_zones.end(), zone);
|
||||
const auto foundEntry = std::ranges::find(m_zones, zone);
|
||||
|
||||
if (foundEntry != m_zones.end())
|
||||
m_zones.erase(foundEntry);
|
||||
|
@@ -25,7 +25,7 @@ void GameIW5::AddZone(Zone* zone)
|
||||
|
||||
void GameIW5::RemoveZone(Zone* zone)
|
||||
{
|
||||
const auto foundEntry = std::find(m_zones.begin(), m_zones.end(), zone);
|
||||
const auto foundEntry = std::ranges::find(m_zones, zone);
|
||||
|
||||
if (foundEntry != m_zones.end())
|
||||
m_zones.erase(foundEntry);
|
||||
|
@@ -25,7 +25,7 @@ void GameT5::AddZone(Zone* zone)
|
||||
|
||||
void GameT5::RemoveZone(Zone* zone)
|
||||
{
|
||||
const auto foundEntry = std::find(m_zones.begin(), m_zones.end(), zone);
|
||||
const auto foundEntry = std::ranges::find(m_zones, zone);
|
||||
|
||||
if (foundEntry != m_zones.end())
|
||||
m_zones.erase(foundEntry);
|
||||
|
@@ -25,7 +25,7 @@ void GameT6::AddZone(Zone* zone)
|
||||
|
||||
void GameT6::RemoveZone(Zone* zone)
|
||||
{
|
||||
const auto foundEntry = std::find(m_zones.begin(), m_zones.end(), zone);
|
||||
const auto foundEntry = std::ranges::find(m_zones, zone);
|
||||
|
||||
if (foundEntry != m_zones.end())
|
||||
m_zones.erase(foundEntry);
|
||||
|
Reference in New Issue
Block a user