-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b524156
commit d9785eb
Showing
48 changed files
with
4,204 additions
and
3,041 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,44 @@ | ||
#pragma once | ||
#ifndef DROP_H | ||
#define DROP_H | ||
|
||
#include "Player.h" | ||
#include "PlayerGUI.h" | ||
#include "FloatingText.h" | ||
|
||
class Player; | ||
class PlayerGUI; | ||
class FloatingText; | ||
|
||
class Drop | ||
{ | ||
public: | ||
Drop(const std::string& name, const float& posX, const float& posY, const unsigned& worth, sf::VideoMode& vm); | ||
virtual ~Drop(); | ||
|
||
virtual const std::string getName() const; | ||
virtual const bool getSpawned() const; | ||
|
||
void spawn(const float& dt); | ||
void spin(const float& dt); | ||
void move(const float& posX, const float& posY, const float& dt); | ||
const bool playerPick(Player* player, sf::Font* font, PlayerGUI* playerGUI, std::list<FloatingText*>& floatingTexts, const float& dt); | ||
|
||
void update(const float& dt); | ||
void draw(sf::RenderTarget& target); | ||
private: | ||
sf::Texture texture; | ||
sf::Sprite sprite; | ||
|
||
float scale; | ||
sf::Vector2f predkosc; | ||
sf::Vector2f velocity; | ||
std::string name; | ||
|
||
float spinCooldown; | ||
unsigned worth; | ||
float angle; | ||
std::string name; | ||
|
||
void init(const float& scale, const sf::Vector2f& position, const std::string& name, const unsigned& worth); | ||
void spin(const float& dt); | ||
void move(const float& dt); | ||
|
||
Drop(); | ||
virtual ~Drop(); | ||
|
||
sf::VideoMode vm; | ||
|
||
bool spawned; | ||
float spawnCountdown; | ||
}; | ||
|
||
#endif |
Oops, something went wrong.