feat(laser): created laser object

Created laser object without any collision detection
This commit is contained in:
2024-01-09 12:26:42 +01:00
parent 0fed252afd
commit 9b0a7a78bb
10 changed files with 103 additions and 27 deletions
+11
View File
@@ -0,0 +1,11 @@
#include "Laser.h"
Laser::Laser()
{
_laser = RectangleShape(Vector2f(2, 20));
_laser.setFillColor(Color::White);
}
void Laser::setInitialPosition(Vector2f position) {
_laser.setPosition(Vector2f(position.x - (_laser.getScale().x / 2), position.y));
}