ddnet/src/game/layers.h

50 lines
1.5 KiB
C
Raw Normal View History

2010-11-20 10:37:14 +00:00
/* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */
/* If you are missing that file, acquire a complete release at teeworlds.com. */
2010-05-29 07:25:38 +00:00
#ifndef GAME_LAYERS_H
#define GAME_LAYERS_H
#include <engine/map.h>
#include <game/mapitems.h>
class CLayers
{
int m_GroupsNum;
int m_GroupsStart;
int m_LayersNum;
int m_LayersStart;
CMapItemGroup *m_pGameGroup;
CMapItemLayerTilemap *m_pGameLayer;
class IMap *m_pMap;
2022-01-19 21:20:28 +00:00
void InitTilemapSkip();
2010-05-29 07:25:38 +00:00
public:
CLayers();
void Init(class IKernel *pKernel);
2015-08-25 00:11:04 +00:00
void InitBackground(class IMap *pMap);
2022-01-19 21:31:49 +00:00
int NumGroups() const { return m_GroupsNum; }
2022-01-19 21:30:29 +00:00
int NumLayers() const { return m_LayersNum; }
2022-01-19 21:31:49 +00:00
class IMap *Map() const { return m_pMap; }
CMapItemGroup *GameGroup() const { return m_pGameGroup; }
CMapItemLayerTilemap *GameLayer() const { return m_pGameLayer; }
2010-05-29 07:25:38 +00:00
CMapItemGroup *GetGroup(int Index) const;
CMapItemLayer *GetLayer(int Index) const;
// DDRace
2022-01-19 21:31:49 +00:00
CMapItemLayerTilemap *TeleLayer() const { return m_pTeleLayer; }
CMapItemLayerTilemap *SpeedupLayer() const { return m_pSpeedupLayer; }
CMapItemLayerTilemap *FrontLayer() const { return m_pFrontLayer; }
CMapItemLayerTilemap *SwitchLayer() const { return m_pSwitchLayer; }
CMapItemLayerTilemap *TuneLayer() const { return m_pTuneLayer; }
private:
CMapItemLayerTilemap *m_pTeleLayer;
CMapItemLayerTilemap *m_pSpeedupLayer;
CMapItemLayerTilemap *m_pFrontLayer;
CMapItemLayerTilemap *m_pSwitchLayer;
2014-03-12 22:07:19 +00:00
CMapItemLayerTilemap *m_pTuneLayer;
2010-05-29 07:25:38 +00:00
};
#endif