Ajuste leve na velocidade permitindo movimentos mais sutis
[Projeto-PCG.git] / shotmanager.cpp
blobc4081014229f76daa3cf92e4c0ccfd150b29d371
1 #include "shotmanager.h"
2 #include "shot.h"
4 void ShotManager::addShot(Shot* shot) {
5 shots.push_back(shot);
8 void ShotManager::desenha() {
9 std::vector<Shot*>::iterator it;
10 for (it = shots.begin(); it != shots.end(); it++) {
11 (*it)->desenha();
15 void ShotManager::move() {
16 std::vector<Shot*>::iterator it;
17 for (it = shots.begin(); it != shots.end(); it++) {
18 (*it)->move();
22 void ShotManager::deleteShot(Shot* shot) {
23 std::vector<Shot*>::iterator it;
24 for (it = shots.begin(); it != shots.end(); it++) {
25 if (*it == shot) {
26 shots.erase(it);
27 return;
32 void ShotManager::clearShots() {
33 shots.clear();