set CurAmmoType to a temp var so I don't have to worry about it switching inside the routine so that I can actually put OnUsedAmmo where it belongs.
#include <QtGui/QApplication>
#include "editor.h"
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
editor w;
w.show();
return a.exec();
}