diff --git a/source/Game.cpp b/source/Game.cpp index 2d82f87..2e9f361 100644 --- a/source/Game.cpp +++ b/source/Game.cpp @@ -9,8 +9,7 @@ #include -#include "abstract/Character.h" -#include "sprites/Cover.h" +#include "abstract/Character.h" #include "sprites/Enemy.h" #include "types/Instances.h" #include "types/String.h" @@ -32,7 +31,7 @@ Game::Game(sf::RenderWindow& window) : mView(Vector2f(0, 0), mWindow.getView().getSize()), //mFps("test"), mTileManager(mWorld), - mPathfinder(mWorld), + mPathfinder(mTileManager), mElapsed(0), mQuit(false), mPaused(false) { @@ -62,8 +61,6 @@ Game::generate() { Instances instances(mPathfinder, mTileManager, mCollection, mWorld); mCollection.insert(std::shared_ptr(new Enemy(instances, Vector2f(400.0f, 200.0f), Yaml("enemy.yaml")))); - mCollection.insert(std::shared_ptr(new Cover(Vector2f(300, 200), Vector2i(100, 150), - mWorld, Yaml("cover.yaml")))); mPlayer = std::unique_ptr(new Player(instances, Vector2f(200.0f, 100.0f), Yaml("player.yaml"))); } diff --git a/source/sprites/Cover.cpp b/source/sprites/Cover.cpp deleted file mode 100644 index 4d04770..0000000 --- a/source/sprites/Cover.cpp +++ /dev/null @@ -1,13 +0,0 @@ -/* - * Cover.cpp - * - * Created on: 12.08.2012 - * Author: Felix - */ - -#include "Cover.h" - -Cover::Cover(const Vector2f& position, const Vector2i& size, b2World& world, const Yaml& config) : - Sprite(config, PhysicalData(position, world, CATEGORY_WORLD, MASK_ALL, false), size) { -} - diff --git a/source/sprites/Cover.h b/source/sprites/Cover.h deleted file mode 100644 index b5357a9..0000000 --- a/source/sprites/Cover.h +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Cover.h - * - * Created on: 12.08.2012 - * Author: Felix - */ - -#ifndef DG_COVER_H_ -#define DG_COVER_H_ - -#include "../abstract/Sprite.h" -#include "../util/Yaml.h" - -class Sprite; -class Yaml; - -/** - * A wall that can be placed anywhere (not limited by tiles) and have any (rectangular) size. - */ -class Cover : public Sprite { -// Public functions. -public: - Cover(const Vector2f& position, const Vector2i& size, b2World& world, const Yaml& config); -}; - -#endif /* DG_COVER_H_ */