2013-01-19 22:25:53 +00:00
|
|
|
#ifndef GL_CODE_H_INCLUDED
|
|
|
|
#define GL_CODE_H_INCLUDED
|
|
|
|
|
|
|
|
#ifdef TARGET_ANDROID
|
|
|
|
//#include "android_api.h"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <stdio.h>
|
|
|
|
#include <stdlib.h>
|
|
|
|
#include <math.h>
|
2018-02-02 15:00:17 +00:00
|
|
|
#include <memory>
|
2013-01-19 22:25:53 +00:00
|
|
|
|
|
|
|
#include "boost/shared_ptr.hpp"
|
|
|
|
/*#include "boost/thread/thread.hpp"
|
|
|
|
#include "boost/signal.hpp"
|
|
|
|
#include "boost/assign.hpp"
|
|
|
|
#include "boost/bind.hpp"
|
|
|
|
*/
|
|
|
|
#include "include/Engine.h"
|
|
|
|
|
|
|
|
#include "match3/match3field.h"
|
|
|
|
|
2018-02-01 14:39:31 +00:00
|
|
|
class TMatch3Field;
|
2013-01-19 22:25:53 +00:00
|
|
|
|
|
|
|
class TMatch3Controller
|
|
|
|
{
|
|
|
|
public:
|
2018-02-02 15:00:17 +00:00
|
|
|
std::shared_ptr<TMatch3Field> Match3Field;
|
2013-01-19 22:25:53 +00:00
|
|
|
|
|
|
|
|
|
|
|
TMatch3Controller()
|
2018-02-02 15:00:17 +00:00
|
|
|
{
|
2013-01-19 22:25:53 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
//Application class
|
2018-02-01 14:39:31 +00:00
|
|
|
class TMyApplication : public SE::TApplication
|
2013-01-19 22:25:53 +00:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
bool Inited;
|
|
|
|
|
|
|
|
TMatch3Controller Match3Controller;
|
2018-02-02 09:09:09 +00:00
|
|
|
|
|
|
|
SE::TRenderPair testPair;
|
2013-01-19 22:25:53 +00:00
|
|
|
|
|
|
|
TMyApplication() : Inited(false) { }
|
|
|
|
|
|
|
|
virtual void InnerInit();
|
|
|
|
//What to do on init
|
|
|
|
|
|
|
|
virtual void InnerDeinit();
|
|
|
|
//What to do on deinit
|
|
|
|
|
|
|
|
virtual void InnerDraw();
|
|
|
|
//What to do on draw
|
|
|
|
|
2018-02-01 14:39:31 +00:00
|
|
|
virtual void InnerUpdate(size_t timer);
|
2013-01-19 22:25:53 +00:00
|
|
|
//What to do on update. timer means how many ms passed since last update
|
2018-02-02 15:00:17 +00:00
|
|
|
|
|
|
|
|
|
|
|
virtual void InnerOnTapDown(Eigen::Vector2f p) override;
|
|
|
|
|
|
|
|
virtual void InnerOnTapUp(Eigen::Vector2f p) override;
|
|
|
|
|
|
|
|
virtual void InnerOnMove(Eigen::Vector2f pos, Eigen::Vector2f shift) override;
|
2013-01-19 22:25:53 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#ifndef TARGET_IOS
|
2018-02-05 14:53:52 +00:00
|
|
|
extern std::shared_ptr<TMyApplication> App;
|
2013-01-19 22:25:53 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|