This repository has been archived on 2019-12-07. You can view files and clone it, but cannot push or open issues or pull requests.
dungeon-gunner/source/items/Weapon.h

41 lines
732 B
C
Raw Normal View History

/*
* Weapon.h
*
* Created on: 12.08.2012
* Author: Felix
*/
#ifndef DG_WEAPON_H_
#define DG_WEAPON_H_
#include <Thor/Particles.hpp>
#include "../abstract/Physical.h"
#include "../particle/Emitter.h"
/**
* Loading mechanism:
* - pass enum value and load mapped xml
* - pass xml filename
*/
class Weapon : public Emitter {
2012-09-11 19:13:36 +00:00
// Public functions.
public:
Weapon(Physical& holder, Collection& collection, b2World& world);
~Weapon();
void fire();
2012-09-11 19:13:36 +00:00
// Protected functions.
protected:
std::shared_ptr<Particle> createParticle();
2012-09-11 19:13:36 +00:00
// Private variables.
private:
Physical& mHolder;
std::shared_ptr<sf::Texture> mBulletTexture;
b2World& mWorld;
};
#endif /* DG_WEAPON_H_ */