pull/28/head
parent
6d4c069fe4
commit
77bd085908
@ -1,5 +1,5 @@ |
|||||||
#include "Ability.h" |
#include "Ability.h" |
||||||
|
|
||||||
Ability::Ability(){}; |
Ability::Ability(){}; |
||||||
Ability::Ability(std::string name,float cooldownTime,Pixel barColor1,Pixel barColor2) |
Ability::Ability(std::string name,float cooldownTime,int manaCost,Pixel barColor1,Pixel barColor2) |
||||||
:name(name),cooldown(0),COOLDOWN_TIME(cooldownTime),barColor1(barColor1),barColor2(barColor2){} |
:name(name),cooldown(0),COOLDOWN_TIME(cooldownTime),manaCost(manaCost),barColor1(barColor1),barColor2(barColor2){} |
@ -1,11 +1,13 @@ |
|||||||
#pragma once |
#pragma once |
||||||
#include "olcPixelGameEngine.h" |
#include "olcPixelGameEngine.h" |
||||||
|
|
||||||
|
//Abilities are tied to class data which is defined in Class.cpp.
|
||||||
struct Ability{ |
struct Ability{ |
||||||
std::string name=""; |
std::string name=""; |
||||||
float cooldown=0; |
float cooldown=0; |
||||||
float COOLDOWN_TIME=0; |
float COOLDOWN_TIME=0; |
||||||
|
int manaCost=0; |
||||||
Pixel barColor1,barColor2; |
Pixel barColor1,barColor2; |
||||||
Ability(); |
Ability(); |
||||||
Ability(std::string name,float cooldownTime,Pixel barColor1=VERY_DARK_RED,Pixel barColor2=DARK_RED); |
Ability(std::string name,float cooldownTime,int manaCost,Pixel barColor1=VERY_DARK_RED,Pixel barColor2=DARK_RED); |
||||||
}; |
}; |
After Width: | Height: | Size: 697 B |
Loading…
Reference in new issue