summaryrefslogtreecommitdiff
path: root/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'main.cpp')
-rw-r--r--main.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/main.cpp b/main.cpp
index f9312bd..9f62068 100644
--- a/main.cpp
+++ b/main.cpp
@@ -8,10 +8,7 @@
#include "global.h"
#include "library.h"
#include "build/objects.h"
-
-#include <FL/Fl.H>
-#include <FL/Fl_Window.H>
-#include <FL/Fl_draw.H>
+#include "build/sprites.h"
using namespace std;
@@ -64,5 +61,9 @@ int main(int argc,char **argv){
Fl::visual(FL_RGB);
window->show(argc,argv);
Fl::add_timeout(1.0/30,stepcallback);
- return Fl::run();
+ int ret=Fl::run();
+ for(shared_ptr<Object> p : global.objects){
+ p->destroy();
+ }
+ return ret;
}