Add alot of memory leak fixes

This commit is contained in:
Bram Verhulst
2024-04-23 11:17:17 +02:00
parent e75b80eea8
commit 1b90f222a4
27 changed files with 234 additions and 48 deletions

View File

@@ -5,6 +5,9 @@ Screen::Screen(const std::string& filePath, Vector2f pos, Vector2f size, Texture
m_Background = manager->GetTexture(filePath);
}
Screen::~Screen() {
for (Button* b : m_Buttons) {
delete b;
}
}
void Screen::Update(float elapsedSecs) {
for (Button* b : m_Buttons) {