Turret able to shoot, no collision event yet.
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
#ifndef Components_Turret_h__
|
||||
#define Components_Turret_h__
|
||||
|
||||
#include "Component.h"
|
||||
|
||||
namespace Components
|
||||
{
|
||||
|
||||
struct Turret : Component
|
||||
{
|
||||
Turret()
|
||||
: ShotSpeed(1.0f) { }
|
||||
|
||||
EntityID ShotTemplate;
|
||||
float ShotSpeed;
|
||||
|
||||
virtual Turret* Clone() const override { return new Turret(*this); }
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif // BarrelSteering_h__
|
||||
@@ -0,0 +1,25 @@
|
||||
#ifndef Components_TurretShot_h__
|
||||
#define Components_TurretShot_h__
|
||||
|
||||
#include "Component.h"
|
||||
|
||||
namespace Components
|
||||
{
|
||||
|
||||
struct TurretShot : Component
|
||||
{
|
||||
TurretShot()
|
||||
: Damage(1.0f),
|
||||
ExplosionRadius(1.0f),
|
||||
ExplosionStrength(100.0f) { }
|
||||
|
||||
float Damage;
|
||||
float ExplosionRadius;
|
||||
float ExplosionStrength;
|
||||
|
||||
virtual TurretShot* Clone() const override { return new TurretShot(*this); }
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif // Components_TurretShot_h__
|
||||
Reference in New Issue
Block a user