#pragma once #include #include "HeightMap.h" #include "Player.h" #include "Enemy.h" #include "LevelObject.h" #include "Interface.h" #include "Crystal.h" #include "Skybox.h" #include "CrystalPoint.h" #include "Portal.h" class Entity; class World { private: std::vector>> objecttemplates; Sound* music; Player* player; HeightMap* heightmap; Interface* interface; Skybox* skybox; Portal* portal; bool nextworld; int sound_id,maxCrystals,maxEnemies; std::vector entities; std::vector enemies; //std::vector crystals; public: World(const std::string &fileName); ~World(); void draw(); void update(float elapsedTime); bool isPlayerPositionValid(); float getHeight(float x, float y); void addLevelObject(LevelObject* obj); Vec2f randomPosition(void); std::pair getObjectFromValue(int i); };