diff options
author | tomsmeding <tom.smeding@gmail.com> | 2016-12-29 10:57:15 +0100 |
---|---|---|
committer | tomsmeding <tom.smeding@gmail.com> | 2016-12-29 10:57:30 +0100 |
commit | 6286f890c132b9cd6a36d585735e5d7310dc0abf (patch) | |
tree | 32b2e697fa0030fdd410eba0d2626e8fd511c7ed /main.cpp | |
parent | ac18b3132059b5e7d5f00ccf2b56e543cf0da84b (diff) |
Sprites, object destruction
Diffstat (limited to 'main.cpp')
-rw-r--r-- | main.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -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; } |