/* # ______ ____ ___ # | \/ ____| |___| # | | | \ | | #----------------------------------------------------------------------- # Copyright 2020, tyra - https://github.com/h4570/tyra # Licenced under Apache License 2.0 # MichaƂ Mostowik */ #ifndef _DRIVER_ #define _DRIVER_ #include #include #include #include #include #include #include #include "./camera.hpp" #include "./objects/player.hpp" #include "./objects/collectible.hpp" #include "./objects/mine.hpp" class Dolphin : public Game { public: Dolphin(Engine *t_engine); ~Dolphin(); void onInit(); void onUpdate(); Engine *engine; static float engineFPS; private: void calcSpiral(int X, int Y); static const u16 WATER_TILES_COUNT = 1024; Point spirals[WATER_TILES_COUNT]; Mesh **waterDrawList; /** * DO NOT TOUCH ORDER OF DECLARATION! * GCC BUG CAUSES RENDERING TO FAIL IN ANY OTHER ORDER OF DECLARATION! */ Mesh seabed; Mesh island; Mesh skybox; Mesh mine; LightBulb bulb; Player player; Camera camera; Collectible *oysters; TextureRepository *texRepo; Sprite waterOverlay; Mesh water[WATER_TILES_COUNT]; Mesh waterbox; Sprite lifeSprites[3]; Sprite gameOver; audsrv_adpcm_t *underwaterAmbient, *surfaceAmbient; audsrv_adpcm_t *pickupSound; audsrv_adpcm_t *boomSound; Mine *mines; }; #endif