#ifndef MAINWINDOW_H #define MAINWINDOW_H #include #include class QGraphicsScene; class QStateMachine; class QState; class TankItem; class MainWindow: public QMainWindow { Q_OBJECT Q_PROPERTY(bool started READ started WRITE setStarted) public: MainWindow(QWidget *parent = 0); ~MainWindow(); void setStarted(bool b) { m_started = b; } bool started() const { return m_started; } public slots: void addTank(); void addRocket(); void runStep(); signals: void mapFull(); private: void init(); void addWall(const QRectF &wall); QGraphicsScene *m_scene; QStateMachine *m_machine; QState *m_runningState; QList m_spawns; QTime m_time; bool m_started : 1; }; #endif