axmol/tests/cpp-tests/Classes/TileMapTest/TileMapTest.h

306 lines
6.1 KiB
C
Raw Normal View History

2010-09-01 17:30:51 +08:00
#ifndef _TILEMAP_TEST_H_
#define _TILEMAP_TEST_H_
#include "../testBasic.h"
#include "../BaseTest.h"
class TileDemo : public BaseTest
2010-09-01 17:30:51 +08:00
{
public:
TileDemo(void);
virtual ~TileDemo(void);
virtual std::string title() const override;
virtual std::string subtitle() const override;
virtual void onEnter() override;
virtual void onExit()override;
void restartCallback(Ref* sender);
void nextCallback(Ref* sender);
void backCallback(Ref* sender);
void onTouchesMoved(const std::vector<Touch*>& touches, Event *event);
2010-09-01 17:30:51 +08:00
};
class TileMapTest : public TileDemo
{
public:
TileMapTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TileMapEditTest : public TileDemo
{
public:
TileMapEditTest (void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
2012-06-08 13:55:28 +08:00
void updateMap(float dt);
2010-09-01 17:30:51 +08:00
};
class TMXOrthoTest : public TileDemo
{
public:
TMXOrthoTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
virtual void onEnter() override;
virtual void onExit() override;
2010-09-01 17:30:51 +08:00
};
2014-10-11 15:09:58 +08:00
class TMXStaggeredTest : public TileDemo
{
public:
TMXStaggeredTest(void);
virtual std::string title() const override;
virtual void onEnter() override;
virtual void onExit() override;
};
2010-09-01 17:30:51 +08:00
class TMXOrthoTest2 : public TileDemo
{
public:
TMXOrthoTest2(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXOrthoTest3 : public TileDemo
{
public:
TMXOrthoTest3(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXOrthoTest4 : public TileDemo
{
public:
TMXOrthoTest4(void);
2012-06-08 13:55:28 +08:00
void removeSprite(float dt);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXReadWriteTest : public TileDemo
{
unsigned int _gid;
unsigned int _gid2;
2010-09-01 17:30:51 +08:00
public:
TMXReadWriteTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
void removeSprite(Node* sender);
2012-06-08 13:55:28 +08:00
void updateCol(float dt);
void repaintWithGID(float dt);
void removeTiles(float dt);
2010-09-01 17:30:51 +08:00
};
class TMXHexTest : public TileDemo
{
public:
TMXHexTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXIsoTest : public TileDemo
{
public:
TMXIsoTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXIsoTest1 : public TileDemo
{
public:
TMXIsoTest1(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXIsoTest2 : public TileDemo
{
public:
TMXIsoTest2(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXUncompressedTest : public TileDemo
{
public:
TMXUncompressedTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXTilesetTest : public TileDemo
{
public:
TMXTilesetTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
};
class TMXOrthoObjectsTest : public TileDemo
{
public:
TMXOrthoObjectsTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
virtual std::string subtitle() const override;
2010-09-01 17:30:51 +08:00
};
class TMXIsoObjectsTest : public TileDemo
{
public:
TMXIsoObjectsTest(void);
virtual std::string title() const override;
2010-09-01 17:30:51 +08:00
virtual std::string subtitle() const override;
2010-09-01 17:30:51 +08:00
};
class TMXResizeTest : public TileDemo
{
public:
TMXResizeTest(void);
virtual std::string title() const override;
virtual std::string subtitle() const override;
2010-09-01 17:30:51 +08:00
};
class TMXIsoZorder : public TileDemo
{
Sprite* _tamara;
2010-09-01 17:30:51 +08:00
public:
TMXIsoZorder(void);
virtual std::string title() const override;
virtual std::string subtitle() const override;
virtual void onExit(void);
2010-09-01 17:30:51 +08:00
~TMXIsoZorder();
2012-06-08 13:55:28 +08:00
void repositionSprite(float dt);
2010-09-01 17:30:51 +08:00
};
class TMXOrthoZorder : public TileDemo
{
Sprite* _tamara;
2010-09-01 17:30:51 +08:00
public:
TMXOrthoZorder(void);
virtual std::string title() const override;
virtual std::string subtitle() const override;
2010-09-01 17:30:51 +08:00
virtual ~TMXOrthoZorder();
2012-06-08 13:55:28 +08:00
void repositionSprite(float dt);
2010-09-01 17:30:51 +08:00
};
class TMXIsoVertexZ : public TileDemo
{
Sprite* _tamara;
2010-09-01 17:30:51 +08:00
public:
TMXIsoVertexZ(void);
virtual std::string title() const override;
virtual std::string subtitle() const override;
~TMXIsoVertexZ();
2012-06-08 13:55:28 +08:00
void repositionSprite(float dt);
virtual void onEnter() override;
virtual void onExit() override;
2010-09-01 17:30:51 +08:00
};
class TMXOrthoVertexZ : public TileDemo
{
Sprite* _tamara;
2010-09-01 17:30:51 +08:00
public:
TMXOrthoVertexZ(void);
virtual std::string title() const override;
virtual std::string subtitle() const override;
~TMXOrthoVertexZ();
2012-06-08 13:55:28 +08:00
void repositionSprite(float dt);
virtual void onEnter() override;
virtual void onExit() override;
2010-09-01 17:30:51 +08:00
};
class TMXIsoMoveLayer : public TileDemo
{
public:
TMXIsoMoveLayer(void);
virtual std::string title() const override;
virtual std::string subtitle() const override;
2010-09-01 17:30:51 +08:00
};
class TMXOrthoMoveLayer : public TileDemo
{
public:
TMXOrthoMoveLayer(void);
virtual std::string title() const override;
virtual std::string subtitle() const override;
};
class TMXTilePropertyTest : public TileDemo
{
public:
TMXTilePropertyTest();
virtual std::string title() const override;
virtual std::string subtitle() const override;
2010-09-01 17:30:51 +08:00
};
class TMXOrthoFlipTest : public TileDemo
{
public:
TMXOrthoFlipTest();
virtual std::string title() const override;
};
class TMXOrthoFlipRunTimeTest : public TileDemo
{
public:
TMXOrthoFlipRunTimeTest();
virtual std::string title() const override;
virtual std::string subtitle() const override;
2012-06-08 13:55:28 +08:00
void flipIt(float dt);
};
class TMXOrthoFromXMLTest : public TileDemo
{
public:
TMXOrthoFromXMLTest();
virtual std::string title() const override;
};
class TMXOrthoXMLFormatTest : public TileDemo
{
public:
TMXOrthoXMLFormatTest();
virtual std::string title() const override;
};
2011-02-23 16:47:25 +08:00
class TMXBug987 : public TileDemo
{
public:
TMXBug987();
virtual std::string title() const override;
virtual std::string subtitle() const override;
2011-02-23 16:47:25 +08:00
};
class TMXBug787 : public TileDemo
{
public:
TMXBug787();
virtual std::string title() const override;
virtual std::string subtitle() const override;
2011-02-23 16:47:25 +08:00
};
class TMXGIDObjectsTest : public TileDemo
2011-07-06 14:56:05 +08:00
{
public:
TMXGIDObjectsTest();
virtual std::string title() const override;
virtual std::string subtitle() const override;
2011-07-06 14:56:05 +08:00
};
2010-09-01 17:30:51 +08:00
class TileMapTestScene : public TestScene
{
public:
virtual void runThisTest();
};
#endif